Integration
Read the index
GET /api/index returns the live index and the inputs behind it. It is read-only and cached for 8 seconds. See the API reference for every field.
curl -s https://<site>/api/index | jq '{spot, upbit: .upbit.price, bithumb: .bithumb.price, ecb: .ecb.rate}'
Recompute it yourself
Every input is a free public endpoint. This is the full computation the site performs for the live reading:
const j = (u) => fetch(u).then((r) => r.json());
const [up, bt, fx] = await Promise.all([
j("https://api.upbit.com/v1/ticker?markets=KRW-USDT"),
j("https://api.bithumb.com/public/ticker/USDT_KRW"),
j("https://api.frankfurter.dev/v1/latest?base=USD&symbols=KRW"),
]);
const median = (up[0].trade_price + Number(bt.data.closing_price)) / 2;
const indexPp = (median / fx.rates.KRW - 1) * 100;
For a settlement value, replace the two tickers with the mean of 24 hourly closes ending at expiry (/v1/candles/minutes/60 on
Upbit, /public/candlestick/USDT_KRW/1h on
Bithumb) and use the ECB fix dated on the expiry day.
Run a reporter
A reporter is anyone who posts report(value) after expiry with the bond. The value is in ibp (1 pp = 100), rounded to the nearest ibp and clipped to the band. A correct report gets the bond back once the market settles; a wrong one loses it to a challenger.
Run a watcher
A watcher recomputes S after each report and calls dispute(value) within the dispute window when the report is wrong. The challenger wins the reporter's bond if strictly closer to the arbiters' recomputation.
Finish markets for users
claim, claim_bond and settle are permissionless and pay only the rightful owner, so any keeper can close out a series for traders who never return.