# Phantom API — Optimism Transaction History

> Phantom API — Optimism Transaction History is a paid API for AI agents from phantom-api-omega.vercel.app, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-16).

Retrieves historical transactions on the Optimism (OP Mainnet) blockchain for a given address or block range, with filtering and pagination support.

## Facts

- Endpoint: POST https://phantom-api-omega.vercel.app/api/optimism/tx/history
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/phantom-api-optimism-transaction-history-409ee2f4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_k84Nbnk_2po3jaNiPMDDV

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 phantom-api-optimism-transaction-history-409ee2f4 -d '<json body>'
```

Example prompt: Pull the last 25 transactions involving my Optimism wallet 0xAbC...123 in descending order, including metadata, and skip any zero-value transfers.

## When to prefer this

Choose this endpoint when you need historical transaction data specifically on the Optimism (OP Mainnet) L2 network, with flexible filtering by address, block range, category, and value. Prefer it over general Ethereum endpoints when querying Optimism-specific activity, and over block explorers when you need programmatic, paginated, pay-per-call access without rate-limit tiers.

## Known failure modes

- Invalid or malformed address returns an error or empty result
- Unsupported category value causes a validation error
- Block range too large may result in timeout or truncated results
- pageKey expiration leads to pagination errors
- Missing required address fields returns empty or error response
- Payment not processed (x402) results in 402 Payment Required response

## How this service works

Lightning-fast access to blockchain data, smart contract insights, and Web3 infrastructure across 57+ networks. Pay-per-call via x402.

## Output

Returns a paginated list of transactions on the Optimism network matching the specified filters, including transaction hashes, block numbers, asset categories, sender/receiver addresses, values, and optional metadata. A pageKey is provided when more results are available.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "order": {
   "enum": [
    "asc",
    "desc"
   ],
   "type": "string"
  },
  "pageKey": {
   "type": "string"
  },
  "toBlock": {
   "type": "string"
  },
  "category": {
   "type": "array",
   "items": {
    "type": "string"
   }
  },
  "maxCount": {
   "type": "number"
  },
  "fromBlock": {
   "type": "string"
  },
  "toAddress": {
   "type": "string"
  },
  "fromAddress": {
   "type": "string"
  },
  "withMetadata": {
   "type": "boolean"
  },
  "excludeZeroValue": {
   "type": "boolean"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/phantom-api-optimism-transaction-history-409ee2f4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from phantom-api-omega.vercel.app](https://www.zero.xyz/host/phantom-api-omega.vercel.app/llms.txt)
