GET/pools-api/swap-quote

Claude ↗ChatGPT ↗
Auth X-Hub-Key from API_HUB_KEYExecute GET /run/orca/pools-api/swap-quoteCache cached 1s, never served stale past that windowCost free · weight 0 · standard rate classSource billing free

Read-only split-route Whirlpool swap quote returning input/output amounts, route splits, pool hops, and price impact without building a transaction.

Try this endpoint

Reads the credential from API_HUB_KEY; it never appears in the URL.

curl -sH "X-Hub-Key: $API_HUB_KEY" "https://openapihub.dev/run/orca/pools-api/swap-quote?from=So11111111111111111111111111111111111111112&to=EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v&amount=1000000000&isLegacy=False&amountIsInput=True"

Parameters

nameintypedescription
fromquerystrrequiredInput SPL token mint address.
example: So11111111111111111111111111111111111111112
toquerystrrequiredOutput SPL token mint address.
example: EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
amountquerystrrequiredRaw integer amount in base units.
example: 1000000000
isLegacyqueryboolrequiredSet false for versioned lookup-table routes, true for legacy.
default: False
example: False
amountIsInputqueryboolrequiredTrue for exact-in quote, false for exact-out.
default: True
example: True

Response

type: object
pagination: none
sample: {
  "data": "object",
  "meta": "object"
}