REST API
Public read endpoints. All return JSON, no authentication, CORS open. Base URL: https://lumpfun.com. All bigint values (lovelace, token quantities, reserves) are returned as strings to preserve precision; convert to BigInt on the client.
Endpoints
GET /api/tokensGET /api/token/{policyId}GET /api/curveGET /api/quoteGET /api/holdersGET /api/tradesGET /api/price-historyGET /api/wallet-assetsErrors/api/tokens
List every token registered with LumpFun, ordered newest first. Each entry is the full TokenMetarecord — the same shape stored in our KV registry.
Response (200) — array of:
{
"policyId": "ec11a20dc05761a24c415cfc85b42ef5b31caa52dd501082d6744b9c",
"assetName": "4d5547", // hex of utf-8 ticker
"ticker": "MUG",
"name": "Mug",
"creatorAddress": "addr1q...", // bech32 of creator wallet
"creatorFeeBps": 100, // 100 = 1%, max 200
"curveAddress": "addr1w...", // bonding-curve script
"validatorCbor": "59...", // parameterised PlutusV3
"graduationAdaLovelace": "21000000000", // optional, default 21k ADA
"imageUri": "https://...",
"description": "...",
"website": "https://...", // all socials optional
"twitter": "@handle",
"telegram": "t.me/...",
"discord": "discord.gg/...",
"launchedAt": "2026-05-05T11:48:29.797Z",
// Set when graduation has happened:
"graduatedTxHash": "f326c7...",
"minswapPoolTxHash": "77d4bd...",
"minswapPoolId": "ec11a2...4d5547",
"poolAdaLovelace": "12000000",
"poolTokens": "3970836",
// Set when creator picked a launch vesting window:
"vestingAddress": "addr1w...",
"vestingValidatorCbor": "...",
"vestingUnlockMs": 1799123456000,
"vestingClaimedTxHash": "...",
"extraVestings": [ /* additional re-vest positions */ ],
// Set on tokens launched after the fee accumulator shipped:
"feeAccumulatorAddress": "addr1w...",
"feeAccumulatorValidatorCbor": "...",
"feeAccumulatorClaimedTxHash": "..."
}curl
curl https://lumpfun.com/api/tokensts
const tokens = await fetch('https://lumpfun.com/api/tokens').then(r => r.json());
for (const t of tokens) {
console.log(t.ticker, t.policyId);
}/api/token/{policyId}
Single token lookup with live curve state attached. Cheaper than fetching /api/tokens and filtering when you already know the policy ID.
Response (200):
{
...all TokenMeta fields,
"live": {
"adaReserve": "12345678", // lovelace currently at the curve
"tokenReserve": "987654321", // tokens still purchasable
"priceLovelace": "12500", // (adaReserve+virtual)*1e6/tokenReserve
"marketCapAda": 4321.5, // priceLovelace * total_supply / 1e6
"bondedPct": 5.88, // 0–100, 100 = at graduation
"graduated": false
}
}live is null for fully-graduated tokens whose curve UTxO has been drained — read poolAdaLovelace / poolTokens from the meta instead.
curl
curl https://lumpfun.com/api/token/ec11a20dc05761a24c415cfc85b42ef5b31caa52dd501082d6744b9c/api/curve
Raw on-chain curve state. The lowest-latency way to poll reserves for a trading agent — bypasses any cache layer above Blockfrost.
Query params:
| name | description | |
|---|---|---|
| address | bech32 curve script address (from token meta) | required |
| asset | concatenation of policyId + assetName (hex) | required |
Response (200):
{
"adaReserve": "5000000", // lovelace in the curve UTxO
"tokenReserve": "996679946" // tokens still in the curve
}Returns 404 with {"error":"curve UTxO not found"} after the token has graduated and the UTxO is gone.
Side effect:any GET to this endpoint also kicks off a graduation check for that token. If reserves have crossed the threshold and the migration hasn't run yet, the server queues it. Idempotent and safe to poll.
curl
curl "https://lumpfun.com/api/curve?address=addr1wxp8497v67f4vzpsrqmc97rv2vyq6vntrzkz4pc2ce92sncmzz5z5&asset=ec11a20dc05761a24c415cfc85b42ef5b31caa52dd501082d6744b9c4d5547"/api/quote
Pre-trade quote computed against live reserves with the on-chain curve math (quoteBuy / quoteSellGross from web/src/lib/curve-math.ts). Same numbers the validator will check at submit time — use this so your agent and the chain agree.
Query params:
| name | description | |
|---|---|---|
| policyId | token policy ID (from registry) | required |
| side | "buy" or "sell" | required |
| amount | bigint string. Buy: lovelace in. Sell: tokens in. | required |
| slippageBps | 0–500. Default 50 (0.5%). | optional |
Response (200):
{
"side": "buy" | "sell",
"policyId": "...",
"assetUnit": "<policyId><assetName>",
"amountIn": "5000000",
"expectedOut": "166112956", // tokens (buy) or lovelace gross (sell)
"minOut": "165280391", // expectedOut after slippage applied
"creatorFeeBps": 100,
"creatorFeeLovelace": "50000", // bps × ada_in (buy) or × ada_gross (sell)
"platformFeeLovelace": "1000000", // flat 1 ADA, paid by buyer/seller
"adaNetLovelace": "...", // sell only — gross − creator − platform
"reserves": { "adaReserve": "...", "tokenReserve": "..." },
"graduated": false,
"slippageBps": 50
}Returns 409 if the curve has graduated (no longer tradeable on the bonding curve; route via Minswap V2 instead).
curl (buy 5 ADA)
curl "https://lumpfun.com/api/quote?policyId=POLICY&side=buy&amount=5000000"curl (sell 1M tokens)
curl "https://lumpfun.com/api/quote?policyId=POLICY&side=sell&amount=1000000"/api/holders
Top holders of an asset, derived from Blockfrost's asset-addresses index. Includes the bonding curve and any vesting script addresses — filter client-side if you only want wallets.
Query params:
| name | description | |
|---|---|---|
| asset | concatenation of policyId + assetName (hex) | required |
Response (200) — array of:
{
"address": "addr1q...",
"quantity": "996679946" // bigint string
}curl
curl "https://lumpfun.com/api/holders?asset=ec11a20dc05761a24c415cfc85b42ef5b31caa52dd501082d6744b9c4d5547"/api/trades
Recent trades on a curve, derived from on-chain tx deltas. Sorted newest first, capped at 25 entries. Each row reports the actual buyer/seller (the wallet that signed the tx, identified via inputs — not the treasury or creator-fee output addresses).
Query params:
| name | description | |
|---|---|---|
| address | bech32 curve script address | required |
| asset | concatenation of policyId + assetName | required |
Response (200) — array of:
{
"txHash": "9a1b2c...",
"type": "buy" | "sell",
"adaDelta": "10000000", // |Δ ada_reserve| in lovelace
"tokenDelta": "32156789", // |Δ token_reserve| in token units
"trader": "addr1q...",
"blockTime": 1777991234 // unix seconds
}Cached for 24h per tx-hash via Next.js ISR — recent trades come live, deeper history is stable so we don't re-query Blockfrost on every page load.
/api/price-history
OHLC bars for chart rendering. Server buckets trades into the requested timeframe. Same query params as /api/trades plus the bucket size.
Query params:
| name | description | |
|---|---|---|
| address | bech32 curve script address | required |
| asset | concatenation of policyId + assetName | required |
| timeframe | "5m" | "15m" | "1h" | "all". Default "15m". | optional |
Response (200) — array of bars:
{
"t": "5/5 13:00", // formatted display label
"timestamp": 1777991100, // unix seconds (bucket start)
"open": 0.04,
"high": 0.045,
"low": 0.04,
"close": 0.043
}Prices are floating-point ADA-per-token, derived from the curve datum at each tx (not lovelace). For the precise on-chain price use /api/curve → spotPrice from curve-math.
/api/wallet-assets
Non-ADA assets held by a Cardano address, with LumpFun registry metadata joined on for any asset that was launched via this protocol.
Query params:
| name | description | |
|---|---|---|
| address | bech32 (mainnet addr1...) | required |
Response (200):
{
"assets": [
{
"unit": "ec11a20...4d5547",
"quantity": "3298081",
"registry": { // present only for LumpFun-launched tokens
"policyId": "ec11a20...",
"assetName": "4d5547",
"ticker": "MUG",
"name": "Mug",
"imageUri": "https://..."
}
}
]
}Returns {"assets": []} (status 200) if Blockfrost hasn't indexed the address yet — common for fresh wallets that haven't transacted.
Errors
Errors are JSON with a single error field. Common shapes:
400— missing/invalid query params (e.g. non-bigintamount).404— token not in registry, or curve UTxO not on-chain (graduated tokens).409— operation not applicable to current state (e.g. quote on a graduated curve).500— internal error. Includes the message from the underlying source (Blockfrost, Lucid, etc.).502— upstream Blockfrost rejected the call. Usually means a malformed address.