Blockstream Documentation. Esplora API. API specification for retrieving transactions and blockchain data: suitable for passive, legitimate analysis of your own addresses and test data.

03.09.2026

Blockstream Documentation. Esplora API. API specification for retrieving transactions and blockchain data: suitable for passive, legitimate analysis of your own addresses and test data.

Topics:  Applied cryptography, cryptanalysis of blockchain systems, digital signature (ECDSA/Schnorr) and sidechain (Elements/Liquid) auditing.
Integration format:  Fully compatible with WordPress / HTML5.

Introduction and fundamental basis

Blockstream Esplora’s architecture is a high-performance server-side and client-side blockchain state indexer based on RocksDB/Electrs, exporting a deterministic, RESTful JSON HTTP interface. In the context of modern applied cryptography and cryptographic system auditing, this protocol serves as the standard for extracting immutable blockchain artifacts (raw witnesses, scriptSig, scriptPubKey, commitments).

Using a standardized API allows researchers and security specialists to conduct passive, verifiable transaction analysis without generating active, destructive network requests. The entire analytical framework is built on entropy recovery, vulnerability analysis of pseudorandom number generator (CSPRNG) implementations, nonce reuse analysis in ECDSA schemes, and verification of cryptographic proofs in Confidential Transactions.

1. Category: Transactions (Transactions API)

Transaction endpoints provide access to serialized bytecodes, input/output structures, and block inclusion statuses.

GET /tx/:txid

GET /tx/:txid/hex

GET /tx/:txid/status

GET /tx/:txid/outspend/:vout

POST /tx

The structure  tx deserializes an array  vincontaining  scriptsig,  witness and  sequence, as well as an array  vout with descriptors  scriptpubkey and values  value ​​in satoshis.

\[ s \equiv k^{-1} (z + r \cdot d) \pmod{n} \]
(Basic ECDSA signature equation over the elliptic curve secp256k1)

Cryptanalytic Case Study: Nonce Reuse Attack

Historical fact:  In 2013, on the Android platform (due to a bug in  java.security.SecureRandom) and in a number of transactions in the Bitcoin blockchain (for example, the incident with the Blockchain.info pool in 2014), collisions of the \(k\) parameter occurred when signing two different digests \(z_1\) and \(z_2\) with the same private key \(d\).

Mathematical recovery of the key:  Given two signatures \((r, s_1)\) and \((r, s_2)\), obtained through  GET /tx/:txid/hex:

\[ s_1 – s_2 \equiv k^{-1} (z_1 – z_2) \pmod{n} \implies k \equiv rac{z_1 – z_2}{s_1 – s_2} \pmod{n} \] \[ d \equiv rac{s_1 \cdot k – z_1}{r} \pmod{n} \]

The endpoint  /tx/:txid extracts signature elements  scriptsig_asm or fields  witness, allowing for immediate detection of a \(r\) replay vulnerability as part of an audit of one’s own addresses.

2. Category: Addresses & Scripthashes

Interface for aggregating balances and history of transactions on P2PKH, P2SH, P2WPKH, P2WSH and P2TR descriptors.

GET /address/:address

GET /scripthash/:hash

GET /address/:address/utxo

GET /address/:address/txs/chain[/:last_seen_txid]

To keep requests private without transmitting public addresses, Esplora supports Electrum-compatible SHA-256 scriptPubKey hashing:

\[ H_{ ext{script}} = ext{SHA-256}( ext{scriptPubKey}) \quad ext{(in reverse byte order)} \]

Cryptanalytic precedent: Biased nonces and the grille attack (Hidden Number Problem / LLL)

Historical context:  Analyzing the transaction history of an address through  /address/:address/txs allows one to collect a sequence of signatures \((r_i, s_i, z_i)\). If the random number generator generates nonces with a known bias (e.g., the most significant \(l\) bits of \(k\) are always 0 due to an implementation bug), the system reduces to the hidden number problem (HNP).

\[ k_i — s_i^{-1} r_i \cdot d — s_i^{-1} z_i \equiv 0 \pmod{n} \]

Construction of the Cantor-Babai matrix lattice (of dimension \(m+2\)) and application of the LLL/BKZ basis reduction algorithm leads to complete disclosure of the private key \(d\) even without direct duplicates \(r\).

3. Category: Blocks and Consensus Cryptography (Blocks API)

Endpoints provide verifiable proof of transaction inclusion and Proof-of-Work header metadata.

GET /block/:hash

GET /block/:hash/header

GET /block/:hash/merkle-proof

GET /block-height/:height

\[ ext{Target} = ext{mantissa} imes 256^{( ext{exponent} – 3)}, \quad ext{Difficulty} = rac{T_{ ext{max}}}{T} \] \[ ext{SHA-256}( ext{SHA-256}( ext{Block Header})) < ext{Target} \]

Cryptanalytic Case Study: Merkle Tree Leaf-Node Duplication Vulnerability CVE-2012-2459

Historical fact:  In the Bitcoin Merkle tree structure, if there is an odd number of leaves, the last hash is duplicated: \( ext{Hash}(L_{2n-1} \mathbin{\Vert} L_{2n-1})\).

This created a vulnerability that allowed a block to be created with a mutated transaction tree that had an identical value  merkle_root. Esplora endpoints  /block/:hash/merkle-proof allow  /block/:hash/txids cryptanalysts to mathematically validate the absence of Merkle tree node collisions and the correctness of inclusion proofs.

4. Category: Mempool & Fee Estimation

Real-time analysis of pre-consensus transaction pool.

GET /mempool

GET /mempool/txids

GET /fee-estimates

The endpoint  /mempool returns an array of histograms  fee_histogram as tuples  (feerate, vsize). This provides data for modeling competitive first-level auctions and analyzing the dynamics of Replace-By-Fee (RBF) and CPFP.

5. Category: Elements/Liquid Sidechains and Confidential Transactions

The Esplora specification for Elements networks implements structures with homomorphic encryption of asset and value parameters.

GET /asset/:asset_id

GET /asset/:asset_id/supply

GET /assets/registry

In confidential transactions, public values  value ​​are replaced by Pedersen Commitments and Bulletproofs / Range Proofs:

\[ C = v \cdot G + r \cdot H \pmod p \]
where \(G, H\) are independent generators of the group, \(v\) is the value of the sum, \(r\) is the blinding factor.

Cryptanalytic Fact: Additive Homomorphism and Balance Verification

Thanks to the additive homomorphism property, the verifier checks that the transaction balance is preserved without revealing the amounts:

\[ \sum_{ ext{inputs}} C_i — \sum_{ ext{outputs}} C_j — ext{Fee} \cdot G = 0 \]

The endpoint  /asset/:asset_id/supply aggregates open and blinded emissions, eliminating inflationary collisions in sidechains.

Esplora API Methods Comparison Matrix

CategoryEndpointCryptographic dataScope of application in auditing
TransactionsGET /tx/:txidwitness,  scriptsigtxidECDSA/Schnorr nonce repetition check, HNP audit
UTXOGET /address/:addr/utxoscriptpubkeyvalueValidation of unspent outputs, key analysis
Merkle proofsGET /tx/:txid/merkle-proofMerkle branch path, flagsCryptographic Block Inclusion Audit (SPV)
Liquid AssetsGET /asset/:asset_idsurjection_proofrangeproofPedersen Commitment Verification and Sidechain Validation

Conclusion

The Blockstream Esplora API specification provides a rigorous, deterministic, and verifiable tool for cryptanalysts and information security developers. The availability of raw binary data, Merkle inclusion proofs, and confidential transaction structures makes Esplora a fundamental foundation for passive cryptographic auditing and testing of blockchain systems.

Bibliography

Blockstream Documentation. Esplora API: Specification and cryptanalytic audit of blockchain structures:  https://cryptexy.ru/blockstream-documentation-esplora-api-specification-and-cryptanalytic-audit-of-blockchain-structures/

  1. Nguyen, P. Q., & Shparlinski, I. E. (2002). The Insecurity of the Digital Signature Algorithm with Partially Known Nonces.  Journal of Cryptology , 15(3), 151–176.[reference:44][reference:45]
  2. Nguyen, P. Q., & Shparlinski, I. E. (2003). The Insecurity of the Elliptic Curve Digital Signature Algorithm with Partially Known Nonces.  Designs, Codes and Cryptography , 30(2), 151–176.[reference:46]
  3. Boneh, D., & Venkatesan, R. (1996). Hardness of Computing the Most Significant Bits of Secret Keys in Diffie-Hellman and Related Schemes.  Crypto ’96 .[reference:47]
  4. Howgrave-Graham, N., & Smart, N. P. (1999). Lattice Attacks on Digital Signature Schemes.  Designs, Codes and Cryptography , 23(3), 283–290.[reference:48]
  5. Leadbitter, P. J., & Smart, N. P. (2002). Cryptanalysis of MQV with Partially Known Nonces.  IACR ePrint 2002. [reference:49]