web3-polymarket — Claude Code skill: Polymarket trading
A skill for Polymarket on Polygon: auth, order placement, market data, WebSocket streams and gasless transactions.
npx skills add Polymarket/agent-skills --skill web3-polymarket -a claude-codeWhat web3-polymarket does
The skill covers Polymarket integration end to end: deriving API credentials, placing and cancelling orders, reading the orderbook, fetching events and markets, and subscribing to WebSocket channels. It ships tables of base URLs, Polygon contract addresses, and code samples in TypeScript and Python for @polymarket/clob-client and py-clob-client.
Auth comes in two steps. L1 derives credentials from a private key. L2 initialises the trading client with those credentials, a signature type and the funder wallet address. Pick the signature type by wallet: 0 for a plain EOA, 1 for a Magic Link proxy, 2 for Gnosis Safe. An EOA needs POL for gas; the proxy options route through the relayer.
The skill needs network access to clob.polymarket.com, gamma-api.polymarket.com and a Polygon RPC. Run your agent behind a closed network and orderbook reads plus order submission fail right away. Order types are GTC, GTD, FOK and FAK. Post-only works with GTC and GTD only, and gets rejected when the price would cross the spread.
What it helps with
- derive L1 and L2 API credentials from a private key
- place a limit order and track its status
- read best bid, ask, midpoint and spread for a token
- subscribe to order updates over WebSocket
- split, merge and redeem CTF positions
Example prompts for the agent
- Show me how to derive Polymarket API credentials from a private key and init the trading client
- Place a GTC limit order for 10 dollars at 0.50 in this market
- Subscribe to the user WebSocket channel and print updates for my orders
How to install web3-polymarket
1Skills CLI (Vercel)
npx skills add Polymarket/agent-skills --skill web3-polymarket -a claude-code2Manually: put the files in place
~/.claude/skills/web3-polymarket/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/web3-polymarket/
1Skills CLI (Vercel)
npx skills add Polymarket/agent-skills --skill web3-polymarket -a codex2Manually: put the files in place
.agents/skills/web3-polymarket/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add Polymarket/agent-skills --skill web3-polymarket -a cursor2Manually: put the files in place
.cursor/skills/web3-polymarket/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install Polymarket/agent-skills web3-polymarket2Manually: put the files in place
.github/skills/web3-polymarket/SKILL.md1Skills CLI (Vercel)
npx skills add Polymarket/agent-skills --skill web3-polymarket -a gemini-cli2Platform CLI
gemini skills install https://github.com/Polymarket/agent-skillsManually: put the files in place
.devin/skills/web3-polymarket/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add Polymarket/agent-skills --skill web3-polymarket -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about web3-polymarket
How do I install web3-polymarket in Claude?
Run npx skills add Polymarket/agent-skills --skill web3-polymarket -a claude-code. The skill lands in ~/.claude/skills/web3-polymarket/SKILL.md.
What does web3-polymarket do?
It documents Polymarket integration on Polygon: authentication, order placement, market data, WebSocket subscriptions, CTF operations, the bridge and gasless relayer transactions.
What does the skill need to work?
Network access to clob.polymarket.com, gamma-api.polymarket.com and a Polygon RPC. With the EOA signature type you also need POL for gas.