Powered by Kite Passport · x402 V2 · EIP-3009

Trade Polymarket from Claude.
Gasless. No JWT. One wallet.

A Claude Code skill that turns "buy me $5 of YES on this market" into a real on-chain Polymarket position — using your Kite wallet to sign, AnyEx to settle, and Polygon to hold. No accounts to create, no gas to manage, no API keys to leak.

$ curl -fsSL https://install.anyex.ai/polymarket | bash
macOS · Linux · Claude Code · Cursor · Codex · Cline · Claude Desktop (optional MCP)
What it looks like

One natural-language prompt → one real on-chain trade.

You don't construct payloads, sign EIP-712, or call any APIs. The skill orchestrates the whole flow: market search, endDate validation, one-time DepositWallet provisioning (with explicit consent), x402 payment, CLOB order placement, position verification.

You
Buy me $5 of Polymarket YES on "Will BTC close above $150k by end of 2026"
Claude
Found "Will Bitcoin reach $150,000 by Dec 31, 2026?" — endDate 2026-12-31, YES @ $0.18. Ready to spend $5 USDC → ~27.7 shares. Need to provision your DepositWallet first ($0.05 one-time). Approve?
You
approve
✓ Trade placed
MarketBTC ≥ $150k by EoY 26
OutcomeYES
Fill price$0.18
Size27.78 shares
Cost$5.00 USDC
Init fee$0.05 (one-time)
Safe0xf203…3ad0
Position live · `polymarket_positions` to check anytime
How it works

Three steps. Three minutes.

No app to install (except the CLI). No browser wallet to set up. Your Kite wallet IS your identity — the EIP-3009 signature is both the payment and the auth.

1

Install the skill

One curl | bash drops the skill into ~/.claude/skills/ and installs kpass (Kite Passport CLI) if needed. Claude / Cursor / Codex auto-discover.

2

Sign in + fund

kpass signup init creates your Kite wallet. Bridge ≥ $1 USDC.e to Kite mainnet (chain 2366). One-time setup.

3

Talk to Claude

"Buy me $5 on Polymarket YES for X." Claude routes through AnyEx's x402 shim, you sign with your Kite wallet, the shares end up in a Polymarket DepositWallet you fully custody.

Costs

Transparent fees. No subscription.

Pay only for what you trade. The one-time setup is the only fixed cost.

ActionFeeNotes
One-time DepositWallet setup ~$0.05 USDC Deploys your Polygon Safe + V2 token approvals. Idempotent.
Each BUY order amount + Polymarket fee The CLOB takes the per-market maker fee; AnyEx adds none on BUY.
Each SELL ~$0.01 USDC flat Polymarket sale proceeds accrue to your DepositWallet.
Each REDEEM (resolved markets) ~$0.01 USDC flat Winning shares pay out in USDC to your Polygon Safe.
FAQ

Questions you might be having.

Who custodies my Polymarket positions?

You do. AnyEx provisions a per-user Polymarket DepositWallet (a Gnosis Safe variant) on Polygon owned by a Polygon EOA derived from your Kite wallet. Signing for that Safe runs through Turnkey Delegated Access — AnyEx cannot move your funds.

Why x402 + EIP-3009 instead of a normal JWT/API key?

x402 is the emerging open standard for paid HTTP APIs. EIP-3009 lets you authorize a USDC transfer off-chain with a single ECDSA signature — that signature is both the payment and the identity proof. No server-side session state, no JWT to leak, replay-protected by the token contract's on-chain nonce.

Can I use this without Claude?

Yes — the AnyEx Polymarket endpoint is plain HTTP x402 V2. Use it from:

  • kpass agent:session execute --url …/x402/polymarket/buy
  • Any @x402/core client
  • Any HTTP client that can produce a Payment-Signature header (see the skill SKILL.md for raw HTTP examples)
What if Claude tries to buy the wrong market or an expired one?

The skill has two hard gates:

  • Market freshness: rejects any market whose endDate has already passed, even if Polymarket still shows acceptingOrders: true (those are usually waiting on oracle resolution and resolve to $0 for new buys).
  • Explicit consent card: before deploying your DepositWallet on first trade, Claude shows a card with the exact fee, your Polygon EOA, and what gets deployed. You must reply with an explicit "approve" — "yes I want to buy" doesn't qualify as consent for contract deployment.
How do I check my positions / sell / redeem?

From Claude: "What are my Polymarket positions?" / "Sell my YES on X." Under the hood the skill calls the same shim:

  • GET /anyex/v1/x402/polymarket/positions?safe=<your-safe> (public)
  • POST /anyex/v1/x402/polymarket/sell (paid x402, flat ~$0.01)
  • POST /anyex/v1/x402/polymarket/redeem (paid x402, flat ~$0.01)
What's the catch?

Polymarket has US geo-restrictions that the underlying CLOB enforces. AnyEx doesn't bypass those — if you're in a blocked region the order will be rejected at the Polymarket side. The on-chain wallet and the x402 flow work regardless of geography; only the order matching does. We surface the error if it happens.

HTTP 502 from a buy — what now?

Rare, but possible. Lambda has a 30 s invocation budget; a first-ever /buy for a brand-new user can race that when Polygon block production is slow. The order may still have placed. Do not blindly retry — x402 nonces are unique, a retry settles a second payment. First check:

  • curl "https://mcp.anyex.ai/anyex/v1/x402/polymarket/positions?safe=<your-safe>"

If your position is there, the buy succeeded. If empty, safe to retry. The /init step runs first to make this almost impossible.