IDL
The raffl program ships its IDL on-chain. Anchor publishes it during the same upload as the bytecode.
Reading the IDL
For the canonical, always-current IDL, fetch it from the deployed program. The version in the repo is a snapshot.
Where it lives
- On chain. Published to the program's metadata account at deployment. Anchor's CLI fetches it directly.
- In the repo.
web/lib/idl/raffl.jsonandprogram/target/idl/raffl.json. Same content, different paths. The repo copy gets refreshed when the program redeploys. - In the Codama-generated client.
web/lib/program-client/holds the typed TS client generated from the IDL. The frontend uses this for everything except the Switchboard settle flow.
Fetching from chain
anchor idl fetch Finb5eCnqTNm33ssqS2ofEnuoHzCmXaWfuXEn4HcaGRA \
--provider.cluster devnet \
--out raffl.json
Or with the Solana Explorer: view the program and click the Anchor Program IDL tab.
The IDL describes nine instructions, four account layouts (RafflePlatform, Raffle, Ticket, plus the Switchboard RandomnessAccountData it reads), and the program's error enum. See Instructions for a per-call summary.