CPI Route Accounts
POST /api/v1/cpi/route-accounts — Build the route instruction for another program to call via CPI, signed by its PDA.
Headers
Optional API key: Bearer vulcx_.... Anonymous calls are allowed but capped at a small per-IP rate limit — see Rate limits.
"Bearer vulcx_..."
Body
Parameters for building the route instruction as a CPI target. Like InstructionsRequest, but the signer is a calling program's PDA (the on-chain authority that will invoke_signed into route) rather than a wallet.
The calling program's PDA authority — owns the token accounts and signs the swap via invoke_signed inside the integrating program.
"EJxE7RDaP5pmoVzzHRb4fufCNq3wsCgdUbJ8PCXHZNUP"
"So11111111111111111111111111111111111111112"
"uSd2czE61Evaf76RNbq4KPpXnkiL3irdzgLFUMe3NoG"
Amount in the smallest token units.
"1000000000"
ExactIn, ExactOut "ExactIn"
50
Route corridor: multi-hop routes may only pass through these mints, closing the requiredTokenAccounts set over ATAs you pre-provisioned. Input and output mints are implicitly allowed. Empty/omitted = unrestricted.
16Cap on route length (1 = direct pools only). 0/omitted = server default.
2
DEX types to exclude from routing. Excluding "moonit" also lifts the authority-writable requirement on the CPI.
vortex, fluxbeam, moonit Optional referrer wallet (base58). Receives integratorFeeBps in full, paid on-chain in the output token in the same transaction as the swap. Required whenever integratorFeeBps is set.
"EJxE7RDaP5pmoVzzHRb4fufCNq3wsCgdUbJ8PCXHZNUP"
Your own fee rate in basis points of the output, kept by you in full. Requires referrer — a rate with no wallet to pay it to returns 400. Added to platformFeeBps, not carved out of it; the sum may not exceed 100 bps.
0 <= x <= 10020
Response
Route CPI account list built successfully.
true
The route instruction shaped for a CPI caller. Forward routeInstruction.accounts into your program's route CPI and sign with the PDA seeds. requiredTokenAccounts are the ATAs the authority PDA must own and fund before the CPI runs — this builder emits no ATA-create or wrap/unwrap instructions.