curl --request POST \
--url 'https://api.avax.network/ext/bc/P#platform.getBlockchains' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"method": "platform.getBlockchains",
"params": {},
"id": 1
}
'{
"jsonrpc": "2.0",
"result": {
"blockchains": [
{
"id": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"name": "<string>",
"subnetID": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"vmID": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
}
]
},
"id": 1
}GetBlockchains returns all of the blockchains that exist
curl --request POST \
--url 'https://api.avax.network/ext/bc/P#platform.getBlockchains' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"method": "platform.getBlockchains",
"params": {},
"id": 1
}
'{
"jsonrpc": "2.0",
"result": {
"blockchains": [
{
"id": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"name": "<string>",
"subnetID": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM",
"vmID": "2oYMBNV4eNHyqk2fjjV5nVQLDbtmNJzq5s3qs3Lo6ftnC6FByM"
}
]
},
"id": 1
}JSON-RPC request
Was this page helpful?