# USD Price of a Token at a Past Moment

> USD Price of a Token at a Past Moment is a paid API for AI agents from twin.unykorn.org, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-02).

Returns the USD price of an EVM token contract at a specified Unix timestamp on a supported blockchain

## Facts

- Endpoint: POST https://twin.unykorn.org/token-price-at?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/usd-price-of-a-token-at-a-past-moment-12b07bdc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_kifSZcuAu2dJ6oTK114AC

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 usd-price-of-a-token-at-a-past-moment-12b07bdc -d '<json body>'
```

Example prompt: What was the USD price of the token at contract address 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 on Ethereum at Unix timestamp 1700000000?

## When to prefer this

Choose this endpoint when you need a point-in-time USD price for an EVM-compatible token on one of the ten supported chains (Ethereum, Base, Polygon, Arbitrum, Optimism, BSC, Avalanche, Gnosis, Linea, Scroll). It is ideal for tax calculations, historical portfolio valuation, audit trails, or reconstructing trade economics at a specific past moment. Prefer it over on-chain oracle calls when you need a simple, paid, API-level lookup without writing smart contract code.

## Known failure modes

- Unsupported chain value returns validation error
- Invalid contract address format (non-0x40hex) rejected by schema
- Timestamp too far in the past may lack price data, returning no result or an error
- Network or RPC issues on the target chain may cause lookup failure
- Payment failure via x402 protocol will block the request
- Contract address not a known token on the specified chain may return null or error

## How this service works

USD price of a token at a past moment — Genesis402 / UnyKorn Operator Network

## Output

Returns a JSON object with ok:true, the type field 'token-price-at', the USD price of the token at the requested timestamp, a transaction receipt including tx_hash and receipt_id, and an ISO8601 generated_at timestamp confirming when the response was produced.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "params": {
   "type": "object",
   "properties": {
    "chain": {
     "enum": [
      "ethereum",
      "base",
      "polygon",
      "arbitrum",
      "optimism",
      "bsc",
      "avalanche",
      "gnosis",
      "linea",
      "scroll"
     ],
     "type": "string"
    },
    "contract": {
     "type": "string",
     "pattern": "^0x[0-9a-fA-F]{40}$"
    },
    "timestamp": {
     "type": "integer",
     "minimum": 0
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "type": "token-price-at",
  "receipt": {
   "tx_hash": "0x<64hex>",
   "amount_usd": 0.005,
   "receipt_id": "g402-<16hex>"
  },
  "generated_at": "<iso8601>"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/usd-price-of-a-token-at-a-past-moment-12b07bdc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from twin.unykorn.org](https://www.zero.xyz/host/twin.unykorn.org/llms.txt)
