Skip to main content

Module instruction

Module instruction 

Source
Expand description

Instruction types

Enums§

FundingType
Defines which authority to update in the SetFundingAuthority instruction
PreferredValidatorType
Defines which validator vote account is set during the SetPreferredValidator instruction
StakePoolInstruction
Instructions supported by the StakePool program.

Functions§

add_validator_to_pool
Creates AddValidatorToPool instruction (add new validator stake account to the pool)
add_validator_to_pool_with_vote
Create an AddValidatorToPool instruction given an existing stake pool and vote account
cleanup_removed_validator_entries
Creates CleanupRemovedValidatorEntries instruction (removes entries from the validator list)
create_token_metadata
Creates an instruction to create metadata using the mpl token metadata program for the pool token
decrease_additional_validator_stake
Creates DecreaseAdditionalValidatorStake instruction (rebalance from validator account to transient account)
decrease_additional_validator_stake_with_list
Create a DecreaseAdditionalValidatorStake instruction given an existing stake pool, validator list and vote account
decrease_additional_validator_stake_with_vote
Create a DecreaseAdditionalValidatorStake instruction given an existing stake pool and vote account
decrease_validator_stakeDeprecated
Creates DecreaseValidatorStake instruction (rebalance from validator account to transient account)
decrease_validator_stake_with_reserve
Creates DecreaseValidatorStakeWithReserve instruction (rebalance from validator account to transient account)
decrease_validator_stake_with_vote
Create a DecreaseValidatorStake instruction given an existing stake pool and vote account
deposit_sol
Creates instruction to deposit SOL directly into a stake pool.
deposit_sol_with_authority
Creates instruction required to deposit SOL directly into a stake pool. The difference with deposit_sol() is that a deposit authority must sign this instruction.
deposit_sol_with_authority_and_slippage
Creates instruction to deposit SOL directly into a stake pool with slippage constraint.
deposit_sol_with_slippage
Creates instruction to deposit SOL directly into a stake pool with slippage constraint.
deposit_stake
Creates instructions required to deposit into a stake pool, given a stake account owned by the user.
deposit_stake_with_authority
Creates instructions required to deposit into a stake pool, given a stake account owned by the user. The difference with deposit() is that a deposit authority must sign this instruction, which is required for private pools.
deposit_stake_with_authority_and_slippage
Creates instructions required to deposit into a stake pool with slippage, given a stake account owned by the user. The difference with deposit() is that a deposit authority must sign this instruction, which is required for private pools.
deposit_stake_with_slippage
Creates instructions to deposit into a stake pool with slippage
deposit_wsol_with_session
Creates instruction required to deposit wSOL directly into a stake pool using a session signer.
increase_additional_validator_stake
Creates IncreaseAdditionalValidatorStake instruction (rebalance from reserve account to transient account)
increase_additional_validator_stake_with_list
Create a IncreaseAdditionalValidatorStake instruction given an existing stake pool, validator list and vote account
increase_additional_validator_stake_with_vote
Create an IncreaseAdditionalValidatorStake instruction given an existing stake pool and vote account
increase_validator_stake
Creates IncreaseValidatorStake instruction (rebalance from reserve account to transient account)
increase_validator_stake_with_vote
Create an IncreaseValidatorStake instruction given an existing stake pool and vote account
initialize
Creates an Initialize instruction.
redelegateDeprecated
Creates Redelegate instruction (rebalance from one validator account to another)
remove_validator_from_pool
Creates RemoveValidatorFromPool instruction (remove validator stake account from the pool)
remove_validator_from_pool_with_vote
Create an RemoveValidatorFromPool instruction given an existing stake pool and vote account
set_fee
Creates a SetFee instruction.
set_funding_authority
Creates a SetFundingAuthority instruction.
set_manager
Creates a SetManager instruction.
set_preferred_validator
Creates SetPreferredDepositValidator instruction
set_staker
Creates a SetStaker instruction.
update_stake_pool
Creates all UpdateValidatorListBalance and UpdateStakePoolBalance instructions for fully updating a stake pool each epoch
update_stake_pool_balance
Creates UpdateStakePoolBalance instruction (pool balance from the stake account list balances)
update_stale_stake_pool
Creates the UpdateValidatorListBalance instructions only for validators on validator_list that have not been updated for this epoch, and the UpdateStakePoolBalance instruction for fully updating the stake pool.
update_stale_validator_list_balance_chunk
Creates UpdateValidatorListBalance instruction (update validator stake account balances)
update_token_metadata
Creates an instruction to update metadata in the mpl token metadata program account for the pool token
update_validator_list_balanceDeprecated
Creates UpdateValidatorListBalance instruction (update validator stake account balances)
update_validator_list_balance_chunk
Creates an UpdateValidatorListBalance instruction (update validator stake account balances) to update validator_list[start_index..start_index + len].
withdraw_from_stake_account_with_session
Creates instruction to withdraw lamports from a user stake account using a session signer. Used after the cooldown period to convert deactivated stake to SOL.
withdraw_sol
Creates instruction required to withdraw SOL directly from a stake pool.
withdraw_sol_with_authority
Creates instruction required to withdraw SOL directly from a stake pool. The difference with withdraw_sol() is that the sol withdraw authority must sign this instruction.
withdraw_sol_with_authority_and_slippage
Creates instruction required to withdraw SOL directly from a stake pool with a slippage constraint. The difference with withdraw_sol() is that the sol withdraw authority must sign this instruction.
withdraw_sol_with_slippage
Creates instruction required to withdraw SOL directly from a stake pool with slippage constraints.
withdraw_stake
Creates a WithdrawStake instruction.
withdraw_stake_with_session
Creates instruction to withdraw stake from a stake pool using a session signer.
withdraw_stake_with_slippage
Creates a WithdrawStakeWithSlippage instruction.
withdraw_wsol_with_session
Creates instruction required to withdraw wSOL directly from a stake pool using a session signer.