Skip to main content
Preview. On-chain intents run on staging (https://staging-execution.kairos.trade). Production answers 503 until release. Fields and behavior may still change.
An on-chain intent runs one operation on the wallet’s Polymarket trading wallet: Kairos builds the exact calls, the wallet signs twice, and the batch runs with no gas for the wallet. Kairos marks the intent done only once it has checked the final on-chain result itself. Supported: binary Polymarket markets on Polygon, for a wallet set up on Polymarket. Redeem works on markets on Polymarket’s newer exchange (markets whose orders sign with exchange version 3). Other markets answer 400.

With the SDK

Each call prepares the intent, asks the wallet for its two signatures, executes it, and waits until it’s confirmed. To find what you can redeem, read positions: resolved rows with redeemable: true.

Over HTTP

1. Prepare

All field names are camelCase. Unknown fields are refused.

2. Check and sign

The response holds the intent and two signing requests:
  • terms.effects is the exact set of token movements the batch makes on the trading wallet. Show them to the user, and refuse to sign if they’re not what you asked for.
  • consentRequest is the wallet’s consent to these terms: domain KairosOnchainIntent v1 on chain 137, primaryType: "OnchainIntent", message { signer, partnerId, audience, intentId, intentHash, executeBefore }.
  • nativeRequest is the trading wallet’s own Batch (domain DepositWallet v1, chain 137, verifyingContract = the trading wallet). It holds two calls: one approval, then the operation.
  • Both must be signed by the wallet’s own key: 65 bytes, low s, no smart-account signatures. The wallet must be on Polygon (0x89). The documents carry chainId as the string "137".
The approval in the batch lets Polymarket’s split, merge and redeem contract act on the trading wallet: a pUSD allowance of exactly amountRaw for a split, or a standing setApprovalForAll on the outcome tokens for merge and redeem.

3. Execute

Execute checks both signatures, then the trading wallet’s balance at the latest final block. It reserves the debited tokens and commits. Kairos then submits the batch once. With submissionOwner: "client", send only consentSignature; sending nativeSignature too answers 400. The response is the same shape as prepare. Executing again with the same signatures returns the intent unchanged.

4. Follow it

GET /v3/onchain-intents/{id} every few seconds until status is confirmed. The response then carries proof: the transaction hash, block, and the effects found on chain.
Never broadcast the batch from the wallet itself. The batch must be submitted gaslessly as given. A copy sent from the owner’s address never confirms, and the intent’s reserved balance stays reserved.

Submitting it yourself

With submissionOwner: "client", the prepare response’s submission describes the request to make: endpoint, method and a body without a signature. Add "signature": "<native signature>" to body and send it. Then, optionally, report the transaction hash:
A report is only a hint. Kairos finds and checks the transaction itself, with or without it. Unless you already run your own Polymarket relayer integration, use submissionOwner: "kairos".

Chaining intents

To merge shares a split is about to create, prepare the split, then prepare the merge with "dependencies": ["<split id>"]. Execute the merge only after the split is confirmed: until then, execute answers 409.

Errors

Errors are { "error": "message" }.