For the complete documentation index, see llms.txt. This page is also available as Markdown.

Integration Checklist

Checks for Arc swaps, liquidity and claims, with executable fee examples.

Use this checklist before enabling an Arc integration. Validate the actual target deployment and transaction flow against the matching contract version.

SDK transaction acceptance

Use @masterpeach/market-sdk@1.0.1, public root imports and the reviewed deployment preset. Keep the following checks when shortening examples:

Explicit prepare: true for funds operations, plus separate verifyDeployment(); neither installing the package nor a successful read enables a capability. Correct chain, wallet owner, token decimals, complete PoolKey and spender. Amounts are bigint base units; shares/liquidity are not token units. Exact, bounded allowances to the intended Hook/Router/Permit2; confirm each approval and obtain a fresh quote afterward. User-reviewed maximum spend, minimum output/shares, recipient, fee cap and chain-time deadline. Never use unlimited approval or zero protection as a shortcut. Same-client prepare → explicit user-confirmed send → saved hash → result.status === "confirmed". Check actual receipt results and recover pending/ambiguous transactions before retrying. Native funds cover both value and gas; Quoter gas is not full-transaction gas. Paused principal-only withdrawal is distinct from blocked claims and combined withdrawal/claim.

Current mainnet presets keep claimOperator: "unverified" and management disabled. Delegated claims, Compound and fee-inclusive Rebalance need separately accepted claim capability and independent range authorization; do not promote flags or disable preflight to make an example run.

Examples in Quickstart, Providing Liquidity, Fees & Claims and RWA Calendar are checked against main@b5fc5ba. Typechecking proves API usage, not funded execution or deployment acceptance.

Trading acceptance

  • Verify chain, Hook, PoolManager, configuration, initialized state and any router or Quoter deployment.

  • Cover both directions, ordinary keeper/cap boundaries, RWA sessions and exact time boundaries, and Mid-block reference transitions.

  • Isolate route branches and roll back reverted state; preserve integer rounding, zero outputs and partial-fill outcomes.

  • Simulate actual router calldata, settlement, amount bounds and deadlines. Accept exact-output separately if offered.

Liquidity and claim acceptance

  • Test deposits and partial/full withdrawals in range, below range and above range; confirm actual principal, shares and receipts.

  • Check spender-specific approvals, amount maxima/minima, deadline equality and expiry, recipient validation and insufficient balances.

  • Verify that withdraw leaves earnings unclaimed, withdrawAndClaim pays them, and a full exit can leave claimable owed fees.

  • Test the effective protocol-share cap, historical configuration changes, original-currency payouts and whole-unit/Q128 rounding.

  • Separate share approval from range claim delegation; test unauthorized claims, operator-chosen recipients and explicit revocation after exit/redeposit.

  • Test global and pool pause behavior against the exact deployment. The current SDK baseline allows principal-only withdrawal while paused; claims and combined withdrawal/claim remain pause-sensitive. The older 314ed215 reference blocks principal withdrawal too; do not substitute one version's operation matrix for another.

  • For batch claims, test grouping by chain/Hook, 1–100 items, validated empty entries and atomic rollback on one failing item.

Gas and activation boundaries

Gas must be measured for the destination router, settlement and tick path. The helper’s separate on-chain call allowance is 200,000 gas; it is not a full-route gas guarantee.

Before enabling production routing, verify all supported addresses/managers, both directions, ordinary/keeper boundaries, RWA calendar boundaries, Mid-block reference transitions, clone/rollback behavior, exact rounding and partial-fill outcomes. Verify the destination router's actual calldata and settlement in an execution simulation. Exact-output, if offered, needs separate amount and settlement acceptance. Activating chain discovery, refresh schedules and public API routing is aggregator-side work, not an automatic result of accepting a document.

Peach's LP fee-claim policy affects the distribution of collected LP income; it is not an extra per-swap fee to add to these formulas. PoolManager protocol fees are another independent mechanism. The supported snapshots use zero protocol fee; this scope does not introduce protocol-fee compatibility logic. These are historical reference snapshots; nonzero PoolManager protocol fees require separate implementation and acceptance.

Executable fee example

This Python 3 snippet is self-contained and uses arbitrary-precision integers. Inputs must already be valid configurations. It computes the fee rate only; use the v4 AMM engine to calculate token amounts.

Historical Arc block: 27252638. Historical RPC reproduction requires an archive-capable node. A current eth_call or a snapshot first resolved from latest is a different test context.

Last updated

Was this helpful?