# Bitcoin Latest Block

> Bitcoin Latest Block is a paid API for AI agents from diamond.btc-intel.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-11-21).

Returns the most recent Bitcoin block's height, hash, age, transaction count, total fees, fee-rate percentiles, size, weight, and subsidy.

## Facts

- Endpoint: GET https://diamond.btc-intel.workers.dev/api/x402/block?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-21
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/bitcoin-latest-block-6cf509d8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ER6i20GJmF94Fshr5c1EX

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 bitcoin-latest-block-6cf509d8
```

Example prompt: What does the latest Bitcoin block look like — give me the height, hash, age, transaction count, total fees, fee-rate percentiles, and block size right now.

## When to prefer this

Use this endpoint when you need a single, real-time snapshot of the most recent Bitcoin block including fee-rate percentiles and on-chain activity metrics. Prefer it over block explorer scraping or running a full node when you need structured, pay-per-call data with no infrastructure overhead. It is especially useful for fee estimation, blockchain monitoring dashboards, and alerting pipelines that need current mempool and block statistics.

## Known failure modes

- Node temporarily unavailable — 5xx error if the backend Bitcoin node is syncing or offline
- Stale data if block propagation is delayed to the node
- Payment required (402) if the x402 micropayment header is missing or insufficient
- Rate limiting if the API key or wallet is exhausted

## How this service works

The latest Bitcoin block: height, hash, age, transaction count, total fees, fee-rate percentiles, size, weight and subsidy.

## Output

A JSON object containing the latest Bitcoin block's height (integer), age in minutes, product label, transaction count, total fees in BTC, fee-rate percentiles as an array of sat/vB values (e.g. 10th, 25th, 50th, 75th, 90th percentile), block size, block weight, and miner subsidy.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "properties": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "height": 974953,
  "age_min": 4.1,
  "product": "latest_block",
  "tx_count": 3812,
  "total_fee_btc": 0.0412,
  "feerate_percentiles_sat_vb": [
   1,
   2,
   3,
   5,
   9
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/bitcoin-latest-block-6cf509d8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from diamond.btc-intel.workers.dev](https://www.zero.xyz/host/diamond.btc-intel.workers.dev/llms.txt)
