diff --git a/website/src/pages/en/token-api/faq.mdx b/website/src/pages/en/token-api/faq.mdx index 6178aee33e86..dd2e92ff797a 100644 --- a/website/src/pages/en/token-api/faq.mdx +++ b/website/src/pages/en/token-api/faq.mdx @@ -8,19 +8,27 @@ Get fast answers to easily integrate and scale with The Graph's high-performance ### What blockchains does the Token API support? -Currently, the Token API supports Ethereum, Binance Smart Chain (BSC), Polygon, Optimism, Base, and Arbitrum One. +Currently, the Token API supports Ethereum, Binance Smart Chain (BSC), Polygon, Optimism, Base, Unichain, and Arbitrum One. -### Why isn't my API key from The Graph Market working? +### How do I authenticate requests to the Token API? Why isn't my API key from The Graph Market working? -Be sure to use the Access Token generated from the API key, not the API key itself. An access token can be generated from the dashboard on The Graph Market using the dropdown menu next to each API key. +Authentication is managed via API tokens obtained through [The Graph Market](https://thegraph.market/). Be sure to use the API Token generated from the API key, not the API key itself. An API token can be found on The Graph Market dashboard next to each API key. JWT tokens issued by [Pinax](https://pinax.network/en), a core developer of The Graph, are also supported. ### How current is the data provided by the API relative to the blockchain? The API provides data up to the latest finalized block. -### How do I authenticate requests to the Token API? +### How do I retrieve token prices? -Authentication is managed via JWT tokens obtained through The Graph Market. JWT tokens issued by [Pinax](https://pinax.network/en), a core developer of The Graph, are also supported. +By default, token prices are returned with token-related responses, including token balances, token transfers, token metadata, and token holders. Historical prices are available with the Open-High-Low-Close (OHLC) endpoints. + +### Does the Token API support historical token data? + +The Token API supports historical token balances with the `/historical/balances/evm/{address}` endpoint. Query historical price data by pool at `/ohlc/pools/evm/{pool}` and by contract at `/ohlc/prices/evm/{contract}`. + +### What exchanges does the Token API use for token prices? + +The Token API currently tracks prices on Uniswap v2 and Uniswap v3, with plans to support additional exchanges in the future. ### Does the Token API provide a client SDK? @@ -36,7 +44,7 @@ Yes, improvements to provide data closer to the chain head are planned. Feedback ### Are there plans to support additional use cases such as NFTs? -The Graph ecosystem is actively determining the [roadmap](https://thegraph.com/blog/token-api-the-graph/) for additional use cases, including NFTs. Please provide feedback on specific features you would like prioritized on [Discord](https://discord.gg/graphprotocol). +NFT endpoints are planned for the near future. The Graph ecosystem is actively determining the [roadmap](https://thegraph.com/blog/token-api-the-graph/) for additional use cases. Please provide feedback on specific features you would like prioritized on [Discord](https://discord.gg/graphprotocol). ## MCP / LLM / AI Topics @@ -60,17 +68,17 @@ You can find the code for the MCP client in [The Graph's repo](https://github.co Check that you included the `Authorization: Bearer ` header with the correct, non-expired token. Common issues include using the API key instead of generating a new JWT, forgetting the "Bearer" prefix, using an incorrect token, or omitting the header entirely. Ensure you copied the JWT exactly as provided by The Graph Market. -### Are there rate limits or usage costs?\*\* +### Are there rate limits or usage costs? During Beta, the Token API is free for authorized developers. While specific rate limits aren't documented, reasonable throttling exists to prevent abuse. High request volumes may trigger HTTP 429 errors. Monitor official announcements for future pricing changes after Beta. -### What networks are supported, and how do I specify them? +### How do I specify a network? -You can query available networks with [this link](https://token-api.thegraph.com/#tag/monitoring/GET/networks). A full list of network IDs accepted by The Graph can be found on [The Graph's Networks](https://thegraph.com/docs/en/supported-networks/). The API supports Ethereum mainnet, Binance Smart Chain, Base, Arbitrum One, Optimism, and Polygon/Matic. Use the optional `network_id` parameter (e.g., `mainnet`, `bsc`, `base`, `arbitrum-one`, `optimism`, `matic`) to target a specific chain. Without this parameter, the API defaults to Ethereum mainnet. +You can query available networks with [this link](https://token-api.thegraph.com/#tag/monitoring/GET/networks). A full list of the exact network IDs accepted by The Graph can be found on [The Graph's Networks](https://thegraph.com/docs/en/supported-networks/). Use the optional `network_id` parameter (e.g., `mainnet`, `bsc`, `base`, `arbitrum-one`, `optimism`, `matic`, `unichain`) to target a specific chain. Without this parameter, the API defaults to Ethereum mainnet. ### Why do I only see 10 results? How can I get more data? -Endpoints cap output at 10 items by default. Use pagination parameters: `limit` (up to 500) and `page` (1-indexed). For example, set `limit=50` to get 50 results, and increment `page` for subsequent batches (e.g., `page=2` for items 51-100). +Endpoints cap output at 10 items by default. Use pagination parameters: `limit` and `page` (1-indexed) to return more results. For example, set `limit=50` to get 50 results, and increment `page` for subsequent batches (e.g., `page=2` for items 51-100). ### How do I fetch older transfer history?