Skip to content

Instantly share code, notes, and snippets.

@patcito
Created March 28, 2026 02:25
Show Gist options
  • Select an option

  • Save patcito/745918bde7487e57bb5c02c5e5ea877e to your computer and use it in GitHub Desktop.

Select an option

Save patcito/745918bde7487e57bb5c02c5e5ea877e to your computer and use it in GitHub Desktop.

API Updates (2026-03-28)

1. Per-chain series in /status/ftusd/dashboard

Series data (price, ftUsdSupply, sftUsdSupply, apy) is now available per chain inside each chains[] entry.

GET /status/ftusd/dashboard?days=360&include_series=true&chain_ids=146
{
  "chains": [{
    "chainId": 146,
    "series": {
      "price": [{ "timestamp": "2026-03-01", "value": 1.0001 }, ...],
      "ftUsdSupply": [{ "timestamp": "2026-03-01", "value": 125000.50 }, ...],
      "sftUsdSupply": [{ "timestamp": "2026-03-01", "value": 80000.25 }, ...],
      "apy": [{ "timestamp": "2026-03-01", "value": 5.2 }, ...]
    },
    ...
  }],
  "series": { ... }  // top-level still present (aggregated across all chains)
}

2. hfLiquidationWarning in /mm/lend

New field on each chain: hfLiquidationWarning = marginHfSafeBps from the config registry. This is the HF below which new user actions (borrow, withdraw) are blocked.

  • Prod: 1.6
  • Dev: 1.5
{
  "chains": [{
    "chainId": 146,
    "hfLiquidationThreshold": 1.25,
    "hfLiquidationWarning": 1.6,
    ...
  }]
}
Field Meaning Current prod value
hfLiquidationThreshold HF below which positions get liquidated 1.25
hfLiquidationWarning HF below which new borrows/withdrawals are blocked 1.60

3. CB polling endpoint: GET /mm/lend/cb

Lightweight endpoint for polling circuit breaker limits when a withdraw drawer is open.

GET /mm/lend/cb?chain_id=146&token=0x29219dd400f2Bf60E5a23d13Be72B486D4038894
{
  "code": 200,
  "success": true,
  "data": {
    "circuitBreakerLimit": 49.77,
    "circuitBreakerLimitUsd": 49.76
  }
}

4. Lending earnings now populated in /mm/lend?user={address}

totalEarnings, totalEarningsUsd, claimableEarnings, claimableEarningsUsd now return claimable FT token rewards from epoch distributions (priced at $0.10/FT). Available at asset, chain, and global levels in userMetrics.

{
  "userMetrics": {
    "totalEarningsUsd": 0.000228,
    "claimableEarningsUsd": 0.000228
  }
}

totalEarnings = FT token amount, totalEarningsUsd = FT amount × $0.10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment