IDL SubmissionsYou can submit any program for decoding that has a public IDL or GitHub repo (Anchor, native, and system are supported), for example Jupiter on Solscan. Use dune.com/contracts/new and select Solana, or see Solana program decoding submissions for the full flow and IDL requirements.
instruction_calls, so you can refer there for most of the types. We only add columns for each argument in the function call data and each account that was required to be in account_arguments. These only decode from instructions, and not inner instructions.
Example IDL Decoded Walkthrough
Using an IDL, we decode the function data arguments and the required account arguments. Let’s look at an example using Whirlpool - normally you can find the IDL on Solscan, but this time we had to dig into the project repo. IDLs are like ABIs on Ethereum, except they are created from the Anchor lang project instead of natively from every program. Here’s a transaction of a pool (a trading pair) being initialized. You can see that the instruction data is decoded in “Bumps”, “TickSpacing”, and “InitialSqrtPrice” on the explorer. We have the same thing in a SQL table! You can also see all the account names are labelled clearly as well with anaccount_ prefix. Raw table inherited columns like tx_id, block_time, tx_index get a call_ prefix.
The main thing to note is that we’ve exploded outer and inner instructions, where the index will match what you see on explorers. This example call is at the outer instruction level, so the inner instruction index is null. For Whirlpool swaps, often times it will happen in inner_instructions so then the top level outer instruction is inherited into the call_outer_instruction_index and the inner index is call_inner_instruction_index (same idea with the call_outer_executing_account and call_inner_executing_account)
Try it out for yourself in this query below:
<namespace>_solana.<programName>_call_<instructionName>
We already have many of the top projects decoded, so go explore!