TheGraph MCP Server
@kukapay
About TheGraph MCP Server
An MCP server that powers AI agents with indexed blockchain data from The Graph.
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"thegraph-mcp": {
"command": "uv",
"args": [
"--directory",
"path/to/thegraph-mcp",
"run",
"main.py"
],
"env": {
"THEGRAPH_API_KEY": ""
}
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is TheGraph MCP Server?
TheGraph MCP Server is an MCP server that powers AI agents with indexed blockchain data from The Graph. It is built for developers who want AI assistants to fetch and analyze on-chain data through subgraphs.
How to use TheGraph MCP Server?
Clone the repository and configure your MCP client with the uv command pointing to main.py. Set the THEGRAPH_API_KEY environment variable with your The Graph API key. Use the tools getSubgraphSchema and querySubgraph to fetch schema or run GraphQL queries.
Key features of TheGraph MCP Server
- Fetches subgraph schemas for query context
- Executes GraphQL queries against subgraphs
- Returns schemas in human-readable or JSON format
- Supports both AI-generated and manual queries
- Integrates with The Graph’s indexed blockchain data
Use cases of TheGraph MCP Server
- Explore a subgraph’s data model before writing queries
- Ask an AI to find top tokens by trading volume
- Analyze liquidity or swap events from a subgraph
- Combine schema discovery with custom data analysis
FAQ from TheGraph MCP Server
What kind of data does TheGraph MCP Server provide?
It provides indexed blockchain data from The Graph’s subgraphs, such as token prices, trading volumes, and swap events.
What are the runtime requirements?
Python 3.10 or higher, the uv package manager, and a valid The Graph API key configured in the environment variable THEGRAPH_API_KEY.
How is the server configured in a client?
Add a JSON entry under mcpServers with the command uv, args pointing to the cloned directory and main.py, and the API key in the env section.
Does TheGraph MCP Server support custom queries?
Yes, the querySubgraph tool executes any GraphQL query string, whether AI-generated or manually written.
Frequently asked questions
What kind of data does TheGraph MCP Server provide?
It provides indexed blockchain data from The Graph’s subgraphs, such as token prices, trading volumes, and swap events.
What are the runtime requirements?
Python 3.10 or higher, the `uv` package manager, and a valid The Graph API key configured in the environment variable `THEGRAPH_API_KEY`.
How is the server configured in a client?
Add a JSON entry under `mcpServers` with the command `uv`, args pointing to the cloned directory and `main.py`, and the API key in the env section.
Does TheGraph MCP Server support custom queries?
Yes, the `querySubgraph` tool executes any GraphQL query string, whether AI-generated or manually written.
Basic information
More Other MCP servers
Inbox Zero AI MCP
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
FastMCP v2 🚀
jlowin🚀 The fast, Pythonic way to build MCP servers and clients.
Inbox Zero AI
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
🚀 Model Context Protocol (MCP) Curriculum for Beginners
microsoftThis open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable,
Nginx UI
0xJackyYet another WebUI for Nginx
Comments