Skip to content
QSwapDocs

Errors and fixes

Every error code the QSwap API returns, what it means and what to do. Plus Jupiter's execute codes.

Every non-2xx response has the same shape:

{ "error": { "code": "NO_ROUTE", "message": "human text", "details": {} } }
Every error code, and what to do
  • BAD_REQUESTA parameter is missing or malformed.Your inputCheck what you entered
  • NOT_FOUNDNo such path or resource.Your inputReload; report it if it persists
  • RATE_LIMITEDToo many requests to the API or to Jupiter.NetworkWait, then try again
  • UPSTREAM_ERRORJupiter or the Solana RPC failed.NetworkTry again
  • NO_ROUTENo route between these tokens for this amount.MarketChange the pair or amount
  • INSUFFICIENT_FUNDSYour balance is below the amount you entered.Your walletLower the amount
  • INSUFFICIENT_SOLNot enough SOL to pay network fees or rent.Your walletAdd a little SOL
  • BELOW_MINIMUMThe trade is below the gasless minimum.Your inputRaise the amount
  • ORDER_EXPIREDThe order expired before it landed.MarketGet a new price and sign again
  • EXECUTE_FAILEDJupiter could not land the transaction.MarketGet a new price and sign again
  • FEATURE_DISABLEDThis feature is turned off here.FeatureNothing: it's off on purpose
  • INTERNALSomething went wrong on the server.NetworkReload; report it if it persists
Source: docs/API-CONTRACT.md → Error shape

Execute codes

Jupiter execute codesPOST /swap/execute returns HTTP 200 with status Failed and one of these in code.
  • 0Success: the swap landed.
  • -1Order not found: it expired or the requestId is wrong. Get a new order.
  • -2The signed transaction is invalid.
  • -3The message bytes are invalid.
  • -1000The transaction failed to land.
  • -1001Unknown error.
  • -1002The transaction is invalid.
  • -1003The transaction isn't fully signed.
  • -1004Invalid block height.
  • -1005Expired: get a new order.
  • -2000…-2004RFQ (JupiterZ) errors. -2003: the market maker's quote expired.
Source: Jupiter Swap API v2 → POST /swap/v2/execute

A swap that fails to land is not an HTTP error: POST /swap/execute returns 200 with "status": "Failed", and code and error filled in.

Retries

How failed calls retry
RATE_LIMITED: waits Retry-After
UPSTREAM_ERROR, network: waits longer each time
ORDER_EXPIRED: new order, you sign again

3 tries failed: the error shows

Jupiter's order errorCode maps to API codes: 1 → INSUFFICIENT_FUNDS, 2 → INSUFFICIENT_SOL (from JupiterZ, 2 means a missing token account and maps to UPSTREAM_ERROR), 3 → BELOW_MINIMUM, no route → NO_ROUTE.