Skip to main content

Block API

The block API provides REST API endpoints for retrieving block data from the Aleo testnet.

Components of a Block

"transactions": ["7a38bc5d1fd2c1f3355406eec505bcd722197d2dc679c1cf3465a3c41f51b615"],
"hash": "e6dfa55eb904c386a70c8858f13f1bc2155fd3b506d17e63e456b9c30f04fd80",
"height": 0,
"merkleRoot": "fc88e8b29c042ae4daa7000e8f4f38ce17b66afb771df5b78a0f6407862da12a",
"pedersenMerkleRoot": "38db6fa1fcd0c65976eb6366de3a0389730d94670dbf8850afba13700e7d5b05",
"time": 1592698396,
"nonce": 0,
"previousBlockHash": "0000000000000000000000000000000000000000000000000000000000000000",
"size": 1479,
"difficultyTarget": 576460752303423500,
"canonical": true,

The components of a block as provided are specific to the data structure provided by Aleo Explorer.

All components in a standard Aleo block are provided, in addition to possible helper parameters that accompany the primary data.


hash (string)

Hash of all of the block header data within this attribute.

height (number)

The height this current block is located at.

canonical (boolean)

A boolean value whether this block is currently in the longest chain.

previousBlockHash (string)

The hash of the previous block header.

merkleRoot (string)

Merkle root representing the transactions in the block.

pedersonMerkleRoot (string)

Merkle root representing the state of the block.

time (number)

Block timestamp is a Unix epoch time (UTC) when the miner started hashing the header (according to the miner and checked by every other miner).

size (number)

The size in bytes of the current block (sum of the size of all transactions + the values listed within this object).

nonce (number)

Nonce for solving the PoSW puzzle.

proof (string)

A succinct proof that attests to the transactions included in this block.

transactions (Array of hashes (strings))

A list of all the transactions included in this block.

difficultyTarget (number)

Proof of Succinct Work algorithm difficulty target for this block.