4.5 Supply info api for Cosmos chain
Last updated
Last updated
This is an advanced supply information API for Cosmos Chain. I simplified the logic structure to improve efficiency and enable automatic switching in case of API_ENDPOINT failure.
This improves the reliability and stability of the supply information API by quickly switching to the next API_ENDPOINT when the first one fails.
- /v1/total-supply
: returns total supply in plain text
- /v1/circulating-supply
: returns circulating supply in plain text
- /v1/total-staked
: returns total staked in plain text
- /v1/bonded-ratio
: returns bonded ratio in plain text
- /v1/community-pool
: returns community pool size in plain text
- /v1/apr
: returns APR in plain text
- /v1/denom
: returns denom in plain text
- /v1
: JSON
Get total supply.
Get community pool.
Subtract community pool from total supply.
This yields the circulating supply.
See .env.example
for an example.
eg: