Get gas station settings by asset
Returns gas station settings and balances for a requested asset. Endpoint Permission: Admin, Non-Signing Admin, Signer, Approver, Editor.
GET
/
gas_station
/
{assetId}
TypeScript
const response: Promise<FireblocksResponse<GasStationPropertiesResponse>> = fireblocks.gasStations.getGasStationByAssetId(gasStationsApiGetGasStationByAssetIdRequest);CompletableFuture<ApiResponse<GasStationPropertiesResponse>> response = fireblocks.gasStations().getGasStationByAssetId(assetId);response = fireblocks.gas_stations.get_gas_station_by_asset_id(asset_id);curl --request GET \
--url https://api.fireblocks.io/v1/gas_station/{assetId}const options = {method: 'GET'};
fetch('https://api.fireblocks.io/v1/gas_station/{assetId}', 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/gas_station/{assetId}",
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/gas_station/{assetId}"
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/gas_station/{assetId}")
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{
"balance": {},
"configuration": {
"gasThreshold": "<string>",
"gasCap": "<string>",
"maxGasPrice": "<string>"
}
}{
"message": "<string>",
"code": 123
}Was this page helpful?
Previous
Edit gas station settingsConfigures gas station settings for ETH.
Learn more about the Fireblocks Gas Station in the following [guide](https://developers.fireblocks.com/docs/work-with-gas-station).
Endpoint Permission: Admin, Non-Signing Admin, Signer, Approver, Editor.
Next
⌘I
TypeScript
const response: Promise<FireblocksResponse<GasStationPropertiesResponse>> = fireblocks.gasStations.getGasStationByAssetId(gasStationsApiGetGasStationByAssetIdRequest);CompletableFuture<ApiResponse<GasStationPropertiesResponse>> response = fireblocks.gasStations().getGasStationByAssetId(assetId);response = fireblocks.gas_stations.get_gas_station_by_asset_id(asset_id);curl --request GET \
--url https://api.fireblocks.io/v1/gas_station/{assetId}const options = {method: 'GET'};
fetch('https://api.fireblocks.io/v1/gas_station/{assetId}', 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/gas_station/{assetId}",
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/gas_station/{assetId}"
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/gas_station/{assetId}")
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{
"balance": {},
"configuration": {
"gasThreshold": "<string>",
"gasCap": "<string>",
"maxGasPrice": "<string>"
}
}{
"message": "<string>",
"code": 123
}