Get the network exchange rate to estimate costs
Last updated 8 months ago
Returns the network's exchange rate, current and next.
OK
const response = await fetch('https://mainnet.hedera.validationcloud.io/v1/YOUR_API_KEY/api/v1/network/exchangerate', { method: 'GET', headers: {}, }); const data = await response.json();
{ "current_rate": { "cent_equivalent": 596987, "expiration_time": 1649689200, "hbar_equivalent": 30000 }, "next_rate": { "cent_equivalent": 596987, "expiration_time": 1649689200, "hbar_equivalent": 30000 }, "timestamp": "1586567700.453054000" }