sodax-sdk-swap

Installation
SKILL.md

Swap (Core SDK granular skill)

Granular skill for the swap feature of @sodax/sdk v2. Source-of-truth reference lives in the parent broad skill's knowledge tree — this file is the focused workflow only.

Step 1 — Clarify with user before coding

Swap has materially different code paths depending on the answers. Don't skip:

  1. Are you writing new code, or porting v1 code to v2?
    • New code → § Integration workflow below.
    • Port v1 → v2 → § Migration workflow.
  2. Signed flow (frontend wallet, browser/RN) or unsigned-tx flow (backend / custom relay)?
    • Signed → raw: false + walletProvider.
    • Unsigned → raw: true, you handle relay yourself.
  3. One-shot swap() or step-by-step (createIntent → backend submit → postExecution)?
    • One-shot is the default for frontends. Step-by-step is for backends that already have a relay/orchestration layer.
  4. Market order or limit order? Limit orders use a different params shape (no deadline).

Integration workflow (writing new v2 swap code)

Installs
1
First Seen
Jun 10, 2026
sodax-sdk-swap — icon-project/sodax-sdks