Parameters
string
required
Public key of the owner (base-58 encoded)
object
required
Response
object
Object containing:
array
Array of token account objects containing:
string
Public key of the token account (base-58 encoded)
object
number
Number of lamports in the account
string
Public key of the account owner (base-58 encoded)
boolean
Whether the account is executable
number
Epoch at which the account will next owe rent
object
object
object
object
string
Public key of the token’s mint (base-58 encoded)
string
Public key of the token account owner (base-58 encoded)
string
Public key of the delegate (base-58 encoded)
string
Type of account (account)
string
Program that owns the account (spl-token)
number
Number of bytes allocated to the account
Code Examples
Basic Request
Using web3.js
Notes
- Returns all token accounts owned by the given public key
- The owner has full control over these accounts
- The response is immediate as it reads from the current state
- The accounts can change with token transfers and other operations
- The owner must be a valid public key
Best Practices
- Use appropriate commitment level based on your needs
- Cache results when appropriate to reduce RPC load
- Monitor for changes in owned accounts
- Consider using websocket subscription for real-time updates
- Handle network errors and retry when appropriate
Common Errors
Use Cases
-
Owner Account Analysis
-
Owner Account Monitoring
-
Owner Account Planning