X-Chain Transactions
index.getContainerByID
Get container by ID.
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.getContainerByID",
"params": {
"id": "6fXf5hncR8LXvwtM8iezFQBpK5cubV6y1dWgpJCcNyzGB1EzY",
"encoding":"hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "not found",
"data": null
},
"id": 1
}
index.getContainerByIndex
Get container by index. The first container accepted is at index 0, the second is at index 1, etc.
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.getContainerByIndex",
"params": {
"index":0,
"encoding": "hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "no container at index 0",
"data": null
},
"id": 1
}
index.getContainerRange
Returns the transactions at index [startIndex
], [startIndex+1
], ... , [startIndex+n-1
]
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.getContainerRange",
"params": {
"startIndex":0,
"numToFetch":100,
"encoding": "hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "no containers have been accepted",
"data": null
},
"id": 1
}
index.getIndex
Get a container's index.
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.getIndex",
"params": {
"id":"6fXf5hncR8LXvwtM8iezFQBpK5cubV6y1dWgpJCcNyzGB1EzY",
"encoding": "hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "not found",
"data": null
},
"id": 1
}
index.getLastAccepted
Get the most recently accepted container.
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.getLastAccepted",
"params": {
"encoding": "hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "no containers have been accepted",
"data": null
},
"id": 1
}
index.isAccepted
Returns true if the container is in this index.
Method: POST
https://avax.nownodes.io/ext/index/X/tx
Example body (raw)
{
"jsonrpc": "2.0",
"method": "index.isAccepted",
"params": {
"id":"6fXf5hncR8LXvwtM8iezFQBpK5cubV6y1dWgpJCcNyzGB1EzY",
"encoding": "hex"
},
"id": 1
}
Example response: 200
{
"jsonrpc": "2.0",
"result": {
"isAccepted": false
},
"id": 1
}
Last updated