Staking
Evolution SDK provides complete staking operations — register stake credentials, delegate to pools and DReps, withdraw rewards, and deregister. All operations support both key-based and script-controlled stake credentials.
Stake Key Registration
Register stake credentials on the Cardano blockchain
Legacy Stake Registration
Register stake credentials using the pre-Conway certificate format (no deposit)
Delegation
Delegate stake to pools and voting power to DReps
Rewards Withdrawal
Withdraw accumulated staking rewards
Deregistration
Deregister stake credentials and reclaim deposit
Stake Pool Operations
Register and retire stake pools on Cardano
Staking Lifecycle
- Register — Create a stake credential on-chain (requires a deposit)
- Delegate — Assign your stake to a pool and/or DRep
- Earn — Accumulate rewards each epoch
- Withdraw — Claim accumulated rewards
- Deregister — Remove credential and reclaim deposit (optional)
Quick Example
import { Credential, preprod, Client } from "@evolution-sdk/evolution"
const client = Client.make(preprod)
.withBlockfrost({
baseUrl: "https://cardano-preprod.blockfrost.io/api/v0",
projectId: process.env.BLOCKFROST_API_KEY!
})
.withSeed({ mnemonic: process.env.WALLET_MNEMONIC!, accountIndex: 0 })
declare const stakeCredential: Credential.Credential
declare const poolKeyHash: any
const tx = await client
.newTx()
.registerStake({ stakeCredential })
.delegateToPool({ stakeCredential, poolKeyHash })
.build()
const signed = await tx.sign()
await signed.submit()
Conway Era Features
The Conway era introduced new delegation capabilities:
- Vote delegation — Delegate voting power to a DRep separately from stake
- Combined certificates — Register + delegate in a single certificate
- Script-controlled staking — Use Plutus scripts for stake operations
Next Steps
- Registration — Register stake credentials on-chain
- Legacy Registration — Pre-Conway registration, withdrawal scripts, and coordinator pattern
- Delegation — Delegate to pools and DReps
- Withdrawal — Claim accumulated staking rewards
- Deregistration — Remove credentials and reclaim deposit
- Stake Pool Operations — Register and retire stake pools