跳转到主要内容
POST
/
getTokenAccounts
curl --request POST \
  --url https://mainnet.helius-rpc.com/ \
  --header 'Content-Type: application/json' \
  --data '{
  "jsonrpc": "2.0",
  "id": "1",
  "method": "getTokenAccounts",
  "params": {
    "owner": "86xCnPeV69n6t3DnyGvkKobf9FdN2H9oiVDdaMpo2MMY"
  }
}'
{
  "last_indexed_slot": 365750752,
  "total": 2,
  "limit": 100,
  "cursor": "<string>",
  "token_accounts": [
    {
      "address": "<string>",
      "mint": "<string>",
      "owner": "<string>",
      "amount": 123,
      "delegated_amount": 123,
      "frozen": true,
      "burnt": "<any>"
    }
  ]
}

Authorizations

api-key
string
query
required

您的 Helius API 密钥。您可以在仪表板中免费获取一个。

Body

application/json
jsonrpc
enum<string>
default:2.0
required

JSON-RPC 协议的版本。

Available options:
2.0
id
string
default:1
required

用于标识请求的 ID。

Example:

"1"

method
enum<string>
default:getTokenAccounts
required

要调用的方法名称。

Available options:
getTokenAccounts
params
object
required

Response

成功响应

last_indexed_slot
integer

保证所有数据都已索引到此槽位及之前的所有数据。

Example:

365750752

total
integer

请求找到的结果数量。

Example:

2

limit
integer

请求的最大结果数量。

Example:

100

cursor
string

用于分页的游标。

token_accounts
any[]

一个包含代币账户的数组。

I