Skip to content
LangChain

thegraph mcp for LangChain

io.github.mrfentmen/thegraph-mcp

The Graph gateway: run GraphQL against any indexed subgraph.

client:LangChain transport:stdio runtime:npm

Install thegraph mcp in LangChain

pip install langchain-mcp-adapters

from langchain_mcp_adapters.client import MultiServerMCPClient

client = MultiServerMCPClient({
        "thegraph-mcp": {
            "transport": "stdio",
            "command": "npx",
            "args": ["-y", "thegraph-mcp"],
        }
})

tools = await client.get_tools()

get_tools() returns the server's tools as LangChain tools, ready for an agent. LangChain docs

thegraph mcp in other clients