DevelopersDraft

Swap API

One HTTP call returns the best route and ready-to-sign calldata. No SDK needed.

What it is

One HTTP call returns the best route for a swap on Robinhood Chain and ready-to-sign calldata. No SDK is needed: any language that can make an HTTP request can integrate.

Draft request

http
GET <host>/v1/swap
  ?chainId=4663
  &tokenIn=<address>
  &tokenOut=<address>
  &amountIn=<integer, token base units>
  &slippageBps=<integer>
  &recipient=<address>
  &integrator=<partner fee address, optional>
  &integratorFeeBps=<integer, max 50, optional>
ParameterMeaning
chainIdRobinhood Chain, 4663
tokenIn / tokenOutToken addresses
amountInAmount to sell, in base units
slippageBpsRequested slippage; capped by Hard limits
recipientAddress that receives the output
integratorYour address for the integrator fee
integratorFeeBpsIntegrator fee in basis points, up to 50 (0.5%)

Draft response

json
{
  "chainId": 4663,
  "block": "<block number the quote was built at>",
  "amountIn": "<string>",
  "amountOut": "<string>",
  "minAmountOut": "<string>",
  "priceImpactBps": "<integer>",
  "route": [
    { "venue": "<uniswap-v3 | uniswap-v4 | aggregator-hook>", "pool": "<address>", "shareBps": "<integer>" }
  ],
  "simulation": { "ok": true },
  "integratorFee": { "recipient": "<address>", "bps": "<integer>" },
  "tx": { "to": "<address>", "data": "<0x…>", "value": "<string>" }
}

Values in angle brackets are placeholders, not real data.

What the engine does before answering

The same checks as the app: pinned contracts before quoting, and route simulation against the live chain before calldata is returned.