What you can do
| stake | Deposit SOL to get PSOL | call DepositSol(lamports) or DepositSolWithSlippage on program SPoo1Ku8WFXoNDMHPsrGSTSG1Y47rzgn41SLUNakuHy with SOL attached; PSOL is minted to the depositor |
| unstake | Burn PSOL for SOL | call WithdrawSol or WithdrawSolWithSlippage; if the reserve is short, use WithdrawStake to get a stake account instead |
| hold-psol | Hold and transfer PSOL | SPL Token transfer or transferChecked of mint pSo1f9nQXWgXibFtKf7NWYxb5enAM4qfP6UJSiXRQfL between token accounts |
| check-pool | Read pool balance and PSOL supply | read pool account pSPcvR8GmG9aKDUbn9nbKYjkxt9hxMS7kF1qqKJaPqJ and getTokenSupply on the PSOL mint |
Phantom's fee table applies: a protocol fee on rewards, and an exit fee when unstaking or swapping PSOL. Check the current table before acting.
If the SOL reserve is short, WithdrawSol cannot pay out, and the PSOL converts to a native stake that takes about two to three days to withdraw.
Rewards update at the start of each epoch, so the PSOL price moves once per epoch.
Staking rewards and APY are variable, and principal can be lost.
Contracts
Read any function, or build a write and sign it. Amounts are in base units (1 USDC = 1000000).SPL Stake Pool program (Solana Labs)staking on solanaSPoo1Ku8WFXoNDMHPsrGSTSG1Y47rzgn41SLUNakuHy
write DepositSol(lamports: u64)
Deposit SOL into the stake pool and mint PSOL to the depositor. Needs the pool account pSPcvR8GmG9aKDUbn9nbKYjkxt9hxMS7kF1qqKJaPqJ and the PSOL mint as accounts.
write DepositSolWithSlippage(lamports_in: u64, minimum_pool_tokens_out: u64)
Same as DepositSol, but fails if fewer PSOL than the minimum are minted. Use this to cap slippage.
write WithdrawSol(pool_tokens: u64)
Burn PSOL and receive SOL from the pool's reserve. Argument: PSOL amount to burn. Reverts if the reserve cannot cover it.
write WithdrawSolWithSlippage(pool_tokens_in: u64, minimum_lamports_out: u64)
Same as WithdrawSol, but fails if less SOL than the minimum would be returned.
write DepositStake()
Deposit an active stake account into the pool and receive PSOL.
write WithdrawStake(pool_tokens: u64)
Burn PSOL and receive a stake account instead of SOL. Use this when the SOL reserve is short. The stake takes about two to three days to deactivate and withdraw.
write UpdateStakePoolBalance()
Permissionless crank that updates the pool's total SOL and PSOL price after each epoch.
PSOL stake pool accountpool on solanapSPcvR8GmG9aKDUbn9nbKYjkxt9hxMS7kF1qqKJaPqJ
PSOL token minttoken on solanapSo1f9nQXWgXibFtKf7NWYxb5enAM4qfP6UJSiXRQfL
write transfer(amount: u64)
Standard SPL Token transfer of PSOL between two token accounts (Tokenkeg program).
write transferChecked(amount: u64, decimals: u8)
SPL Token transfer that checks the decimals against the mint. Read the decimals from the mint account first.
write approve(amount: u64)
Delegate an amount of PSOL to a spender token account.
write burn(amount: u64)
Burn PSOL from a token account owned by the signer.
read getTokenSupply(mint)
Total PSOL supply and decimals from the mint account.