Skip to main content
ABI is the correct term here. This is the human-readable reference for the deployed Application Binary Interface, not an HTTP API. JPYC, IDRX and IDRP use the same ABI at different proxy addresses.
The Swapper ABI contains 87 functions, 25 events and 45 custom errors, including inherited OpenZeppelin entries. baseToken() returns the selected market’s JPYC, IDRX or IDRP, and quoteToken() returns Kaia USDT. Copy-ready minimal viem ABIs for taker and maker integrations are provided in Contract integration, and the complete machine-readable arrays are provided on ABI JSON.

ABI types

Enums are ABI-encoded as uint8. getOrder returns this tuple in exactly the field order above.

Maker

Taker

previewFill is not a dry run of fillOrder. It shares _quote, so its arithmetic — and its stale-oracle and maker-floor reverts — cannot drift from the real fill. But everything fillOrder checks around that is absent: pause, expiry, sellAmountOut > sellRemaining, the minimum-fill and dust rules, and the caller’s balance and allowance.It can return a quote while the desk is paused or for a size larger than the order holds. A successful preview therefore does not mean the fill will go through.

Sweeper — no role

Views

openOrderIds and expiredOrderIds clamp a caller-supplied limit that would overflow offset + limit, rather than panicking. Passing type(uint256).max is safe. For expiredOrderIds, keep following nextOffset even when the filtered ids page is empty.

Additional ABI entries

The complete ABI also contains inherited entries. Typical integrations need only hasRole, supportsInterface and paused in addition to the functions above. The exact machine-readable surface remains available on ABI JSON, while user-facing events and errors are listed in Events & errors.