Quark: DeFi Queries Acceleration
How it Works
Mainnet DeFi getProgramAccounts queries get accelerated by RPC Fast's custom-built accounts engine, including eligible programs, commitments, and filter shapes.
RPC Fast automatically routes eligible Mainnet Beta getProgramAccounts and getProgramAccountsPaginated requests through a custom-built accounts engine. It replaces broad program scans with bounded account-type or mint indexes for selected DeFi protocols. You keep the same RPC endpoint and the standard Solana account response shape.
Queries that do not match the shapes below continue through the normal RPC path. Acceleration is therefore additive; no client-side routing or protocol-specific API is required.
Common Requirements
An accelerated request must:
use one of the program IDs listed below;
set
encodingexplicitly tobase64;include a non-empty
filtersarray;use
processed,confirmed, orfinalizedcommitment (omittingcommitmentusesfinalized);use standard
dataSizeandmemcmpfilters. Mint filters must decode to exactly 32 bytes;memcmp.bytesmay be base58 or base64.
All supplied filters are applied to the returned accounts. dataSlice and withContext are supported.
For getProgramAccountsPaginated, limit must be a positive integer and paginationKey, when present, must be the opaque string returned by the previous page. Accelerated compact mint-index queries support up to 1,000 accounts per page; other accelerated layouts support up to 10,000. See getProgramAccountsPaginated for the complete pagination contract.
Eligible Programs and Filter Shapes
All entries below support processed, confirmed, and finalized.
Pump.fun PumpSwap Pool
pAMMBay6oceH9fJKBRHGP5D4bD4sWpmSwMn52FMfXEA
One or both 32-byte mint memcmp filters: base mint at offset 43, quote mint at 75. Optional account selectors: dataSize: 301, discriminator hQrXeCntzbV at offset 0.
Orca Whirlpools Whirlpool
whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc
Both 32-byte mint filters: token A at offset 101, token B at 181. Optional selectors: dataSize: 653, discriminator BdrfaPg3xM6 at offset 0.
Meteora DAMM v2 Pool
cpamdpZCGKUy5JxQXB4dcpGPiikHawvSWAd6mEn1sGG
Both 32-byte mint filters: token A at offset 168, token B at 200. Optional selectors: dataSize: 1112, discriminator hQrXeCntzbV at offset 0.
Meteora DLMM LbPair
LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo
Both 32-byte mint filters: token X at offset 88, token Y at 120. Optional selectors: dataSize: 904, discriminator 6XZoLajBWVJ at offset 0.
Raydium AMM v4 LiquidityStateV4
675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8
One or both 32-byte mint filters: base mint at offset 400, quote mint at 432. Optional selector: dataSize: 752.
Raydium CLMM PoolState
CAMMCzo5YL8w4VFF8KVHrK22GGUsp5VTaW7grrKgrWqK
One or both 32-byte mint filters: mint 0 at offset 73, mint 1 at 105. Optional selector: dataSize: 1544.
Raydium CPMM PoolState
CPMMoo8L3F4NbTegBCKVNunggL7H1ZpdTHKxQB5qKP1C
One or both 32-byte mint filters: token 0 at offset 168, token 1 at 200. Optional selectors: dataSize: 637, discriminator iUE1qg7KXeV at offset 0.
Jupiter v6 TokenLedger
JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4
dataSize: 48 and a memcmp at offset 0 beginning with discriminator TFkui5QKQvG. Additional filters are allowed.
Jupiter Token Ledger flow — this flow does not discover ledgers with getProgramAccounts.
HumidiFi pool accounts
9H6tua7jkLhdm3w8BvgpTn5LZNU7g4ZynDmCiNN3q6Rp
dataSize: 1728. Additional filters are allowed.
Public HumidiFi litepaper — no official public account-query example is currently available.
Kamino Lending Obligation
KLend2g3cP87fffoy8q1mQqGKjrxjC8boSyAYavgmjD
dataSize: 3344. Additional filters are allowed.
The optional account selectors shown for mint-indexed layouts are recommended when your integration already knows the account type, but they are not required for acceleration. The mint filters are required exactly as listed.
How protocol SDK queries map to acceleration
Protocol documentation may show an SDK helper rather than the raw RPC request it generates. Acceleration applies only when the client actually sends getProgramAccounts or getProgramAccountsPaginated with an eligible shape.
Orca
fetchWhirlpoolsByTokenPair first uses getProgramAccounts to read FeeTier accounts for a Whirlpools config. It then derives pool addresses and reads them with getMultipleAccounts. Orca's lower-level fetchAllWhirlpoolWithFilter does issue a Whirlpool-account GPA with a discriminator and caller-selected filters.
Whirlpool-account GPA is accelerated when it includes both mint filters at offsets 101 and 181. Single-mint, config-only, tick-spacing, fee-rate, vault, reward, and other Orca account-type queries do not currently match the accelerated shape.
Raydium
The official fetchAllPools example issues dataSize-only GPA requests for AMM v4, CLMM, and CPMM.
Size-only all-pools scans are not accelerated. GPA requests containing the required one-mint or two-mint filters listed above are accelerated.
Pump.fun
The public PumpSwap documentation describes the Pool layout and PDA/SDK flows, but does not publish a getProgramAccounts pool-discovery example.
Raw GPA integrations with a base-mint or quote-mint filter are accelerated.
Jupiter
The official Token Ledger flow creates and uses a known ledger account; it does not discover Token Ledger accounts with GPA.
Custom raw GPA queries for TokenLedger are accelerated when they include the required size and discriminator. Additional standard filters are reapplied.
Other methods such as getAccountInfo and getMultipleAccounts do not use this GPA acceleration path.
Pair lookup example
The official Orca helper linked above does not send this Whirlpool GPA: it scans fee tiers, derives pool PDAs, and reads the derived addresses. The request below is the accelerated raw-RPC shape for discovering initialized Whirlpool accounts by both mints. It uses the same SOL/devUSDC pair as Orca's official pool-monitoring example. Replace the mints with the pair you need.
For PumpSwap, Raydium AMM v4, Raydium CLMM, and Raydium CPMM, a single mint filter at either listed offset is also eligible. Orca Whirlpools, Meteora DAMM v2, and Meteora DLMM require both mint filters.
Bounded account-type example
Jupiter v6 Token Ledger acceleration requires both its exact account size and discriminator.
HumidiFi and Kamino Lending use the same request shape with only their required dataSize filter. Additional standard filters can narrow the result further.
Last updated