Aller au contenu
GET /v1/blocks

The most recent blocks

Essayez-le en direct

10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.

En-têtes personnalisés (facultatif)
api.oanor.com/mempool-api

Ça marche. Récupérez une clé API et utilisez-la dans votre projet.

Obtenez une clé API

Extraits de code

curl "https://api.oanor.com/mempool-api/v1/blocks" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/mempool-api/v1/blocks", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/mempool-api/v1/blocks");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/mempool-api/v1/blocks",
    headers={"x-oanor-key": "oanor_test_..."}
)

Exemple de réponse

Une réponse réelle de ce endpoint, capturée lors du dernier contrôle de santé.

{
    "data": {
        "count": 15,
        "blocks": [
            {
                "bits": 386008719,
                "hash": "00000000000000000000ca26e1b2c9ac55324209c6359ba124122d46c1dfacbd",
                "pool": "MARA Pool",
                "size": 1604000,
                "nonce": 2353618982,
                "height": 952789,
                "reward": 314001818,
                "weight": 3993095,
                "version": 662069248,
                "tx_count": 5055,
                "fee_range": [
                    0.5857142857142857,
                    0.6132142857142857,
                    0.6188571428571429,
                    0.6385714285714286,
                    1.0857142857142856,
                    2.315315315315315,
                    50
                ],
                "timestamp": 1780880962,
                "difficulty": 138955357012247.3,
                "median_fee": 1,
                "total_fees": 1501818,
                "merkle_root": "0d354f298792189dbf3c69ba68d541034e0d6b4dc5c7282b6cc47e3d54a9b339",
                "previous_block": "00000000000000000000470626c3e621eb50c928bf9d42ca9315b1b13027fc11"
            },
            {
                "bits": 386008719,
                "hash": "00000000000000000000470626c3e621eb50c928bf9d42ca9315b1b13027fc11",
                "pool": "Foundry USA",
                "size": 1616051,
                "nonce": 2734003080,
                "height": 952788,
                "reward": 313353970,
                "weight": 3993554,
                "version": 692166656,
                "tx_count": 6062,
                "fee_range": [
                    0.539568345323741,
                    0.5643507972665148,
                    0.5728571428571428,
                    0.7345480528760272,
                    0.89,
                    1.0314285714285714,
                    20
                ],
                "timestamp": 1780880325,
                "difficulty": 138955357012247.3,
                "median_fee": 0.7403571428571427,
                "total_fees": 853970,
                "merkle_root": "6768416c621eb580cbe6907558e74b5776242486cbc74ecff0107ec6eefd910e",
                "previous_block": "000000000000000000014a273ed0b622faf17ea5974e69d3b3fbce32710c4a89"
            },
            {
                "bits": 386008719,
                "hash": "000000000000000000014a273ed0b622faf17ea5974e69d3b3fbce32710c4a89",
                "pool": "F2Pool",
                "size": 1580697,
                "nonce": 1270580072,
                "height": 952787,
                "reward": 314934545,
                "weight": 3997602,
                "version": 738197504,
                "tx_count": 4169,
                "fee_range": [
                    1.1691297208538587,
                    1.2168923159687977,
                    1.244093357271095,
                    1.3991853360488797,
                    2.409252669039146,
                    3.52428810720268,
                   
…