Skip to content

ETH price & $STFI

The ETH/USD reference price and the $STFI status.

Two small endpoints used across the app: the ETH/USD reference price and the status of the $STFI token.

GET /api/eth-price

GET/api/eth-price

CoinGecko simple/price for Ethereum. Server cache 60 s; Cache-Control: public, s-maxage=60, stale-while-revalidate=240.

200 OK
{  "data": { "usd": 3124.55, "change24h": -0.84 },  "updatedAt": 1731974400000,  "stale": false,  "source": "CoinGecko"}

GET /api/stfi

GET/api/stfi

Until NEXT_PUBLIC_STFI_ADDRESS is set to the deployed contract, the endpoint reports PRE-LAUNCH and no address, price or supply. Once it is set, token is the full TokenDetail for that address on NEXT_PUBLIC_STFI_CHAIN_ID (default 1), or null if it could not be loaded. This endpoint never returns an error status.

200 OK — before launch
{ "data": { "status": "PRE-LAUNCH", "token": null } }
200 OK — after launch
{  "data": { "status": "LIVE", "token": { "row": { "symbol": "STFI", "…": "…" }, "…": "…" } },  "updatedAt": 1731974400000}