accounts_resources
Overview#
Lists all Move resources stored under an account. Useful to discover balances, capabilities, and custom module data.
Endpoint#
GET /v1/accounts/{address}/resources
Aptos-Specific Notes#
- Resource types follow
address::module::Struct<...>. - Large accounts may have many resources; use pagination parameters if present.
Request#
Path Parameters#
| Name | Type | Required | Description |
|---|---|---|---|
| address | string | Yes | Account address (e.g., 0x1) |
Query Parameters#
| Name | Type | Required | Description |
|---|---|---|---|
| ledger_version | string | No | Read at a historical version |
| limit | integer | No | Max number of resources to return |
| start | string | No | Cursor for pagination |
Request Body#
None.
Response#
Success Response (200)#
[
{
"type": "0x1::coin::CoinStore<0x1::aptos_coin::AptosCoin>",
"data": { "coin": { "value": "123" } }
}
]
Error Responses#
| Status | Error Code | Description |
|---|---|---|
| 400 | invalid_input | Invalid address format |
| 404 | account_not_found | Account doesn't exist |
Code Examples#
- cURL
- Python
- TypeScript
- Rust SDK
curl -X GET https://api-aptos-mainnet.n.dwellir.com/YOUR_API_KEY/v1/accounts/0x1/resources?limit=100 \
-H "Accept: application/json" \
-H "Accept: application/json"
SDK
from aptos_sdk.client import RestClient
client = RestClient("https://api-aptos-mainnet.n.dwellir.com/YOUR_API_KEY/v1")
resources = client.account_resources("0x1")
import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";
const aptos = new Aptos(new AptosConfig({ network: Network.MAINNET, fullnode: "https://api-aptos-mainnet.n.dwellir.com/YOUR_API_KEY/v1" }));
const resources = await aptos.getAccountResources({ accountAddress: "0x1" });
use aptos_sdk::rest_client::Client;
let client = Client::new("https://api-aptos-mainnet.n.dwellir.com/YOUR_API_KEY/v1".parse()?);
let resources = client.get_account_resources_bcs("0x1").await?;
Common Use Cases#
- Token balances (CoinStore, FA)
- Capability checks
- Reading application state
Related Endpoints#
- accounts_resource - Get a single resource type