Getting Started

Staking in the Sei network using the Staking API consists of the following main steps:

  1. Create a stake transaction.
  2. Sign and send the transaction to the network.
  3. Optionally, track the stake status to confirm activation.

Amounts must be specified in MIST (1 SUI = 1,000,000,000 MIST).

Get an authentication token to start using Staking API.

Request examples are provided using cURL.

1. Create Stake Transaction

Send a POST request to /api/v1/sei/{network}/staking/stake.

Example request (for testnet network):

curl --request POST
		--url 'https://api-test.p2p.org/api/v1/sui/testnet/staking/stake' \
		--header 'accept: application/json' \
		--header 'Authorization: Bearer <token>' \
		--header 'Content-Type: application/json' \
		--data '{
      "sender": "0x696f4402d7151fb49e52b629de3ce3098f3dda7721a7425c000b4f26653709e3",
      "gasPrice": 1000,
      "gasBudget": 500000000,
      "amount": 1000000000
		}'
  • sender — your SUI wallet address.
  • gasPrice — gas price in MIST.
  • gasBudget — maximum gas budget for the transaction.
  • amount — amount to stake, in MIST.

Example response:

{
    "error": null,
    "result": {
        "unsignedTransaction": "0x000003000800ca9a3b00000000010100000000000000000000000000000000000000000000000000000000000000050100000000000000010020ab4fb3eeaa7b0ab4f91eedab33adf140c6750e60ca5e44b3df82491937d7bab4020200010100000000000000000000000000000000000000000000000000000000000000000000030a7375695f73797374656d11726571756573745f6164645f7374616b650003010100020000010200696f4402d7151fb49e52b629de3ce3098f3dda7721a7425c000b4f26653709e3024af02b603f7d65cced30be6ed44300d7d9d66522940e501e1a2083cfc25429e5a60bd0140000000020abca58a9797ecf7cc82596d71b4a154f8dd14b18e3190beee205b905611fbfa29c6ca3ef6b075ab6294342fe06c323768659879813e0544d3fd25a7db7875cca440000180000000020405515b0e64b00c04ebdb0517c2a1f07f3e32cba49adf4ea87d4daadc265c1f0696f4402d7151fb49e52b629de3ce3098f3dda7721a7425c000b4f26653709e3e8030000000000000065cd1d0000000000"
    }
}
  • unsignedTransaction — serialized, unsigned transaction in Base64 format.

2. Sign and Send Transaction

Use transactionData to sign and send the signed transaction to the Sei network.

3. Optionally, track the stake status to confirm activation.

To view your staking position and status, use the following endpoint:

Send a GET request to /api/v1/sei/{network}/transaction/stake-list/{address}.

Example request (for testnet network):

curl --request GET
		 --url 'https://api-test.p2p.org/api/v1/sui/testnet/transaction/stake-list/0x696f4402d7151fb49e52b629de3ce3098f3dda7721a7425c000b4f26653709e3' \
		--header 'Authorization: Bearer <token>'

Example response:

{
  "error": null,
  "result": {
    "validatorAddress": "0xab4fb3eeaa7b0ab4f91eedab33adf140c6750e60ca5e44b3df82491937d7bab4",
    "stakerAddress": "0x696f4402d7151fb49e52b629de3ce3098f3dda7721a7425c000b4f26653709e3",
    "stakes": [
      {
        "stakeId": "0x5d920b8fca6a6043d898ab1a9a8ab167d8aa323fe2b9e76a27312f7f16e20a67",
        "amount": 1000000000,
        "status": "Pending"
      }
    ]
  }
}

Stake status values:

  • Pending — The stake has been submitted and is awaiting activation.
  • Active — The stake is active and earning rewards. Activation may take up to 12 hours depending on validator configuration.
  • Unstaked — The stake has been withdrawn.

Note: You will need the stakeId to perform a withdrawal later.

What's Next?