# AgenticFi Token Price History

> AgenticFi Token Price History is a paid API for AI agents from defi-api.agenticfi.wtf, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Returns historical price data for a token over a specified number of days using its CoinGecko ID

## Facts

- Endpoint: GET https://defi-api.agenticfi.wtf/api/token/price-history/%7Bid%7D
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agenticfi-token-price-history-6a81f40e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_p6PGfY23qNZNo9SYqQDYl

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agenticfi-token-price-history-6a81f40e
```

Example prompt: Can you pull the price history for ethereum over the last 30 days so I can see how it's been trending?

## When to prefer this

Choose this endpoint when you need historical token price data for analysis, charting, or backtesting, especially within an AI agent workflow that already uses x402 micropayments on Base. Prefer this over direct CoinGecko calls when operating in an agentic DeFi context with pay-per-call billing already set up.

## Known failure modes

- Invalid CoinGecko token ID returns an error or empty result
- Unsupported 'days' value outside allowed set (1, 7, 14, 30, 90, 365) may return error or default behavior
- Token not listed on CoinGecko returns 404 or empty data
- Payment failure via x402/USDC results in 402 response and no data returned
- Rate limiting or upstream CoinGecko API unavailability causes 503 or timeout

## How this service works

OHLCV candles for a token - supports 1d, 7d, 14d, 30d, 90d, 365d ranges

## Output

A time series of historical price data for the specified token, showing price points over the requested number of days (e.g. 1, 7, 14, 30, 90, or 365 days). Data is sourced from CoinGecko and returned in a structured format suitable for charting or analysis.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "pathParams",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "pathParams": {
     "type": "object",
     "required": [
      "id"
     ],
     "properties": {
      "id": {
       "type": "string",
       "title": "id (required)",
       "description": "Required. CoinGecko token ID.\nTry one of these 10 examples: bitcoin, ethereum, solana, chainlink, uniswap, aave, maker, dogecoin, pepe, arbitrum"
      }
     }
    },
    "queryParams": {
     "type": "object",
     "required": [
      "id"
     ],
     "properties": {
      "id": {
       "type": "string",
       "title": "id (required)",
       "description": "Required. CoinGecko token ID.\nTry one of these 10 examples: bitcoin, ethereum, solana, chainlink, uniswap, aave, maker, dogecoin, pepe, arbitrum"
      },
      "days": {
       "type": "string",
       "title": "days (optional)",
       "description": "Optional. Number of days (1, 7, 14, 30, 90, 365) Examples: 1, 7, 30, 365"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agenticfi-token-price-history-6a81f40e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from defi-api.agenticfi.wtf](https://www.zero.xyz/host/defi-api.agenticfi.wtf/llms.txt)
