Reference
API
Base URL, formats, pagination and the flow of a signed transaction.
The Flare site reads one HTTP API, and anything you build on Flare can read the same one. It answers JSON, builds every transaction a wallet signs, and streams changes as Server-Sent Events.
Base URL
https://api-production-bab49449.up.railway.appRoutes are under /v1, plus /health. Reads need no key and no wallet. Writes (every POST) are limited to 60 per client per minute.
The TypeScript client
The site's API kit is built on the contract's client: one call per route, each response parsed by the same zod schema the server validates with. Its source is in the site at launchpad/contract/, and in the backend at src/contract/.
import { createClient } from '@flare/contract'
const api = createClient('https://api-production-bab49449.up.railway.app')
const { items } = await api.coins({ sort: 'attention', limit: 3 })Two sources
Every coin in the API has a source. flare is a flare launched on Flare, with its window, marketing treasury and access list. launchlab is a live token from another LaunchLab launchpad, read from Raydium's public data and scored in the same index. Its Flare-only fields are null, its holders aren't read, and its treasury and access routes answer NOT_FOUND. GET /v1/coins?source=flare lists only Flare's own. GET /health reports the feed of those tokens under feed.
Formats
- Amounts are integer strings in base units, never JSON numbers: lamports for SOL (9 decimals), base units for flare tokens (6 decimals).
"100000000"is 0.1 SOL. - Prices are decimal strings: SOL per whole token, or USD per whole token where a field says so.
- Rates are integers in parts per million, as LaunchLab and CPMM store them:
27500is 2.75%. Shares of 10,000 are basis points. - Times are ISO 8601 strings in UTC.
- Addresses and signatures are base58.
Pages
Lists that grow (/v1/coins, /v1/coins/:mint/trades) come one page at a time. Pass limit (1 to 100, 24 by default) and, for the next page, the cursor from the last one's page.nextCursor. page.hasMore is false on the last page. Every response carries asOf, the time it was made.
Transactions
The API builds every transaction; the wallet only signs.
- Build.
POST /v1/launch/buildorPOST /v1/trade/buildanswers abuild: the unsigned v0 transaction in base64, its blockhash andlastValidBlockHeight, andcosigned. - Sign. The wallet signs. If
cosignedistrue(every launch, since the new mint signs too), it must not send the transaction itself. - Submit.
POST /v1/transactions/submitwith the build'sid, an idempotency key and either the signed bytes (relay, the API sends it) or the signature of a transaction the wallet already sent (wallet-sent, trades only). - Follow.
GET /v1/transactions/:idanswerssubmitted, thenconfirmedandfinalized, orfailedwith the stage and reason, orexpiredonce the blockhash can no longer land.
The API checks a signed transaction against the one it built before sending it. Wallets may add their own instructions, such as compute budget; a transaction changed in any other way is refused with stage wallet-changed, and you build again.
Health
{
"status": "fixture"
}ready serves chain data. waiting means the API is up and the platform isn't on chain yet: reads answer empty and builds answer PROGRAM_UNAVAILABLE.
Fixtures
An API started in fixture mode serves the same routes from generated flares, with status: "fixture". A request can pick a scenario with the X-Fixture header (empty, waiting, migrating, graduated, expired) or force any error code's envelope by naming it. Every sample response in these pages was captured from a fixture server.