# DEX Spread History (1-Minute Buckets, Up to 24h)

> DEX Spread History (1-Minute Buckets, Up to 24h) is a paid API for AI agents from api.agentfeeds.jp, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Returns bulk historical 1-minute DEX spread statistics for a trading pair, covering up to 24 hours, for slippage calibration and backtesting.

## Facts

- Endpoint: GET https://api.agentfeeds.jp/v1/dex/spreads/history
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/dex-spread-history-1-minute-buckets-up-to-24h-bc7508f8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_oCyEeaX4LhR8iCsIu5XY9

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 dex-spread-history-1-minute-buckets-up-to-24h-bc7508f8
```

Example prompt: Pull the last 6 hours of 1-minute DEX spread history for WETH/USDC so I can calibrate slippage for my backtesting model.

## When to prefer this

Use this endpoint when you need a bulk window of historical 1-minute spread statistics (up to 24h) for a DEX pair in a single call — ideal for backtesting workflows or slippage model calibration where you want descriptive statistics over time rather than a single real-time snapshot.

## Known failure modes

- Missing required 'pair' parameter returns a 400 error
- Invalid pair format (e.g. unsupported token pair) returns a 404 or empty dataset
- 'hours' value outside 0.25–24 range may return a validation error
- No historical data available for the requested window returns an empty result set
- Payment not processed (x402 unpaid) returns a 402 Payment Required response

## How this service works

Bulk historical window (up to 24h) of 1-minute DEX spread statistics for a given pair, in one call. Useful for slippage calibration and backtesting. Descriptive statistics only; not investment advice.

## Output

A time-series of 1-minute-bucket spread descriptive statistics (e.g. mean, min, max, std) for the requested DEX pair, covering up to 24 hours of history. Useful for slippage calibration and quantitative backtesting; explicitly not investment advice.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "pair"
     ],
     "properties": {
      "pair": {
       "type": "string",
       "description": "e.g. 'WETH/USDC'"
      },
      "hours": {
       "type": "number",
       "description": "0.25-24, default 1"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/dex-spread-history-1-minute-buckets-up-to-24h-bc7508f8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agentfeeds.jp](https://www.zero.xyz/host/api.agentfeeds.jp/llms.txt)
