Get Blocks

This endpoint returns you a paginated list of blocks

Parameters

  • from- (optional) The pagination cursor for the next/previous page
  • pageSize- (optional) Defines the number of results to be returned in a single page. Default is set to 50
  • paginationType- (optional) Set the field to paginate by
    • Accepts either blockNumber or blockTime
  • reverse- (optional) A boolean field to allow paginating through the results in either descending or ascending order

Results

Valid Response

[<object>] - an array of JSON objects containing the following fields each:

  • blockNumber:<integer> block number of a given block
  • data:<object> A json object containing the follow fields:
    • {
        "epoch": "Epoch number that the block is produced",
        "previousHash": "The previous block hash",
        "producer": "The block producer address of this stated block",
        "hash": "The block hash of this stated block",
        "parentNumber": "The parent block number",
        "number": "The stated block's block number",
        "dataSize": "The data size",
        "numberOfTransactions": "Number of transactions within this block",
        "successfulTransactions": "Number of successful transactions",
        "voteTransactions": "Number of vote transactions",
        "totalTxFees": "Total transaction fees incurred within this block",
        "numberOfRewards": "Number of rewards issued for producing this block",
        "totalRewardAmount": "The total rewarded amount",
        "totalComputeUnitsConsumed": "Compute units consumed for producing this block",
        "totalComputeUnitsLimit": "Compute units upper bound limit",
        "blockTime": "Block time of this stated block"
      }
      

Invalid Response

<object> - a JSON object containing the following fields if the requested account doesn't exist

  • code:<integer>, The error code
  • message:<String>, An error message to indicate which part of the query went wrong
  • status:<String>, The response status following the error code
    • 400 = Bad Request (client side)
    • 500 = Internal Server Error (server side)
Language
Click Try It! to start a request and see the response here!