Skip to main content

Validator Staking — SDK API

This page is the SDK reference. For the on-chain state machine, lock period, and persistence guarantees, see the protocol page:

Backend / Validator Lifecycle

State transitions, unstake lock, restake invariants

Connect

Builders

stake(amount, connectionUrl, demos)

Register a new validator or top up an existing one.
The SDK validates amount as a positive bigint string and connectionUrl as a well-formed URL before signing — invalid input throws synchronously.

unstake(demos)

Arms the unstake lock. Validator continues participating in consensus during the lock window.

validatorExit(demos)

Withdraws the stake. Only valid after the lock has elapsed.

Read-side queries