Skip to main content
POST /api/v2/swap Re-quotes selected routes (including the optional Kyber variant), validates the plan, and builds an unsigned exact-input transaction. The user minimum, recipient, input and deadline are bound in Route settlement. No Route fee is deducted; all actual settlement output goes to the recipient. Unlike quote candidate assessment, this endpoint performs no caller balance/allowance check, approval, whole-swap simulation, signature or submission. Maximum JSON body: 16384 bytes. Integrators must simulate from the signing wallet after any approval and preserve the reviewed minimum if a provider is reselected. For zerox, provide txOrigin as the signing EOA. 0x calldata is rebuilt for this origin and the separate Route executor; never approve Settler. Its opaque actions and inner minimum remain unchanged, while the outer contract enforces the exact reviewed user minimum and deadline. An inner 0.5% minimum can make a swap fail even when a looser outer tolerance would permit it. Changing executors requires a fresh approval review. Active executors have no fee recipient, administrator or fee-rate setter. Direct venue membership and supported fee tiers are server-controlled. Experimental Sushi/Pancake integrations are not active API coverage; clients cannot enable them by submitting adapter or factory addresses. Resolve the reviewed spender from the output-specific configuration map. If Kyber uses a distinct token-output executor, upstream delivery goes directly to the requested recipient and its actual token balance delta enforces the minimum. Native ETH output retains the existing forwarding guard. No request field may override the executor, receiver policy or fee. Complete the JSON body within five seconds; stalled bodies return 408 BODY_TIMEOUT. Unexpected transport failures are logged without raw provider error text. No API key or site login is required on the public production service. Request limits and validation still apply.

JSON fields

Compute a meaningful minimum from your quote and chosen slippage. Do not use zero or a nominal dust minimum. Consult the complete schema for address formats and route structures.

Responses

  • 200: Unsigned swap, optional exact approval, fresh estimate and simulationRequired=true.
  • 400: Structured error; see errors and access.
  • 408: BODY_TIMEOUT: complete the JSON body within five seconds.
  • 409: Structured error; see errors and access.
  • 413: Structured error; see errors and access.
  • 415: Structured error; see errors and access.
  • 422: Structured error; see errors and access.
  • 429: Structured error; see errors and access.
  • 503: Structured error; see errors and access.
Full request and response schemas · Errors and access