query_subgraph
ActiveTool of The Graph
Run a GraphQL query against a subgraph on The Graph network. subgraph_id is the deployment hash (starts with "Qm…" or the new "0x…" subgraph ID from thegraph.com/explorer). Returns the GraphQL `data` block plus any errors.
Parameters schema
{
"type": "object",
"examples": [
{
"query": "{ pools(first: 5) { id feeTier liquidity } }",
"subgraph_id": "5zvR82QoaXYFyDEKLZ9t6v9adgnptxYpKpSbxtgVENFV"
},
{
"query": "query GetPoolData($poolId: String!) { pool(id: $poolId) { id feeTier liquidity volume } }",
"variables": {
"poolId": "0x8ad599c3a0ff1de082011efddc58f1908eb6e6d8"
},
"subgraph_id": "5zvR82QoaXYFyDEKLZ9t6v9adgnptxYpKpSbxtgVENFV"
}
],
"required": [
"subgraph_id",
"query"
],
"properties": {
"query": {
"type": "string",
"description": "GraphQL query string"
},
"variables": {
"type": "object",
"description": "Optional GraphQL variables object"
},
"subgraph_id": {
"type": "string",
"description": "Subgraph deployment ID (look up at thegraph.com/explorer; e.g., Uniswap v3 Ethereum is \"5zvR82QoaXYFyDEKLZ9t6v9adgnptxYpKpSbxtgVENFV\")"
}
}
}No endpoints wrapped at confidence ≥ 0.50.
Parent server
The Graph
https://github.com/pipeworx-io/mcp-the-graph
1/7 registries