Skip to content

Instantly share code, notes, and snippets.

View patcito's full-sized avatar

patcito patcito

View GitHub Profile

Wallet Widget Endpoint

GET /wallet/{address}

Returns FT token balance, puts/marketplace summary, and the 3 most recent user actions for the wallet widget.

No query parameters needed — aggregates across all chains automatically.


@patcito
patcito / ftusd-hook-architecture.md
Last active February 26, 2026 19:48
ftUSD Hook Architecture — useFTUSDActions consolidation guide for frontend devs

ftUSD Hook Architecture — useFTUSDActions

What changed

We replaced 6 legacy per-action hooks with a single consolidated useFTUSDActions hook. This mirrors the pattern used in lending (useLendingActions).

Deleted hooks

  • useMintWithPermitAndFee — buy (mint) ftUSD
  • useRedeemWithPermit — sell (redeem) ftUSD
  • useStakeWithPermit — stake ftUSD to vault

FT Withdrawals Report — Ethereum PutManager

Contract: 0xbA49d0AC42f4fBA4e24A8677a22218a4dF75ebaA Event: WithdrawFT(address user, uint256 putId, uint256 amount) Report generated: 2026-02-23 21:28 UTC

Summary

Stat Value
@patcito
patcito / ftusd-dashboard-changes.md
Last active February 23, 2026 20:18
ftUSD Dashboard API changes — new fields for frontend

ftUSD Dashboard API — Frontend Integration Guide

Endpoint

GET /status/ftusd/dashboard

Query params:

  • days — number of days for series (default 7, max 360)

/mm/lend — New userTransactions Field

What changed

When a ?user=0x... query param is provided, each chain object in the response now includes a userTransactions array containing the user's deposit/withdraw/borrow/repay history on that chain.

Response shape

{
@patcito
patcito / lend-overview-endpoint.md
Created February 19, 2026 18:18
GET /mm/lend — Lending Overview Endpoint

GET /mm/lend — Lending Overview Endpoint

Returns full lending data across all chains with per-asset metrics, APY rates, token prices, and optional user positions.

Parameters

Param Type Required Description
user string No User wallet address. If omitted, all user-specific fields are 0.
@patcito
patcito / lend-overview-endpoint.md
Created February 19, 2026 17:21
GET /mm/lend — Lending Overview Endpoint

GET /mm/lend — Lending Overview Endpoint

Returns full lending data across all chains with per-asset metrics, APY rates, token prices, and optional user positions.

Parameters

Param Type Required Description
user string No User wallet address. If omitted, all user-specific fields are 0.

Lending (Money Market) API Endpoints

All responses are wrapped in { "success": true, "data": ... }. Error responses: { "success": false, "message": "..." } with HTTP 400.


GET /mm/snapshot

Aggregate market totals for a chain. Maps to LendGlobalMetrics / LendChain.globalMetrics.

Circuit Breaker Queue — USD Values

Updated: GET /status/ftusd/circuit-breaker/queue

Two new fields added per outflow: fromAmountUsd and toAmountUsd.

New Fields

Field Type Description
fromAmountUsd string USD value of fromAmount (e.g. "1.00"). Omitted if price unavailable.
@patcito
patcito / cb-limits-integration.md
Last active February 19, 2026 03:11
ftUSD Circuit Breaker V2 — Limits, Capacity & Queue Endpoints (Frontend Integration Guide)

Circuit Breaker V2 — Limits, Capacity & Queue Endpoints

New Endpoint: GET /status/ftusd/circuit-breaker/limits

Returns per-asset CB withdrawal capacity and rate limit data for all tracked assets. Use this to show "how much can user withdraw/redeem before hitting the CB rate limit" per token.

Query Params

Param Required Default Description