{"uid":"cap_YZoyzEIvA2XyJcnuDtvT7","slug":"agents-allium-so-72d59a50","name":"Allium Historical Token Prices","description":"API request: /api/v1/developer/prices/history","url":"https://agents.allium.so/api/v1/developer/prices/history","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"addresses":{"type":"array","items":{"type":"object","required":["token_address","chain"],"properties":{"chain":{"type":"string","description":"Blockchain network (e.g. ethereum, solana, base)"},"token_address":{"type":"string","description":"Token contract address"}}}},"end_timestamp":{"type":"string","format":"date-time","description":"ISO 8601 timestamp"},"start_timestamp":{"type":"string","format":"date-time","description":"ISO 8601 timestamp"},"time_granularity":{"enum":["15s","1m","5m","1h","1d"],"type":"string","description":"Time granularity for price buckets"}}},"responseSchema":{"type":"json","example":{"items":[{"mint":"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2","chain":"ethereum","prices":[{"low":2493,"high":2505,"open":2495,"close":2500.5,"price":2500.5,"timestamp":"2025-06-17T10:00:00Z"}],"decimals":18}]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","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.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_EMDPyZ7VGk8rlUBcrJ2Wx","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Retrieves historical price data for onchain tokens over a specified time range","exampleAgentPrompt":"Pull the historical price data for ETH on Ethereum from January 1 2024 to March 31 2024 using Allium — I need daily prices to calculate PnL.","exampleUseCases":[{"title":"Quarterly portfolio PnL calculation","prompt":"I need to figure out how much I made or lost on my DeFi positions last quarter — can you pull the historical price data for USDC, WBTC, and ETH on Ethereum from October 1 to December 31 2024 using Allium so I can run the PnL numbers?"},{"title":"Backtest a token trading strategy","prompt":"I want to backtest a simple moving average strategy on MATIC over the last 6 months — grab me daily historical prices from Allium for MATIC on Polygon from July 1 to December 31 2024 so I can run the analysis."},{"title":"Chart DeFi token price history","prompt":"Can you pull the price history for UNI on Ethereum from January through June 2024 using Allium? I want to chart how the price moved over that period and spot any major trends or dips."}],"resultDescription":"Returns a time series of historical token prices for the requested asset, including price values and associated timestamps over the specified range, suitable for charting, PnL calculations, or trend analysis.","failureModes":["Unknown token symbol or address returns 404 or empty result","Invalid date range or malformed timestamps return 400 error","Unsupported chain returns error or empty dataset","Payment of 0.02 USDC not completed triggers 402 payment required","Rate limiting or quota exceeded returns 429","Date range too large may result in timeout or truncated results"],"whenToPreferThis":"Use this endpoint when you need a time series of token prices over a historical period — for PnL calculations, backtesting, charting, or auditing past portfolio values. Prefer this over the 'At Timestamp' endpoint when you need multiple price points across a range rather than a single snapshot, and over the 'latest prices' endpoint when you need past rather than current data.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T18:34:12.643Z","isFirstParty":false}