grimoire-polymarket
Original:🇺🇸 English
Translated
Queries Polymarket market data and CLOB state, and manages CLOB orders via the Grimoire venue CLI wrapper backed by the official Polymarket CLI.
26installs
Sourcefranalgaba/grimoire
Added on
NPX Install
npx skill4agent add franalgaba/grimoire grimoire-polymarketTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →Grimoire Polymarket Skill
Use this skill for Polymarket market discovery, CLOB market data, and order-management operations through the venue adapter.
polymarketPreferred invocations:
grimoire venue polymarket ...- (no-install)
npx -y @grimoirelabs/cli venue polymarket ... - (repo-local)
bun run packages/cli/src/index.ts venue polymarket ... - (direct binary from
grimoire-polymarket ...)@grimoirelabs/venues
Recommended preflight:
grimoire venue doctor --adapter polymarket --jsongrimoire venue polymarket info --format json
Commands
Canonical agent commands:
grimoire venue polymarket info [--format <auto|json|table>]grimoire venue polymarket search-markets [--query <text>] [--slug <slug|url>] [--question <text>] [--event <text>] [--tag <text>] [--category <text>] [--league <text>] [--sport <text>] [--open-only <true|false>] [--active-only <true|false>] [--ignore-end-date <true|false>] [--tradable-only <true|false>] [--all-pages <true|false>] [--max-pages <n>] [--stop-after-empty-pages <n>] [--limit <n>] [--format <auto|json|table>]
Allowed passthrough groups (official CLI surface, restricted by wrapper policy):
- (
markets)list|get|search|tags - (
events)list|get|tags - (
tags)list|get|related|related-tags - (
series)list|get - (
sports)list|market-types|teams - (book/prices/markets/orders/trades/etc.)
clob - (positions/value/leaderboards/etc.)
data status
Blocked groups in this wrapper (intentionally not exposed for agents):
walletbridgeapprovectfsetupupgradeshell
Legacy compatibility aliases are still supported (, , , , , , , , , , , , , , , ) but should not be used for new agent flows.
marketbookmidpointspreadpricelast-trade-pricetick-sizeneg-riskfee-rateprice-historyordertradesopen-ordersbalance-allowanceclosed-only-modeserver-timeExamples
bash
# Wrapper/health
grimoire venue polymarket info --format json
grimoire venue polymarket status --format json
# Canonical discovery
grimoire venue polymarket search-markets --query bitcoin --active-only true --open-only true --format json
grimoire venue polymarket search-markets --category sports --league "la liga" --active-only true --open-only true --format json
# Official passthrough discovery/data
grimoire venue polymarket markets list --limit 25 --format json
grimoire venue polymarket markets search "atleti" --limit 25 --format json
grimoire venue polymarket events list --limit 25 --format json
grimoire venue polymarket clob book <token_id> --format json
grimoire venue polymarket clob midpoint <token_id> --format json
grimoire venue polymarket clob price <token_id> --side buy --format json
# Authenticated order-management reads
grimoire venue polymarket clob order <order_id> --format json
grimoire venue polymarket clob trades --market <condition_id> --format json
grimoire venue polymarket clob orders --market <condition_id> --format json
grimoire venue polymarket clob balance --asset-type conditional --token <token_id> --format jsonRuntime Configuration
Adapter/runtime auth (for spell execution and authenticated CLOB operations):
- required:
POLYMARKET_PRIVATE_KEY - optional API creds: ,
POLYMARKET_API_KEY,POLYMARKET_API_SECRETPOLYMARKET_API_PASSPHRASE - optional derive toggle (default true):
POLYMARKET_DERIVE_API_KEY=true|false - optional signature routing: (
POLYMARKET_SIGNATURE_TYPEEOA,0POLY_PROXY,1GNOSIS_SAFE),2POLYMARKET_FUNDER
Venue CLI backend:
- Official binary required:
polymarket - Install:
brew tap Polymarket/polymarket-cli && brew install polymarket - Optional path override:
POLYMARKET_OFFICIAL_CLI=/custom/path/polymarket
Adapter Notes
- Adapter name:
polymarket - Execution type:
offchain - Supported chain metadata: (Polygon)
137 - Action type:
custom - Supported custom ops: ,
order,cancel_order,cancel_orders,cancel_allheartbeat
Order argument aliases accepted:
- token: or
token_idortokenIDortokenIdcoin - amount: or
sizeamount - side: /
BUYSELL - order type: /
GTC/GTD/FOKFAK - extra compatibility aliases: ,
arg0..arg5reduce_only
Order type routing:
- /
GTC-> limit order path (GTD)createAndPostOrder - /
FOK-> market order path (FAK)createAndPostMarketOrder
Notes
- Prefer for agent and automation workflows.
--format json - is the agent-oriented normalized discovery command; passthrough
search-marketsis thinner and closer to official behavior.markets search - Keep prompts/tooling on this CLI surface; do not call Polymarket HTTP APIs directly from advisory tools.