# BTC Mining Economics (Hashprice, Hashrate, Difficulty, Revenue Split)

> BTC Mining Economics (Hashprice, Hashrate, Difficulty, Revenue Split) is a paid API for AI agents from api.chainmarket-api.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-11-02).

Returns Bitcoin mining economics: hashprice in USD and sats per TH/s/day, block reward split (subsidy vs fees) over last 144 blocks, network hashrate, difficulty, and BTC price.

## Facts

- Endpoint: GET https://api.chainmarket-api.workers.dev/api/crypto/btc-mining-economics?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/btc-mining-economics-hashprice-hashrate-difficulty-revenue-split-cf954714
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_X6Oq48VKqWDrga0_lOTCD

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 btc-mining-economics-hashprice-hashrate-difficulty-revenue-split-cf954714
```

Example prompt: What's the current Bitcoin hashprice in both USD and sats per TH/s per day, and how is the block reward split between the base subsidy and transaction fees over the last 144 blocks?

## When to prefer this

Choose this endpoint when you need a single, pre-computed snapshot of Bitcoin mining economics — hashprice, revenue split, difficulty, and BTC price — without having to aggregate raw blockchain data yourself. Ideal for mining profitability calculators, miner dashboards, or any agent that needs current BTC mining metrics in one call. Prefer it over raw RPC endpoints when you want the hashprice formula already applied.

## Known failure modes

- Upstream BTC node or data source unavailable — returns 5xx or empty response
- Stale data if the Cloudflare Worker cache hasn't refreshed recently
- Rate limiting or payment verification failure for x402-gated calls
- Network timeout if the worker can't reach its upstream source within the response window

## How this service works

Bitcoin mining economics: Hashprice in USD and sats per TH/s per day, revenue split (subsidy vs fees) over the last 144 blocks, network hashrate and difficulty, and BTC price. Formula: dailyBlocksPerTh = (1e12 * 86400) / (diff * 2^32); hashprice = dailyBlocksPerTh * (totalRewardSat / 144).

## Output

Returns a JSON object containing: hashprice in USD per TH/s per day, hashprice in sats per TH/s per day, total block reward over the last 144 blocks broken down into subsidy and fee components (with percentages), current network hashrate (EH/s or H/s), current difficulty, and spot BTC price in USD.

## 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": [],
     "properties": {}
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/btc-mining-economics-hashprice-hashrate-difficulty-revenue-split-cf954714/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.chainmarket-api.workers.dev](https://www.zero.xyz/host/api.chainmarket-api.workers.dev/llms.txt)
