Get a Blockchain by ID
Returns a blockchain by ID or legacyID.
GET
/
blockchains
/
{id}
TypeScript
const response: Promise<FireblocksResponse<BlockchainResponse>> = fireblocks.blockchainsAssets.getBlockchain(blockchainsAssetsApiGetBlockchainRequest);CompletableFuture<ApiResponse<BlockchainResponse>> response = fireblocks.blockchainsAssets().getBlockchain(id);response = fireblocks.blockchains_&_assets.get_blockchain(id);curl --request GET \
--url https://api.fireblocks.io/v1/blockchains/{id}const options = {method: 'GET'};
fetch('https://api.fireblocks.io/v1/blockchains/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.fireblocks.io/v1/blockchains/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.fireblocks.io/v1/blockchains/{id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.fireblocks.io/v1/blockchains/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "9f9f7062-df90-4fc0-8697-96685184357b",
"legacyId": "ETH",
"displayName": "Ethereum",
"nativeAssetId": "9f9f7062-df90-4fc0-8697-96685184356a",
"onchain": {
"protocol": "EVM",
"test": false,
"signingAlgo": "ECDSA_SECP256K1",
"chainId": 1
},
"metadata": {
"scope": "GLOBAL",
"deprecated": false,
"media": [
{
"url": "https://example.com/image.png",
"type": "image/svg+xml"
}
],
"explorer": {
"base": "https://example.com",
"address": "https://example.com/address/{address}",
"tx": "https://example.com/tx/{tx}",
"token": "https://example.com/nft/{contract}/{tokenId}"
}
}
}{
"message": "Blockchain with specified ID not found",
"code": 1505
}{
"message": "Internal server error",
"code": 3005
}{
"message": "<string>",
"code": 123
}Path Parameters
The ID or legacyId of the blockchain
Response
Blockchain with requested identification
The ID of the blockchain
Example:
"9f9f7062-df90-4fc0-8697-96685184357b"
The old blockchain ID representation of the blockchain
Example:
"ETH"
The name of the blockchain
Example:
"Ethereum"
Native asset ID of this blockchain
Example:
"9f9f7062-df90-4fc0-8697-96685184356a"
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?
⌘I
TypeScript
const response: Promise<FireblocksResponse<BlockchainResponse>> = fireblocks.blockchainsAssets.getBlockchain(blockchainsAssetsApiGetBlockchainRequest);CompletableFuture<ApiResponse<BlockchainResponse>> response = fireblocks.blockchainsAssets().getBlockchain(id);response = fireblocks.blockchains_&_assets.get_blockchain(id);curl --request GET \
--url https://api.fireblocks.io/v1/blockchains/{id}const options = {method: 'GET'};
fetch('https://api.fireblocks.io/v1/blockchains/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.fireblocks.io/v1/blockchains/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.fireblocks.io/v1/blockchains/{id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.fireblocks.io/v1/blockchains/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "9f9f7062-df90-4fc0-8697-96685184357b",
"legacyId": "ETH",
"displayName": "Ethereum",
"nativeAssetId": "9f9f7062-df90-4fc0-8697-96685184356a",
"onchain": {
"protocol": "EVM",
"test": false,
"signingAlgo": "ECDSA_SECP256K1",
"chainId": 1
},
"metadata": {
"scope": "GLOBAL",
"deprecated": false,
"media": [
{
"url": "https://example.com/image.png",
"type": "image/svg+xml"
}
],
"explorer": {
"base": "https://example.com",
"address": "https://example.com/address/{address}",
"tx": "https://example.com/tx/{tx}",
"token": "https://example.com/nft/{contract}/{tokenId}"
}
}
}{
"message": "Blockchain with specified ID not found",
"code": 1505
}{
"message": "Internal server error",
"code": 3005
}{
"message": "<string>",
"code": 123
}