Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.mobula.io/llms.txt

Use this file to discover all available pages before exploring further.

Single endpoint, same shape as EVM / TON. The Solana-specific calldata sits under data.solana. See the Swap Quoting page for the full input parameters.

Native sentinel

So11111111111111111111111111111111111111112
Wrapped SOL — used as the canonical native-SOL identifier. The router unwraps automatically when needed.

Request

GET /api/2/swap/quoting?chainId=solana:solana
  &tokenIn=So11111111111111111111111111111111111111112
  &tokenOut=EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
  &amount=1
  &walletAddress=8ZmF…
  &slippage=1
  &priorityFee=high
  &jitoTipLamports=10000
  &feePercentage=0.5
  &feeWallet=8ZmF…
ParamRequiredNotes
chainIdsolana:solana
tokenIn / tokenOutMint address. Native SOL = So111…112 (wSOL).
amount or amountRawHuman-readable ("1.5") or raw ("1500000" for 6-decimal USDC)
walletAddressUser’s Solana base58 pubkey
slippage% (0-100, default 1)
priorityFeeauto | low | medium | high | veryHigh | number (microLamports/CU)
computeUnitLimittrue (dynamic) or fixed CU number (default 400 000)
jitoTipLamportsAdd a Jito tip transfer to one of the official tip accounts
multiLandertrue returns N candidates over a durable nonce — see Multi-lander
landerTipLamportsPer-lander tip when multiLander=true
payerAddressFee abstraction — separate fee payer from walletAddress
feePercentageCaller referral fee 0-99% (taken from input or output SOL)
feeWalletRequired when feePercentage > 0
onlyRoutersComma-list of jupiter,naos,kyberswap,lifi
excludedProtocols / onlyProtocolsDEX-level filter (e.g. raydium,orca,pump-amm)

Response — data.solana

{
  "data": {
    "amountOutTokens": "245.123",
    "amountInUSD": 200.45,
    "amountOutUSD": 199.87,
    "slippagePercentage": 1,
    "marketImpactPercentage": 0.04,
    "poolFeesPercentage": 0.25,
    "tokenIn":  { "address": "So111…112", "symbol": "SOL",  "decimals": 9 },
    "tokenOut": { "address": "EPjF…",     "symbol": "USDC", "decimals": 6 },
    "requestId": "f8b2…",
    "details": {
      "route": {
        "hops": [
          { "poolAddress": "5Q5…", "exchange": "Raydium", "poolType": "CLMM", "feeBps": 25 }
        ],
        "totalFeePercentage": 0.25,
        "aggregator": "jupiter"
      }
    },
    "fee": { "amount": "0.001", "percentage": 0.5, "wallet": "8ZmF…", "deductedFrom": "input" },
    "solana": {
      "transaction": {
        "serialized": "base64-encoded-VersionedTransaction-bytes",
        "variant": "versioned"
      },
      "lastValidBlockHeight": 269450123
    },
    "evm": null,
    "ton": null
  }
}

data.solana fields

FieldTypeDescription
transaction.serializedbase64Full Solana transaction. Deserialize with VersionedTransaction.deserialize (or Transaction.from for legacy).
transaction.variant'versioned' | 'legacy'Discriminator — almost always 'versioned' in practice.
lastValidBlockHeightnumberBlockhash expiry — your client should broadcast before the chain ticks past this.

Multi-lander

Set multiLander=true to receive N candidate transactions sharing a durable nonce. Race them across Jito / Nozomi / 0slot for fastest landing — only one can commit.
{
  "data": {
    "candidates": [
      { "lander": "jito",     "serialized": "base64…", "tipAccount": "Cw8C…", "tipLamports": 1000 },
      { "lander": "nozomi",   "serialized": "base64…", "tipAccount": "TpdX…", "tipLamports": 1000 },
      { "lander": "zeroslot", "serialized": "base64…", "tipAccount": "6fQa…", "tipLamports": 1000 }
    ],
    "nonceAccount": "Hgs…",
    "nonceAuthority": "BvW…",
    "solana": null,
    "evm": null,
    "ton": null
  }
}
Sign every candidate, POST them all to /swap/send in batch mode (candidates: [{lander, signedTransaction}, …]).

Signing

import { VersionedTransaction } from '@solana/web3.js';

const tx = VersionedTransaction.deserialize(
  Buffer.from(quote.data.solana.transaction.serialized, 'base64'),
);
// Sign via wallet (Phantom / Privy / Backpack / etc.).
const signed = await wallet.signTransaction(tx);
const signedBase64 = Buffer.from(signed.serialize()).toString('base64');

await fetch('/api/2/swap/send', {
  method: 'POST',
  body: JSON.stringify({ chainId: 'solana:solana', signedTransaction: signedBase64 }),
});

Supported aggregators

Jupiter, KyberSwap, NAOS, Li.Fi — pick one or several via onlyRouters. Per-DEX filtering (Raydium, Orca, Meteora DLMM/Damm, Pump AMM, Whirlpool, …) via onlyProtocols / excludedProtocols.

Limits

  • Blockhash expirylastValidBlockHeight is ~150 slots (60s). Re-quote if the user takes longer than that to sign.
  • CU price — when bundling with Jito, set priorityFee and jitoTipLamports together for best landing.
  • Address forms — Solana addresses are case-sensitive base58. Don’t lowercase.