published

The Graph API

The Graph API provides developers free access to blockchain data, enabling efficient queries using GraphQL for dApp development and analytics.

Developed by The Graph Foundation

99.90%Uptime
180msLatency
3.1kStars
API KeyAuth
NoCredit Card
GraphQLStyle
v1Version
API Endpoints

Reference for available routes, request structures, and live examples.

Query blockchain data using The Graph

Full Endpoint URL
https://api.thegraph.com/subgraphs/name/uniswap/uniswap-v2
Implementation Example
curl -X POST 'https://api.thegraph.com/subgraphs/name/uniswap/uniswap-v2' \
  -H 'Authorization: Bearer YOUR_API_KEY'
Request Payload
{
  "query": "{ pairs(first: 5) { id token0 { symbol } } }"
}
Expected Response
{
  "data": {
    "pairs": [
      {
        "id": "0x...",
        "token0": {
          "symbol": "ETH"
        }
      }
    ]
  }
}
Version:v1
Limit:100,000 requests/month (free tier)
Real-World Applications
  • Creating DeFi dashboards to display real-time token dataOptimized Capability
  • Building NFT marketplaces to showcase digital assetsOptimized Capability
  • Developing blockchain explorers for transaction trackingOptimized Capability
  • Integrating analytics tools for smart contract insightsOptimized Capability
  • Constructing decentralized applications (dApps) requiring on-chain data accessOptimized Capability
Advantages
  • Decentralized and reliable indexing
  • Real-time updates via subscriptions
  • Supports complex GraphQL queries for flexibility
  • Official SDKs for easy integration
  • Wide support for Ethereum and Polygon networks
Limitations
  • Requires understanding of GraphQL
  • API key required for access
  • No official rate limits published widely
  • Limited to supported blockchains and subgraphs
  • Advanced queries can be complex to optimize

FAQs

API Specifications

v1
Pricing Model
Tiered subscription with free tier and paid plans based on usage
Credit Card
Not Required
Response Formats
JSON
Supported Languages
6 Languages
SDK Support
JavaScript, Go
Time to Hello World

Minutes to setup API key and SDKs

Rate Limit

5000 requests per minute

Free Tier Usage

Free tier allows up to 500,000 queries per month with access to all public subgraphs and standard rate limits.

Use Case: Best For

Developers building dApps, DeFi tools, NFT platforms, and blockchain analytics needing real-time indexed data

Not Recommended For

Use cases requiring private blockchain data indexing or extremely high-frequency trading data

#graphql#blockchain-indexing#ethereum-queries#the-graph

Explore Related APIs

Discover similar APIs to The Graph API

View All APIs
PUBLIC

Covalent API

The Covalent API offers seamless access to aggregated blockchain data from various networks, enabling developers to build multi-chain applications efficiently.

BlockchainView Details
PUBLIC

Etherscan API

The Etherscan API offers developers free access to Ethereum blockchain data, suitable for applications like crypto wallets, DeFi, and analytics tools.

BlockchainView Details
PUBLIC

MEXC API

The MEXC API offers developers free access to real-time cryptocurrency market data, enabling the creation of trading bots and financial applications.

BlockchainView Details