Skip to main content
This page is a cheat-sheet. Bookmark it.

IDL sources

Get them via:
The frontend/lib/idl/ directory packages the same IDLs for the official frontend - copy from there if you don’t want to clone the full protocol repo.

PDA derivation cheatsheet

All PDAs use findProgramAddressSync(seeds, programId). In @solana/web3.js:

mint-redeem PDAs

oracle PDAs

In practice you don’t derive oracle_config - you read market.oracle_address directly from the Market account. The derivation is here for completeness.

clp PDAs

registry PDAs

Note the registry uses a 16-byte zero-padded symbol, while mint-redeem uses the raw symbol bytes. They are different PDA seeds - don’t confuse them.

faucet PDAs

Token accounts (ATAs)

ATAs are not PDAs of Continuum’s programs but you’ll derive them constantly:

Composing a mint call

For mint_paired, you need:
Note the dependency chain:
  1. Derive marketPDA from symbol.
  2. Fetch market (one RPC call).
  3. From the fetched market, derive all child accounts.
In production, batch the market fetch with the user’s ATA balance fetch via getMultipleAccountsInfo.

Account-fetch helpers

For multi-market batched reads:

Discriminators

Each Anchor account / instruction has an 8-byte discriminator. You don’t compute these by hand - Anchor handles it. But if you need to manually decode account data without an IDL:
The discriminator is sha256("account:Market").slice(0, 8). The keeper uses these manually for performance reasons; clients should rely on Anchor’s coder.accounts.decode.

See also

SDK setup

Project bootstrap + first read.

End-to-end example

Mint and redeem in one script.