Retrieves information about the current state of the masterchain
The masterchainInfo
endpoint retrieves information about the current state of the masterchain in the TON blockchain. This includes details about the last masterchain block, the initial masterchain block, and the current state root hash.
Get you own node endpoint today
Start for free and get your app to production levels immediately. No credit card required.
You can sign up with your GitHub, X, Google, or Microsoft account.
Parameters
This endpoint doesn't require any parameters.
Response
last
(object) β Information about the last masterchain block:seqno
(integer) β The sequence number of the last masterchain block.shard
(string) β The shard identifier of the last masterchain block.workchain
(integer) β The workchain ID of the last masterchain block.fileHash
(string) β The file hash of the last masterchain block.rootHash
(string) β The root hash of the last masterchain block.
init
(object) β Information about the initial masterchain block:fileHash
(string) β The file hash of the initial masterchain block.rootHash
(string) β The root hash of the initial masterchain block.
stateRootHash
(string) β The state root hash of the masterchain.now
(integer) β The current timestamp.
Use case
The masterchainInfo
endpoint is crucial for applications that need to stay synchronized with the current state of the TON blockchain. Some common use cases include:
- Block explorers: To display the latest block information and blockchain statistics.
- Wallet applications: To ensure that transactions are being processed against the most recent blockchain state.
- DApps: To verify the current state of the blockchain before executing smart contracts or transactions.
- Monitoring tools: To track the progress and health of the TON network.
- Synchronization services: To help light clients or other services stay up-to-date with the latest masterchain state.
By using this endpoint, developers can easily access critical information about the current state of the TON masterchain, enabling them to build robust and reliable applications that interact with the TON blockchain.