SDK overview
Flint perps ships clients in three languages. All three release together as one SDK suite version and decode the same program ABI, pinned by the same golden fixtures.
| Language | Packages | Guide |
|---|---|---|
| Rust | flint-margin-user-client, flint-margin-maker-client, flint-margin-onchain | Rust |
| Python | flint-api-client (flint.margin.api, flint.margin.onchain, flint.margin.quoting) | Python |
| TypeScript | @superis-labs/flint-margin-user-client, @superis-labs/flint-margin-maker-client, @superis-labs/flint-idl | TypeScript |
Capabilities
| Capability | Rust | Python | TypeScript |
|---|---|---|---|
| Instruction builders, account and type codecs, PDAs, error table | Yes | Yes | Yes |
| Checked account decode (owner, discriminator, exact length) | parse::FlintAccount | decode_flint_account | decodeFlintAccount |
| Event batch decode | Yes | Yes | Yes |
| Transaction decode, including inner instructions | decode_flint_transaction | decode_flint_transaction | decodeFlintTransaction |
| Program error name from code | error_name | flint_error_name | getFlintErrorMessage |
| Trader spot and perp positions | Yes | Yes | Yes |
| Resting order book reader | read_resting_orders | read_resting_orders | readRestingOrders |
| Maker quote book decode | decode_aggregated_quote_book | decode_aggregated_quote_book | decodeAggregatedQuoteBook |
| Build place-order and close instructions with crossing makers | Yes | Yes | Yes |
| Grid math (lots, ticks, slippage bounds) | Yes | Yes | Yes |
Prepare an order from chain (prepare_perp_order) | rpc feature of the user client | Yes (async) | preparePerpOrder |
| Public margin-user services | Client | MarginUserClient | create*Client |
| Maker auth (signed nonce, refresh) and maker services | Yes | Yes | Yes |
TxService with Solana-RPC fallback and status polling | In QuotingCore | with_tx_fallback, poll_tx_status | withTxFallback, pollTxStatus |
QuoteBuilder | Yes | Yes | Yes (builds instructions only) |
QuotingCore (sign, submit, retry, receipts, spread protection) | Yes | Yes | No |
Session heartbeat (SessionService) | Yes | Yes | No (gRPC-Web has no bidi streams) |
| Passkey / WebAuthn delegate helpers | No | No | Yes |
| Lazer oracle-report helpers | No | No | Yes |
TypeScript targets web apps, so like the spot SDKs it has no long-running
quoting core; build quotes with QuoteBuilder and submit them yourself.
Passkey and Lazer helpers depend on browser APIs and stay TypeScript-only.
Devnet server gaps
On devnet today RiskService.SimulateAccountRisk returns INTERNAL
("perp risk inputs are unavailable") and OrderService.ListOrders returns
UNIMPLEMENTED, in every language. Read resting orders from chain with the
resting order book reader until the server serves them.
