Actions11
Overview
The node enables interaction with the Solana blockchain network, supporting various operations such as sending SOL tokens, sending SPL tokens, staking SOL, withdrawing staked SOL, creating wallets, signing/verifying messages, and retrieving account or transaction information.
Specifically, the Withdraw Stake operation allows users to withdraw a specified amount of staked SOL from a given stake account and send it to a destination address. This is useful when users want to reclaim their staked funds after unstaking or when they want to move their SOL to another wallet.
Practical example: A user who previously delegated SOL to a validator for staking can use this node to withdraw some or all of that stake back to their main wallet or another address.
Properties
Name | Meaning |
---|---|
Amount | The amount of SOL to withdraw from the stake account (specified in SOL units). |
Stake Account Address | The public address of the stake account from which to withdraw staked SOL. |
Destination Address | The public address where the withdrawn SOL will be sent. |
Output
The output JSON object for the Withdraw Stake operation contains:
success
: Boolean indicating if the withdrawal was successful.txSignature
: The transaction signature string confirming the withdrawal on the Solana blockchain.operation
: The name of the operation performed (withdrawStake
).
This output confirms the transaction submission and provides the signature for tracking or verification purposes.
Dependencies
- Requires an API key credential with access to a Solana RPC endpoint.
- Uses the
@solana/web3.js
library for blockchain interactions. - Requires the private key of the wallet authorized to withdraw from the stake account.
- The node must be configured with valid Solana credentials including the private key and RPC URL.
Troubleshooting
Common issues:
- Invalid or missing stake account address: The node will throw an error if the stake account address is not provided or invalid.
- Insufficient funds or permissions: Withdrawal will fail if the authorized wallet does not have permission or if the stake account has insufficient balance.
- Network or RPC errors: Connectivity issues with the Solana RPC endpoint may cause failures.
Error messages:
"No credentials returned!"
: Indicates missing or misconfigured Solana API credentials."Unsupported operation"
: If the operation parameter is incorrect or unsupported.- Errors related to invalid addresses or failed transactions will include descriptive messages from the Solana RPC.
To resolve errors, verify that all required input properties are correctly set, ensure the credentials are valid, and confirm network connectivity.