Skip to main content
There are two ways to start staking on the TON network using the Staking API:
  • Stake individually with a validator via a single nominator pool
  • Stake along with multiple nominators via Ton Whales pools
Action Required: Single Nominator PoolsThis is an alternative type of the TON smart contract designed for validators that have enough self stake to validate by themselves without relying on third-party nominators stakes.The single nominator staking flow requires manual activation. Before you begin, please contact the P2P team to whitelist your wallet address.Note: Attempting to stake without pre-registration will result in validation error.
For both flows, to start using the Staking API:
  1. Create a staking request.
  2. Sign and broadcast the staking transaction to the network.
Get an authentication token to start using Staking API. Request examples are provided using cURL.
1

Create staking request

Depending on the type of your staking pool, send a POST request either to /api/v1/ton/{network}/staking/single-nominator/stake or to /api​/v1​/ton​/{network}​/staking​/ton-whales​/stake.Example request (in the testnet network for a single nominator pool):
  • publicKey — public key of the nominator for the TON network.
  • amount — amount of tokens to stake in nanoGRAMs (1 GRAM = 10⁹ nanoGRAMs). Note that the minimum staking amount is not limited, but there is a maximum cap of 2 000 000 GRAM for each pool.
  • walletVersionversion of the smart contract used by the wallet in the TON blockchain:
    • V3R1 and V3R2 — wallet V3.
    • V4 — wallet V4; used by default.
    • V5R1 — wallet V5.
Example response:
  • unsignedTransaction in the hexadecimal format. Sign the transaction and submit it to the blockchain to create a staking request.
  • poolAddress — nominator pool address (for Ton Whales pools).
  • walletVersionversion of the smart contract used by the wallet in the TON blockchain.
  • stakerAddress — main account address of the type which keeps tokens.
  • publicKey — public key of the nominator for the TON network.
  • amount — amount of tokens to stake in TON.
2

Sign and broadcast transaction

Sign and broadcast the unsignedTransaction to the TON network.To check the transaction status, send a GET request to /api/v1/ton/{network}/transactions/status/{address}/{transactionHash}.Example request (in the testnet network for a single nominator pool):
  • address — staker account address.
  • transactionHash — hash of the transaction.
Example response:
  • address — staker account address.
  • lt — logical time of the last transaction created by this staker account.
  • prevTransactionHash — hash of the previous transaction.
  • prevTransactionLt — logical time of the previous transaction.
  • now — current time on the TON blockchain node.
  • outMessagesCount — count of output messages sent by the smart contract in the result of this transaction.
  • oldStatus — staker account status before transaction execution.
  • endStatus — staker account status after transaction execution.
  • transactionHash — hash of the transaction.