{"uid":"cap_o7qIPCqRDd6AUqkbkJuy8","slug":"x402-gateway-production-up-railway-app-c24ec8be","name":"DEX Token Prices with OHLC Data","description":"Real-time DEX-derived token prices with OHLC data — up to 200 tokens per request","url":"https://x402-gateway-production.up.railway.app/api/token/prices","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","bodyType","body","method"],"properties":{"body":{"type":"object","required":["tokens"],"properties":{"tokens":{"type":"array","items":{"type":"object","required":["chain","token_address"],"properties":{"chain":{"type":"string","example":"ethereum"},"token_address":{"type":"string","example":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}},"additionalProperties":false},"example":[{"chain":"ethereum","token_address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}],"minItems":1,"description":"Array of token objects with chain and token_address"}},"additionalProperties":false},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false}}},"responseSchema":null,"example":{"request":{"tokens":[{"chain":"ethereum","token_address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"},{"chain":"ethereum","token_address":"0x6B175474E89094C44Da98b954EedeAC495271d0F"},{"chain":"ethereum","token_address":"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"}]},"response":{"items":[{"low":0.9995844071907223,"high":0.9996036365160565,"open":0.9995844071907223,"chain":"ethereum","close":0.9996036365160565,"price":0.9996036365160565,"address":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48","decimals":6,"timestamp":"2026-06-13T04:16:23Z"},{"low":0.999754302060251,"high":0.999758303130008,"open":0.999758303130008,"chain":"ethereum","close":0.999754302060251,"price":0.999754302060251,"address":"0x6b175474e89094c44da98b954eedeac495271d0f","decimals":18,"timestamp":"2026-06-13T04:16:47Z"},{"low":1663.723305871481,"high":1664.039473243368,"open":1663.9279443797539,"chain":"ethereum","close":1664.039473243368,"price":1664.039473243368,"address":"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2","decimals":18,"timestamp":"2026-06-13T04:16:47Z"}]}},"exampleRequest":{"tokens":[{"chain":"ethereum","token_address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"},{"chain":"ethereum","token_address":"0x6B175474E89094C44Da98b954EedeAC495271d0F"},{"chain":"ethereum","token_address":"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"}]},"tags":["x402"],"displayCostAmount":"0.005000","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005000/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_phrE-ViAzq6YgBTzJph3a","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Fetches real-time DEX-derived spot prices and OHLC candlestick data for up to 200 tokens per request","exampleAgentPrompt":"Can you get me the current DEX-derived prices and OHLC data for these tokens: ETH, BTC, UNI, AAVE, and LINK?","exampleUseCases":null,"resultDescription":"Returns real-time spot prices and OHLC (open, high, low, close) candlestick data sourced from decentralized exchange liquidity pools for each requested token, supporting up to 200 tokens per request.","failureModes":["Request exceeds 200 tokens — returns error indicating batch size limit","Invalid or unrecognized token address/symbol — returns null or error for that token","DEX liquidity data unavailable for obscure tokens — may return empty or stale data","Payment not processed (x402 payment required) — returns 402 Payment Required","Network timeout from DEX data aggregation — returns 503 or timeout error"],"whenToPreferThis":"Use this endpoint when you need real-time, DEX-sourced token prices (not centralized exchange prices) with OHLC candlestick data, especially for DeFi tokens or long-tail assets that may not be listed on CEXs. Ideal for batch lookups of up to 200 tokens in a single call. Prefer this over CEX price feeds when DEX liquidity data or on-chain pricing is specifically required.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T12:34:16.624Z","isFirstParty":false}