Get Started
Learn
- Tutorials
Health Check
- Health Check
EVM
- Chains
- Blocks
- Transactions
- Balances
- Contracts
- NFTs
Primary Network
- Network, Chains & subnet
- Validators & Delegators
- Blocks
- Vertices
- Transactions
- Balances & UTXOs
- Rewards
- Assets
ICM Services
- Teleporter
- Interchain Messaging
- Signature Aggregator
Operations
- Operations
Usage Metrics
- Usage Metrics
List asset transactions
Lists asset transactions corresponding to the given asset id on the X-Chain.
import { AvaCloudSDK } from "@avalabs/avacloud-sdk";
const avaCloudSDK = new AvaCloudSDK({
serverURL: "https://api.example.com",
chainId: "43114",
network: "mainnet",
});
async function run() {
const result = await avaCloudSDK.data.primaryNetwork.transactions.listAssetTransactions({
txTypes: [
"AddValidatorTx",
],
startTimestamp: 1689541049,
endTimestamp: 1689800249,
blockchainId: "x-chain",
network: "mainnet",
assetId: "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
});
for await (const page of result) {
// Handle the page
console.log(page);
}
}
run();
{
"nextPageToken": "<string>",
"transactions": [
{
"txHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"chainFormat": "non-linear",
"timestamp": 1600762738,
"txType": "BaseTx",
"memo": "0x546865204176616c616e6368652050726f6a656374",
"consumedUtxos": [
{
"addresses": [
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
],
"asset": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
},
"consumedOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"consumingTxHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"createdOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"utxoId": "68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC",
"consumingTxTimestamp": 1599696000,
"creationTxHash": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z",
"credentials": [
{
"signature": "bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA",
"publicKey": "AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
}
],
"groupId": 123,
"locktime": 0,
"outputIndex": "38",
"payload": "<string>",
"threshold": 1,
"timestamp": 1599696000,
"utxoType": "mint"
}
],
"emittedUtxos": [
{
"addresses": [
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
],
"asset": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
},
"consumedOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"consumingTxHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"createdOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"utxoId": "68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC",
"consumingTxTimestamp": 1599696000,
"creationTxHash": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z",
"credentials": [
{
"signature": "bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA",
"publicKey": "AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
}
],
"groupId": 123,
"locktime": 0,
"outputIndex": "38",
"payload": "<string>",
"threshold": 1,
"timestamp": 1599696000,
"utxoType": "mint"
}
],
"amountUnlocked": [
{
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
}
],
"amountCreated": [
{
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
}
],
"sourceChain": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"destinationChain": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"assetCreated": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"createdAtTimestamp": 1675444720,
"cap": "fixed"
},
"vertices": [
{
"hash": "82qPRREHmh8Cfta4PGD6GymY9ZLyvgYugqW6hj9FykpMVRz1S",
"height": 1961,
"timestamp": 1600762738
}
]
}
],
"chainInfo": {
"chainName": "p-chain",
"network": "mainnet"
}
}
Authorizations
Api keys provide higher access to rate limits. To obtain an api key, sign up for an account at https://avacloud.io/.
Path Parameters
A primary network blockchain id or alias.
2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM
, 2JVSBoinj9C2J33VntvzYtVJNZdN2NKiwwKjcumHUWEb5DbBrm
, 2piQ2AVHCjnduiWXsSY15DtbVuwHE2cwMHYnEXHsLL73BBkdbV
, x-chain
Either mainnet or testnet/fuji.
mainnet
, fuji
, testnet
, devnet
Asset ID for any asset on X-Chain
Query Parameters
Query param for filtering items based on transaction types.
AddValidatorTx
, AddSubnetValidatorTx
, AddDelegatorTx
, CreateChainTx
, CreateSubnetTx
, ImportTx
, ExportTx
, AdvanceTimeTx
, RewardValidatorTx
, RemoveSubnetValidatorTx
, TransformSubnetTx
, AddPermissionlessValidatorTx
, AddPermissionlessDelegatorTx
, BaseTx
, TransferSubnetOwnershipTx
, ConvertSubnetToL1Tx
, RegisterL1ValidatorTx
, SetL1ValidatorWeightTx
, DisableL1ValidatorTx
, IncreaseL1ValidatorBalanceTx
, UNKNOWN
, CreateAssetTx
, OperationTx
Query param for retrieving items after a specific timestamp.
x >= 0
Query param for retrieving items before a specific timestamp.
x >= 0
A page token, received from a previous list call. Provide this to retrieve the subsequent page.
The maximum number of items to return. The minimum page size is 1. The maximum pageSize is 100.
1 <= x <= 100
Response
Unique ID for this transaction.
"3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c"
Represents chain format this transaction is included in.
non-linear
, linear
"non-linear"
Latest timestamp in seconds this transaction was accepted out of the same transaction accepted in other vertices.
1600762738
Type of transaction.
BaseTx
, CreateAssetTx
, OperationTx
, ImportTx
, ExportTx
, UNKNOWN
Hex encoded memo bytes for this transaction.
"0x546865204176616c616e6368652050726f6a656374"
Addresses that are eligible to sign the consumption of this output.
[
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
]
Unique ID for an asset.
"th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof"
Name of this asset.
"Avalanche"
Symbol for this asset (max 4 characters).
"AVAX"
Denomination of this asset to represent fungibility.
9
Type of asset like SECP256K1 or NFT.
secp256k1
, nft
Amount of the asset.
"5001000"
Blockchain ID on which this output is consumed on.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
Blockchain ID on which this output is created on.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
UTXO ID for this output.
"68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC"
Transaction ID that created this output.
"FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z"
Locktime in seconds after which this output can be consumed.
0
Postion of this output in a list of lexiographically sorted outputs of a transaction.
"38"
Minimum number of signatures required to consume this output.
1
Unix timestamp in seconds at which this outptut was created.
1599696000
Type of output.
"mint"
Transaction ID that consumed this output.
"3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c"
Unix timestamp in seconds at which this output was consumed.
1599696000
Credentials that signed the transaction to consume this utxo
Signature provided to consume the output.
"bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA"
Public key associated with the signature.
"AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
Index representing the minting set for the NFT mint output.
Hex encoded data for NFT assets.
Addresses that are eligible to sign the consumption of this output.
[
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
]
Unique ID for an asset.
"th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof"
Name of this asset.
"Avalanche"
Symbol for this asset (max 4 characters).
"AVAX"
Denomination of this asset to represent fungibility.
9
Type of asset like SECP256K1 or NFT.
secp256k1
, nft
Amount of the asset.
"5001000"
Blockchain ID on which this output is consumed on.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
Blockchain ID on which this output is created on.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
UTXO ID for this output.
"68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC"
Transaction ID that created this output.
"FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z"
Locktime in seconds after which this output can be consumed.
0
Postion of this output in a list of lexiographically sorted outputs of a transaction.
"38"
Minimum number of signatures required to consume this output.
1
Unix timestamp in seconds at which this outptut was created.
1599696000
Type of output.
"mint"
Transaction ID that consumed this output.
"3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c"
Unix timestamp in seconds at which this output was consumed.
1599696000
Credentials that signed the transaction to consume this utxo
Signature provided to consume the output.
"bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA"
Public key associated with the signature.
"AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
Index representing the minting set for the NFT mint output.
Hex encoded data for NFT assets.
Assets unlocked by inputs of this transaction.
Unique ID for an asset.
"th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof"
Name of this asset.
"Avalanche"
Symbol for this asset (max 4 characters).
"AVAX"
Denomination of this asset to represent fungibility.
9
Type of asset like SECP256K1 or NFT.
secp256k1
, nft
Amount of the asset.
"5001000"
Assets created by outputs of this transaction.
Unique ID for an asset.
"th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof"
Name of this asset.
"Avalanche"
Symbol for this asset (max 4 characters).
"AVAX"
Denomination of this asset to represent fungibility.
9
Type of asset like SECP256K1 or NFT.
secp256k1
, nft
Amount of the asset.
"5001000"
A transaction on X-Chain can be accepted over multiple vertices.
Vertex ID of the vertex this transaction belongs to.
"82qPRREHmh8Cfta4PGD6GymY9ZLyvgYugqW6hj9FykpMVRz1S"
Vertex height of the vertex this transaction belongs to.
1961
Timestamp in seconds this vertex was accepted.
1600762738
Source chain for an atomic transaction.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
Destination chain for an atomic transaction.
"2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
AssetAmount details of the asset created in CreateAssetTx
Unique ID for an asset.
"th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof"
Name of this asset.
"Avalanche"
Symbol for this asset (max 4 characters).
"AVAX"
Denomination of this asset to represent fungibility.
9
Type of asset like SECP256K1 or NFT.
secp256k1
, nft
Timestamp in seconds this asset was created on.
1675444720
Cap represents if an asset is a variable or fixed cap asset.
fixed
, variable
A token, which can be sent as pageToken
to retrieve the next page. If this field is omitted or empty, there are no subsequent pages.
Was this page helpful?
import { AvaCloudSDK } from "@avalabs/avacloud-sdk";
const avaCloudSDK = new AvaCloudSDK({
serverURL: "https://api.example.com",
chainId: "43114",
network: "mainnet",
});
async function run() {
const result = await avaCloudSDK.data.primaryNetwork.transactions.listAssetTransactions({
txTypes: [
"AddValidatorTx",
],
startTimestamp: 1689541049,
endTimestamp: 1689800249,
blockchainId: "x-chain",
network: "mainnet",
assetId: "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
});
for await (const page of result) {
// Handle the page
console.log(page);
}
}
run();
{
"nextPageToken": "<string>",
"transactions": [
{
"txHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"chainFormat": "non-linear",
"timestamp": 1600762738,
"txType": "BaseTx",
"memo": "0x546865204176616c616e6368652050726f6a656374",
"consumedUtxos": [
{
"addresses": [
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
],
"asset": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
},
"consumedOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"consumingTxHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"createdOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"utxoId": "68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC",
"consumingTxTimestamp": 1599696000,
"creationTxHash": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z",
"credentials": [
{
"signature": "bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA",
"publicKey": "AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
}
],
"groupId": 123,
"locktime": 0,
"outputIndex": "38",
"payload": "<string>",
"threshold": 1,
"timestamp": 1599696000,
"utxoType": "mint"
}
],
"emittedUtxos": [
{
"addresses": [
"avax1qm2a25eytsrj235hxg6jc0mwk99tss64eqevsw"
],
"asset": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
},
"consumedOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"consumingTxHash": "3j9JpF1aGuQtLLbo3YkvvKkWrCZViXZjdeJQWUSEY5hcqUn2c",
"createdOnChainId": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"utxoId": "68vLva9kfKUsX88ZPM8jdbf8qHUZRoZSFH6NdpAVTspkfrXDC",
"consumingTxTimestamp": 1599696000,
"creationTxHash": "FvwEAhmxKfeiG8SnEvq42hc6whRyY3EFYAvebMqDNDGCgxN5Z",
"credentials": [
{
"signature": "bWWoZUu0Z3STjuk/+2az7M4vP0oqc9NtiA7kOdqINCIE/2+5va5R1KNCWwEX5jE1xVHLvAxU2LHTN5gK8m84HwA",
"publicKey": "AdMQOtubgBFFJu++0faHPIIA6KmdZ2ERErMRGzyy6juI"
}
],
"groupId": 123,
"locktime": 0,
"outputIndex": "38",
"payload": "<string>",
"threshold": 1,
"timestamp": 1599696000,
"utxoType": "mint"
}
],
"amountUnlocked": [
{
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
}
],
"amountCreated": [
{
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"amount": "5001000"
}
],
"sourceChain": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"destinationChain": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"assetCreated": {
"assetId": "th5aLdWLi32yS9ED6uLGoMMubqHjzMsXhKWwzP6yZTYQKYzof",
"name": "Avalanche",
"symbol": "AVAX",
"denomination": 9,
"type": "secp256k1",
"createdAtTimestamp": 1675444720,
"cap": "fixed"
},
"vertices": [
{
"hash": "82qPRREHmh8Cfta4PGD6GymY9ZLyvgYugqW6hj9FykpMVRz1S",
"height": 1961,
"timestamp": 1600762738
}
]
}
],
"chainInfo": {
"chainName": "p-chain",
"network": "mainnet"
}
}