getTokenAccountsByDelegate RPC Method
Description
Returns all SPL Token accounts by approved Delegate.
Parameters
pubkey
(string) - The Pubkey of account delegate to query encoded as base-58 stringobject
(array) - The JSON object with the following fields:mint
(string) - The Pubkey of the specific token Mint to limit accounts to, as base-58 encoded stringprogramId
(string) - The Pubkey of the Token program ID that owns the accounts, as base-58 encoded string
object
(array) - The JSON object with the following fields:commitment
(string, optional) - The level of commitment required for the query. The options include:finalized
- The node will query the most recent block confirmed by the supermajority of the cluster as having reached maximum lockout, meaning the cluster has recognized this block as finalizedconfirmed
- The node will query the most recent block that has been voted on by the supermajority of the clusterprocessed
- The node will query its most recent block. Note that the block may not be complete
encoding
(string) - The encoding format for account data. It can be one of base58 (slow), base64, base64+zstd or jsonParseddataSlice
(string, optional) - The returned account data using the provided offset: 'usize' and length: 'usize' fields; only available for base58, base64, or base64+zstd encodingsminContextSlot
(integer, optional) - The minimum slot at which the request can be evaluated
Returns
An object with the following fields:
context
- The information about the current state of the programapiVersion
- The version of the Solana RPC API to useslot
- An integer representing the slot for which to retrieve the fee calculator
value
- A JSON object with the following fields:account
- An address on the Solana blockchain that is used to store assetsdata
- A string containing the encoded data to be passed to the instructionprogram
- The program that manages the tokenparsed
- An array of parsed instructions that were executed in the block's transactionsinfo
- An array of information objects that provide additional details about the transactions in the blocktokenAmount
- The balance of the token in the token accountdelegate
- The public address of the delegate from which the account tokens are to be retrieved encoded as base-58 stringdelegateAmount
- The configuration object with the following fieldsisNative
- A boolean value indicating whether the token is a native token of the Solana blockchainmint
- Provides information about the creation of new tokensowner
- The base-58 encoded Pubkey of the program this account has been assigned tostate
- The current state of the token account
pubkey
- The public key associated with the token account