blocks - Ton

blocks. Retrieves general block information from the TON blockchain, including block details like block ID, timestamp, and previous block reference.

blocks - ton [Value: 100CU]
Retrieves general block information from the TON blockchain, including block details like block ID, timestamp, and previous block reference.
Use cases

Use cases

  • Retrieve data for TON Blocks V3
  • Analyze block structure and contents
  • Audit block transactions and metadata
Constraints

Constraints

  • Requires valid block ID
  • Supports only Blocks V3 format
  • Depends on network sync
Get started
Unlock Access to 50+ chains
Boost your app's speed and reliability with dRPC - get your access API key

Language

Request
Examples
curl --request GET \
     --url ' https://ton.drpc.org/rest/api/v3/blocks?limit=128&offset=0&sort=desc' \
     --header 'accept: application/json'
Copy
Response
200
{
    "ok": true,
    "result": [
        {
            "block_id": "0:abcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdef",
            "workchain": -1,
            "shard": -9223372036854775808,
            "seqno": 39064874,
            "timestamp": 1693527600,
            "transactions_count": 35,
            "prev_block_id": "0:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
            "root_hash": "abcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdef",
            "file_hash": "1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"
        },
        {
            "block_id": "0:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
            "workchain": -1,
            "shard": -9223372036854775808,
            "seqno": 39064873,
            "timestamp": 1693527500,
            "transactions_count": 40,
            "prev_block_id": "0:abcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdef",
            "root_hash": "1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
            "file_hash": "abcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdef"
        }
    ]
}
Copy

Request params

Parametersobject
object
limitinteger
The maximum number of blocks to return. Default is 128.
offsetinteger
The number of blocks to skip before starting to return results. Default is 0.
sortstring
The sorting order of the blocks. Possible values are 'asc' for ascending or 'desc' for descending. Default is 'desc'.

Response

200

Response params

object
okboolean
Indicates if the request was successful.
resultarray
List of block details.
object
block_idstring
Unique identifier of the block.
workchaininteger
ID of the workchain; -1 represents the masterchain.
shardinteger
ID of the shard in which the block resides.
seqnointeger
Sequence number of the block.
timestampinteger
Unix timestamp indicating when the block was created.
transactions_countinteger
Number of transactions included in the block.
prev_block_idstring
Identifier of the previous block in the sequence.
root_hashstring
Root hash of the block.
file_hashstring
File hash associated with the block.