Skip to main content

token_balances

Creates, updates, deletes, gets or lists a token_balances resource.

Overview

Nametoken_balances
TypeResource
Idaws.managedblockchain_query.token_balances

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
at_blockchain_instantobjectThe container for time.
balancestringThe container for the token balance.
last_updated_timeobjectThe container for time.
owner_identifierobjectThe container for the owner identifier.
token_identifierobjectThe container for the identifier for the token including the unique token ID and its blockchain network. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_token_balanceselectregionGets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.
list_token_balancesselectregionThis action returns the following for a given blockchain network: Lists all token balances owned by an address (either a contract address or a wallet address). Lists all token balances for all tokens created by a contract. Lists all token balances for a given token. You must always specify the network property of the tokenFilter when using this operation.
batch_get_token_balanceselectregionGets the token balance for a batch of tokens by using the BatchGetTokenBalance action for every token in the request. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.

SELECT
at_blockchain_instant,
balance,
last_updated_time,
owner_identifier,
token_identifier
FROM aws.managedblockchain_query.token_balances
WHERE region = '{{ region }}' -- required
;