getTokenAccounts RPC Method
Please note that this RPC method requires the Solana DAS (Digital Asset Standard) API add-on enabled on your QuickNode endpoint.
Solana Web3.js 2.0 includes the ability to customize RPC methods and transports, allowing you to seamlessly integrate QuickNode Marketplace add-ons into your applications. For more information on how to use QuickNode Marketplace add-ons with Solana Web3.js 2.0, check out these guides: How to Use QuickNode Add-ons using Solana Web3.js 2.0 (Part 1) and How to Use QuickNode Add-ons using Solana Web3.js 2.0 (Part 2)
Parameters
mintAddress
string
The mint address to check for token accounts
ownerAddress
string
The address of the owner account to check for token accounts
limit
integer
The maximum number of assets to retrieve
page
integer
The index of the page to retrieve. The page parameter starts at 1
Returns
result
object
The information about the list of token accounts:
total
integer
The number of token accounts returned
limit
integer
The limit specified in the request
page
integer
The page number of the results
token_accounts
array of objects
An array of objects containing information about the specified token accounts:
account
object
The information about the specified token account:
address
string
The address of the token account
mint
string
The address of the mint account
owner
string
The address of the token account owner
amount
integer
The amount of tokens in the token account
delegated_amount
number
The amount of delegated tokens in the token account
frozen
boolean
Whether the token account is frozen
close_authority
string
The close authority for the token account
extentions
string
The extensions of the token account
Request
1curl https://docs-demo.solana-mainnet.quiknode.pro/ \2-X POST \3-H "Content-Type: application/json" \4--data '{"jsonrpc": "2.0","id": 1,"method": "getTokenAccounts","params": {"mintAddress": "So11111111111111111111111111111111111111112", "limit": 2}}'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free