An MCP server that powers AI agents with indexed blockchain data from The Graph.
An MCP server that powers AI agents with indexed blockchain data from The Graph.
Fetches the schema of a specified subgraph, providing AI agents with the context needed to generate GraphQL queries.
Parameters:
subgraphId
: The subgraph ID (e.g., "QmZBQcF...")asText
: Output format flag
true
: Returns human-readable GraphQL schemafalse
: Returns JSON schema (default)Executes GraphQL queries against a specified subgraph. While queries are typically generated by AI, you can also manually craft your own.
Parameters:
subgraphId
: The subgraph IDquery
: GraphQL query stringgit clone https://github.com/kukapay/thegraph-mcp.git
{
"mcpServers": {
"thegraph-mcp": {
"command": "uv",
"args": ["--directory", "path/to/thegraph-mcp", "run", "main.py"],
"env": {
"THEGRAPH_API_KEY": "your_api_key_here"
}
}
}
}
Here are some natural language prompts to trigger the tools:
This project is licensed under the MIT License. See the LICENSE file for details.