{"openapi":"3.1.0","info":{"title":"Bitcoin Mining API","version":"1.0.0","description":"Live Bitcoin mining and hashrate analytics, built on the open mempool.space dataset — the mining layer, not address or mempool data: the mining-pool dominance ranking by share of blocks mined over a period, the current network hashrate and difficulty plus their history, the history of difficulty adjustments with each retarget's percentage change, and block-reward economics over the last N blocks (total and average reward, fees and transactions).","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/mining-api","description":"oanor gateway"}],"tags":[{"name":"Pools"},{"name":"Hashrate"},{"name":"Difficulty"},{"name":"Rewards"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/pools":{"get":{"operationId":"get_v1_pools","tags":["Pools"],"summary":"Mining-pool dominance ranking over a period","description":"","parameters":[{"name":"period","in":"query","required":false,"description":"Period: 24h, 3d, 1w, 1m, 3m, 6m, 1y, 2y, 3y, all","schema":{"type":"string"},"example":"1w"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"pools":[{"name":"Foundry USA","rank":1,"slug":"foundryusa","share_pct":24.66,"blocks_mined":218,"empty_blocks":0,"avg_match_rate":99.48},{"name":"AntPool","rank":2,"slug":"antpool","share_pct":17.99,"blocks_mined":159,"empty_blocks":0,"avg_match_rate":98.64},{"name":"F2Pool","rank":3,"slug":"f2pool","share_pct":12.1,"blocks_mined":107,"empty_blocks":0,"avg_match_rate":99.64},{"name":"ViaBTC","rank":4,"slug":"viabtc","share_pct":9.84,"blocks_mined":87,"empty_blocks":0,"avg_match_rate":99.73},{"name":"SpiderPool","rank":5,"slug":"spiderpool","share_pct":9.5,"blocks_mined":84,"empty_blocks":0,"avg_match_rate":99.12},{"name":"MARA Pool","rank":6,"slug":"marapool","share_pct":5.66,"blocks_mined":50,"empty_blocks":0,"avg_match_rate":99.65},{"name":"Luxor","rank":7,"slug":"luxor","share_pct":4.64,"blocks_mined":41,"empty_blocks":0,"avg_match_rate":98.65},{"name":"SECPOOL","rank":8,"slug":"secpool","share_pct":4.3,"blocks_mined":38,"empty_blocks":0,"avg_match_rate":98.87},{"name":"OCEAN","rank":9,"slug":"ocean","share_pct":3.28,"blocks_mined":29,"empty_blocks":0,"avg_match_rate":91.1},{"name":"Binance Pool","rank":10,"slug":"binancepool","share_pct":1.81,"blocks_mined":16,"empty_blocks":0,"avg_match_rate":99.4},{"name":"SBI Crypto","rank":11,"slug":"sbicrypto","share_pct":1.81,"blocks_mined":16,"empty_blocks":0,"avg_match_rate":84.5},{"name":"Braiins Pool","rank":12,"slug":"braiinspool","share_pct":1.47,"blocks_mined":13,"empty_blocks":0,"avg_match_rate":98.27},{"name":"Unknown","rank":13,"slug":"unknown","share_pct":1.13,"blocks_mined":10,"empty_blocks":0,"avg_match_rate":95.31},{"name":"ULTIMUSPOOL","rank":14,"slug":"ultimuspool","share_pct":0.79,"blocks_mined":7,"empty_blocks":0,"avg_match_rate":98.54},{"name":"BTC.com","rank":15,"slug":"btccom","share_pct":0.57,"blocks_mined":5,"empty_blocks":0,"avg_match_rate":99.35},{"name":"NiceHash","rank":16,"slug":"nicehash","share_pct":0.23,"blocks_mined":2,"empty_blocks":0,"avg_match_rate":99.7},{"name":"Poolin","rank":17,"slug":"poolin","share_pct":0.11,"blocks_mined":1,"empty_blocks":0,"avg_match_rate":100},{"name":"Innopolis Tech","rank":18,"slug":"innopolistech","share_pct":0.11,"blocks_mined":1,"empty_blocks":0,"avg_match_rate":100}],"period":"1w","source":"mempool.space","pool_count":18,"total_blocks":884,"network_hashrate_ehs":941.8446},"meta":{"timestamp":"2026-06-10T14:01:29.089Z","request_id":"558d4177-5fbb-45f4-9d78-1fb77a798dca"},"status":"ok","message":"Pools retrieved successfully","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/hashrate":{"get":{"operationId":"get_v1_hashrate","tags":["Hashrate"],"summary":"Current network hashrate and difficulty plus history","description":"","parameters":[{"name":"period","in":"query","required":false,"description":"Period: 1m, 3m, 6m, 1y, 2y, 3y, all","schema":{"type":"string"},"example":"1m"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"period":"1m","points":31,"source":"mempool.space","hashrate_history":[{"date":"2026-05-11T00:00:00.000Z","hashrate_ehs":993.9411},{"date":"2026-05-12T00:00:00.000Z","hashrate_ehs":1107.9023},{"date":"2026-05-13T00:00:00.000Z","hashrate_ehs":864.9438},{"date":"2026-05-14T00:00:00.000Z","hashrate_ehs":916.314},{"date":"2026-05-15T00:00:00.000Z","hashrate_ehs":987.446},{"date":"2026-05-16T00:00:00.000Z","hashrate_ehs":968.6996},{"date":"2026-05-17T00:00:00.000Z","hashrate_ehs":1029.7729},{"date":"2026-05-18T00:00:00.000Z","hashrate_ehs":960.3486},{"date":"2026-05-19T00:00:00.000Z","hashrate_ehs":936.4806},{"date":"2026-05-20T00:00:00.000Z","hashrate_ehs":962.9338},{"date":"2026-05-21T00:00:00.000Z","hashrate_ehs":1042.2743},{"date":"2026-05-22T00:00:00.000Z","hashrate_ehs":853.8633},{"date":"2026-05-23T00:00:00.000Z","hashrate_ehs":1063.8837},{"date":"2026-05-24T00:00:00.000Z","hashrate_ehs":1112.3522},{"date":"2026-05-25T00:00:00.000Z","hashrate_ehs":886.353},{"date":"2026-05-26T00:00:00.000Z","hashrate_ehs":1130.3989},{"date":"2026-05-27T00:00:00.000Z","hashrate_ehs":940.3621},{"date":"2026-05-28T00:00:00.000Z","hashrate_ehs":949.1191},{"date":"2026-05-29T00:00:00.000Z","hashrate_ehs":1101.448},{"date":"2026-05-30T00:00:00.000Z","hashrate_ehs":959.2063},{"date":"2026-05-31T00:00:00.000Z","hashrate_ehs":977.2729},{"date":"2026-06-01T00:00:00.000Z","hashrate_ehs":1007.689},{"date":"2026-06-02T00:00:00.000Z","hashrate_ehs":922.2064},{"date":"2026-06-03T00:00:00.000Z","hashrate_ehs":759.8111},{"date":"2026-06-04T00:00:00.000Z","hashrate_ehs":752.8889},{"date":"2026-06-05T00:00:00.000Z","hashrate_ehs":990.5227},{"date":"2026-06-06T00:00:00.000Z","hashrate_ehs":926.821},{"date":"2026-06-07T00:00:00.000Z","hashrate_ehs":830.2274},{"date":"2026-06-08T00:00:00.000Z","hashrate_ehs":806.902},{"date":"2026-06-09T00:00:00.000Z","hashrate_ehs":898.3852},{"date":"2026-06-10T00:00:00.000Z","hashrate_ehs":860.8283}],"current_difficulty_t":138.9554,"current_hashrate_ehs":858.0876},"meta":{"timestamp":"2026-06-10T14:01:29.223Z","request_id":"20ccce86-e95f-4661-9008-52f5d7f4fe76"},"status":"ok","message":"Hashrate retrieved successfully","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/difficulty":{"get":{"operationId":"get_v1_difficulty","tags":["Difficulty"],"summary":"History of difficulty adjustments with change percent","description":"","parameters":[{"name":"period","in":"query","required":false,"description":"Period: 1m, 3m, 6m, 1y, 2y, 3y, all","schema":{"type":"string"},"example":"3m"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"count":6,"period":"3m","source":"mempool.space","adjustments":[{"date":"2026-05-29T10:29:46.000Z","height":951552,"change_pct":1.719,"difficulty_t":138.9554},{"date":"2026-05-15T16:01:24.000Z","height":949536,"change_pct":3.121,"difficulty_t":136.6071},{"date":"2026-05-02T02:06:45.000Z","height":947520,"change_pct":-2.3031,"difficulty_t":132.472},{"date":"2026-04-17T17:55:37.000Z","height":945504,"change_pct":-2.4265,"difficulty_t":135.5949},{"date":"2026-04-03T09:28:40.000Z","height":943488,"change_pct":3.867,"difficulty_t":138.9669},{"date":"2026-03-20T21:54:19.000Z","height":941472,"change_pct":-7.7557,"difficulty_t":133.7931}]},"meta":{"timestamp":"2026-06-10T14:01:29.355Z","request_id":"845d60d4-075a-4073-bf54-4839f5cdbd2a"},"status":"ok","message":"Difficulty retrieved successfully","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/rewards":{"get":{"operationId":"get_v1_rewards","tags":["Rewards"],"summary":"Block-reward economics over the last N blocks","description":"","parameters":[{"name":"blocks","in":"query","required":false,"description":"Number of recent blocks (1-1000)","schema":{"type":"string"},"example":"144"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"blocks":144,"source":"mempool.space","total_tx":666658,"end_block":953111,"avg_fee_btc":0.02290523,"start_block":952968,"fee_share_pct":0.7276,"total_fee_btc":3.29835244,"avg_reward_btc":3.14790523,"total_reward_btc":453.29835244},"meta":{"timestamp":"2026-06-10T14:01:29.847Z","request_id":"ad616be4-b07c-40c2-b497-52dcd119a999"},"status":"ok","message":"Rewards retrieved successfully","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Service metadata and endpoint catalog","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"source":"mempool.space mining API (live)","service":"mining-api","endpoints":{"GET /v1/meta":"This document.","GET /v1/pools":"Mining-pool dominance ranking over a period (period=1w).","GET /v1/rewards":"Block-reward economics over the last N blocks (blocks=144).","GET /v1/hashrate":"Current network hashrate and difficulty plus history (period=1m).","GET /v1/difficulty":"History of difficulty adjustments with change percent (period=3m)."},"description":"Live Bitcoin mining and hashrate analytics as an API, built on the open mempool.space dataset — the mining layer (who secures Bitcoin and how hard), not address, transaction or mempool data. The pools endpoint ranks mining pools by their share of blocks mined over a period; the hashrate endpoint returns the current network hashrate and difficulty plus history; the difficulty endpoint returns the history of difficulty adjustments with each retarget's change; the rewards endpoint returns block-reward economics over the last N blocks (total and average reward, fees and transactions). Live, no key, nothing stored. Distinct from address/transaction/mempool on-chain APIs and from price feeds — this is Bitcoin's mining economics: pool dominance, hashrate, difficulty and reward stats.","upstream_status":"ok","current_hashrate_ehs":858.0876},"meta":{"timestamp":"2026-06-10T14:01:29.947Z","request_id":"895ccbf5-cb4d-4a05-8638-03ef4abb6923"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":10000,"rps_limit":3,"hard_limit":true},{"slug":"basic","name":"Basic","price_cents_month":800,"monthly_call_quota":144000,"rps_limit":8,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":2400,"monthly_call_quota":905000,"rps_limit":15,"hard_limit":true},{"slug":"scale","name":"Scale","price_cents_month":5700,"monthly_call_quota":4750000,"rps_limit":30,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/mining-api"}