Skip to main content
POST
Get token balances for multiple wallets in a single request with getTokenAccountsByOwners. Powered by Ridge DB, our custom-built client designed for high-performance token account queries. Instead of making hundreds of individual requests, query up to 250 wallets at once for any token mint. Query up to 250 wallet addresses in one request to reduce API calls and latency.
  • If a wallet has multiple accounts for the same mint, the response returns all of them.
  • If a wallet has no token account, the response returns a clean zero balance instead of an error.
  • Each account includes the slot when the balance was last updated, which helps with caching and change tracking.
Configuración y errores: inicio rápido RPC. Facturación: créditos y límites.

Autorizaciones

api_key
string
query
requerido

Cuerpo

application/json
jsonrpc
enum<string>
predeterminado:2.0
requerido

The JSON-RPC protocol version.

Opciones disponibles:
2.0
Ejemplo:

"2.0"

id
string
predeterminado:1
requerido

A unique identifier for the request.

Ejemplo:

"1"

method
enum<string>
predeterminado:getTokenAccountsByOwners
requerido

The name of the RPC method to invoke.

Opciones disponibles:
getTokenAccountsByOwners
Ejemplo:

"getTokenAccountsByOwners"

params
(string[] | string)[]
requerido

Parameters for the batch token balance query.

Array of owner wallet public keys to query (1-250 wallets). All pubkeys must be valid base-58 encoded Solana addresses.

Required array length: 1 - 250 elements

Owner wallet public key as a base-58 encoded string.

Respuesta

Successfully retrieved token account balances for all requested owners.

jsonrpc
enum<string>

The JSON-RPC protocol version.

Opciones disponibles:
2.0
Ejemplo:

"2.0"

id
string

Identifier matching the request.

Ejemplo:

"1"

result
object

Token account balances with context information.