Blocks

Get blocks by height

Changed on

This endpoint allows you to get the transactions in a block and the corresponding block information.

Transactions are limited by max default transactions size. If not all transactions are present, the user will need to query for the rest of the transactions via the get transactions API.

If the block is pruned, it will return a 410

get/blocks/by_height/{block_height}

Request

  • Base URL
    /v1 (relative, and the document was published on a file host, not at the API’s origin)
  • URL
    /v1/blocks/by_height/{block_height}
  • Auth
    none declared

Path parameters

block_heightinteger required

Block height to lookup. Starts at 0

Query parameters

with_transactionsboolean

If set to true, include all transactions in the block

If not provided, no transactions will be retrieved

Response

block_heightstring uint64 required

A string containing a 64-bit unsigned integer.

We represent u64 values as a string to ensure compatibility with languages such as JavaScript that do not parse u64s in JSON natively.

block_hashstring required
block_timestampstring uint64 required

A string containing a 64-bit unsigned integer.

We represent u64 values as a string to ensure compatibility with languages such as JavaScript that do not parse u64s in JSON natively.

first_versionstring uint64 required

A string containing a 64-bit unsigned integer.

We represent u64 values as a string to ensure compatibility with languages such as JavaScript that do not parse u64s in JSON natively.

last_versionstring uint64 required

A string containing a 64-bit unsigned integer.

We represent u64 values as a string to ensure compatibility with languages such as JavaScript that do not parse u64s in JSON natively.

transactionsTransaction[] (unresolved $ref)

The transactions in the block in sequential order

Changes

    • breaking

      the mandatory response header X-APTOS-BLOCK-HEIGHT removed for the status 200

    • breaking

      the mandatory response header X-APTOS-CHAIN-ID removed for the status 200

    • breaking

      the mandatory response header X-APTOS-EPOCH removed for the status 200

    • breaking

      the mandatory response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 200

    • breaking

      the mandatory response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 200

    • breaking

      the mandatory response header X-APTOS-LEDGER-VERSION removed for the status 200

    • breaking

      the mandatory response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 200

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 400

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 403

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 404

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 410

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 500

    • warning

      the optional response header X-APTOS-BLOCK-HEIGHT removed for the status 503

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 400

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 403

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 404

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 410

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 500

    • warning

      the optional response header X-APTOS-CHAIN-ID removed for the status 503

    • warning

      the optional response header X-APTOS-CURSOR removed for the status 200

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 400

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 403

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 404

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 410

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 500

    • warning

      the optional response header X-APTOS-EPOCH removed for the status 503

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 200

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 400

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 403

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 404

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 410

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 500

    • warning

      the optional response header X-APTOS-GAS-USED removed for the status 503

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 400

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 403

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 404

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 410

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 500

    • warning

      the optional response header X-APTOS-LEDGER-OLDEST-VERSION removed for the status 503

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 400

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 403

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 404

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 410

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 500

    • warning

      the optional response header X-APTOS-LEDGER-TIMESTAMPUSEC removed for the status 503

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 400

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 403

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 404

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 410

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 500

    • warning

      the optional response header X-APTOS-LEDGER-VERSION removed for the status 503

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 400

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 403

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 404

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 410

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 500

    • warning

      the optional response header X-APTOS-OLDEST-BLOCK-HEIGHT removed for the status 503

    • breaking

      added to the ////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////////// response property oneOf list for the response status

    • breaking

      added to the //////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////// response property oneOf list for the response status

    • breaking

      added to the //////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////// response property oneOf list for the response status

    • breaking

      added to the ////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////////// response property oneOf list for the response status

    • breaking

      added to the //////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////// response property oneOf list for the response status

    • breaking

      added to the //////////////////// response property oneOf list for the response status

    • breaking

      added to the /////////////////// response property oneOf list for the response status

    • info

      added abstract_signature discriminator mapping keys to the ////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the //////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the //////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the ////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the //////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the //////////////////// response property for the response status

    • info

      added abstract_signature discriminator mapping keys to the /////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the ////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the //////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the //////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the ////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the //////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the //////////////////// response property for the response status

    • info

      removed abstraction_signature discriminator mapping keys from the /////////////////// response property for the response status

    • info

      removed from the ////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////////// response property oneOf list for the response status

    • info

      removed from the //////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////// response property oneOf list for the response status

    • info

      removed from the //////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////// response property oneOf list for the response status

    • info

      removed from the ////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////////// response property oneOf list for the response status

    • info

      removed from the //////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////// response property oneOf list for the response status

    • info

      removed from the //////////////////// response property oneOf list for the response status

    • info

      removed from the /////////////////// response property oneOf list for the response status