Skip to main content
Names are shown as TypeScript / Python. Rust uses the Python spelling on BoltzApiClientV2 and SwapScript. React Native exposes the same surface as Python with camelCase names, generated from the same bindings. The published TypeScript declarations (dist/index.d.ts) document every type in full.

SwapClient

The maker API client. In TypeScript it comes from SwapClient.forNetwork, new SwapClient(baseUrl, timeoutSecs?), createKaleidoOrgClient, or createKaleidoMakerClient. In Python: SwapClient.default(network), SwapClient(base_url, timeout), SwapClient.kaleido_org(...), or SwapClient.kaleido_maker(...).

Pairs and chain data

Swaps

In Python, RGB swaps set rgb_contract_id (and optionally rgb_max_htlc_sat) on the request instead of passing extra arguments.

Corridor and atomic routes

Partner credentials

SwapScript

The swap script rebuilt on your side, and the claim and refund builder. chain is "bitcoin" or "liquid". Python uses snake_case and takes a SwapTransactionParams with a Fee.RELATIVE(sat_per_vb) or Fee.ABSOLUTE(sats).

SwapMasterKey

SwapWsApi

Higher-level helpers (TypeScript)

Numbers in TypeScript

  • Parameters declared bigint need a BigInt (0n); a plain number throws a TypeError before the SDK can attach a code.
  • 64-bit fields inside request objects accept bigint | number. Unsafe numbers above Number.MAX_SAFE_INTEGER are rejected before the request is sent.
  • 64-bit response fields are always bigint, including amounts, timestamps, and the restore index. 32-bit fields (key indexes, output indexes, reverse and chain timeout heights) stay number.
  • Serialize responses with toJson, not JSON.stringify.