Polar Agent Toolkit

Polar's plugin for AI coding agents. It connects your agent to Polar, the open-source payment infrastructure platform, so it can set up products, checkouts, customer portals and webhooks in your app, test them against the Polar sandbox, and help you migrate from another payment provider.
The skills follow the Agent Skills format, so they also work in agents that don't support plugins.
What's included
MCP servers
| Server | URL | Use it for |
|---|
polar | https://mcp.polar.sh/mcp/polar-mcp | Your live Polar organization |
polar-sandbox | https://mcp.polar.sh/mcp/polar-sandbox | Test data on sandbox.polar.sh |
Both servers use OAuth. Nothing connects until you sign in to Polar and authorize an organization.
Skills
| Skill | What it does |
|---|
setup-polar | Guided setup from scratch: connects the MCP server, creates an organization and a first product, then hands off to polar-integration. |
polar-integration | Adds Checkout, Customer Portal and Webhooks endpoints with @polar-sh/sdk to any TS/JS framework, including Next.js, Express, Hono, Astro, SvelteKit, Remix, Nuxt and Cloudflare Workers. |
polar-config | Manages the catalog as code: writes and edits a billing config file in TypeScript or JSON, and validates, drafts and publishes it with the Polar CLI (polar config validate, polar config draft, polar config publish). |
polar-config-ci | Sets up CI for a billing config: comments the changes on each pull request and drafts or publishes them on merge, in GitHub Actions or Buildkite. |
polar-testing | Tests an integration against the sandbox: test cards, local webhooks with the Polar CLI (polar webhook listen, polar webhook trigger), mocks and CI. |
polar-migration | Guides a migration to Polar: Polar's assisted migration from Stripe Billing or Lemon Squeezy, or recreating the catalog and moving customers from Paddle and others. |
Installation
The quickest way is the Polar CLI. It detects Claude Code, Codex and Cursor and sets each one up with the Polar plugin, MCP server and skills:
npm install -g @polar-sh/cli
polar agent setup
polar agent setup --status shows what is set up, and polar agent setup --skills project installs the skills into .agents/skills for any other agent. To install by hand instead, follow the section for your agent.
Claude Code
/plugin install polar --marketplace polarsource/agent-toolkit
Then run /mcp, select polar or polar-sandbox and sign in to Polar in your browser. Skills are available as /polar:setup-polar, /polar:polar-integration and so on, and Claude also uses them on its own when a task matches.
ChatGPT and Codex
Polar is in OpenAI's plugin directory, which ChatGPT and Codex share.
- Codex CLI: run
/plugins, search for Polar and install it, then start a new session.
- ChatGPT and the Codex app: open the Plugins tab, search for Polar and install it.
Sign in to Polar when prompted, either during install or the first time you use the plugin. Codex uses the skills on its own when a task matches.
The plugin connects to your live organization. To test against the sandbox, add the polar-sandbox server by following the Polar MCP guide.
Cursor
In Cursor, open Customize, choose From GitHub Repository and enter https://github.com/polarsource/agent-toolkit. Then sign in to polar or polar-sandbox from Cursor's MCP settings.
Gemini CLI
gemini extensions install https://github.com/polarsource/agent-toolkit
Then sign in to Polar with /mcp auth polar or /mcp auth polar-sandbox.
Antigravity
agy plugin install https://github.com/polarsource/agent-toolkit
Then sign in to polar or polar-sandbox from Antigravity's MCP settings.
Other agents
Install the skills with skills:
npx skills add https://github.com/polarsource/agent-toolkit
Then connect the MCP server by following the Polar MCP guide for your client.
Example prompts