Polar — Monetization for Developers

You are an expert in Polar, the monetization platform built for developers and open-source maintainers. You help developers add payments, subscriptions, product sales, license keys, and sponsorships to their projects with a developer-first API, webhooks, and embeddable components — replacing Stripe integration complexity with purpose-built tools for software monetization.

25 stars

Best use case

Polar — Monetization for Developers is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

You are an expert in Polar, the monetization platform built for developers and open-source maintainers. You help developers add payments, subscriptions, product sales, license keys, and sponsorships to their projects with a developer-first API, webhooks, and embeddable components — replacing Stripe integration complexity with purpose-built tools for software monetization.

Teams using Polar — Monetization for Developers should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/polar/SKILL.md --create-dirs "https://raw.githubusercontent.com/ComeOnOliver/skillshub/main/skills/TerminalSkills/skills/polar/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/polar/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How Polar — Monetization for Developers Compares

Feature / AgentPolar — Monetization for DevelopersStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

You are an expert in Polar, the monetization platform built for developers and open-source maintainers. You help developers add payments, subscriptions, product sales, license keys, and sponsorships to their projects with a developer-first API, webhooks, and embeddable components — replacing Stripe integration complexity with purpose-built tools for software monetization.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Polar — Monetization for Developers

You are an expert in Polar, the monetization platform built for developers and open-source maintainers. You help developers add payments, subscriptions, product sales, license keys, and sponsorships to their projects with a developer-first API, webhooks, and embeddable components — replacing Stripe integration complexity with purpose-built tools for software monetization.

## Core Capabilities

### Products and Checkout

```typescript
import { Polar } from "@polar-sh/sdk";

const polar = new Polar({ accessToken: process.env.POLAR_ACCESS_TOKEN });

// Create a product
const product = await polar.products.create({
  name: "Pro Plan",
  description: "Full access to all features",
  prices: [{
    type: "recurring",
    recurringInterval: "month",
    priceAmount: 2900,                    // $29.00
    priceCurrency: "usd",
  }],
  benefits: [
    { type: "license_keys", description: "License key for desktop app" },
    { type: "discord", description: "Access to Pro Discord channel" },
    { type: "custom", description: "Priority support" },
  ],
});

// Create checkout session
const checkout = await polar.checkouts.create({
  productId: product.id,
  successUrl: "https://myapp.com/success?session={CHECKOUT_ID}",
  customerEmail: "user@example.com",
  metadata: { userId: "usr-42" },
});
// Redirect user to checkout.url

// Verify checkout
const session = await polar.checkouts.get(checkoutId);
if (session.status === "confirmed") {
  await activateUserPro(session.metadata.userId);
}
```

### Webhooks

```typescript
// Handle Polar webhooks
import { validateEvent } from "@polar-sh/sdk/webhooks";

app.post("/api/webhooks/polar", async (req, res) => {
  const event = validateEvent(req.body, req.headers, process.env.POLAR_WEBHOOK_SECRET!);

  switch (event.type) {
    case "subscription.created":
      await db.users.update(event.data.customer.metadata.userId, { plan: "pro", polarSubId: event.data.id });
      break;
    case "subscription.canceled":
      await db.users.update(event.data.customer.metadata.userId, { plan: "free", cancelAt: event.data.currentPeriodEnd });
      break;
    case "order.created":
      await fulfillOrder(event.data);
      break;
  }

  res.json({ received: true });
});
```

### License Keys

```typescript
// Validate license key (in your desktop/CLI app)
const validation = await polar.licenseKeys.validate({
  key: userProvidedKey,
  organizationId: process.env.POLAR_ORG_ID!,
});

if (validation.valid) {
  console.log(`License valid for: ${validation.customer.email}`);
  console.log(`Activations: ${validation.activations}/${validation.limit}`);
  // Activate features
} else {
  console.log(`Invalid: ${validation.error}`);
}

// Activate (track device)
await polar.licenseKeys.activate({
  key: userProvidedKey,
  label: `${os.hostname()}-${os.platform()}`,
  organizationId: process.env.POLAR_ORG_ID!,
});
```

### Embeddable Components

```tsx
// React component for checkout button
import { PolarCheckout } from "@polar-sh/react";

function PricingPage() {
  return (
    <div className="pricing-grid">
      <div className="plan">
        <h3>Pro</h3>
        <p className="price">$29/mo</p>
        <PolarCheckout
          productId="prod_abc123"
          successUrl="/success"
          className="buy-button"
        >
          Get Pro
        </PolarCheckout>
      </div>
    </div>
  );
}
```

## Installation

```bash
npm install @polar-sh/sdk
npm install @polar-sh/react                # React components
```

## Best Practices

1. **Benefits system** — Attach benefits (license keys, Discord access, downloads) to products; Polar auto-provisions
2. **Webhooks for fulfillment** — Use webhooks for subscription lifecycle; don't rely solely on checkout redirect
3. **License keys** — Use for desktop apps, CLI tools, self-hosted software; activation limits prevent sharing
4. **Metadata** — Pass `userId` in checkout metadata; link Polar customers to your user system
5. **Customer portal** — Polar provides a hosted portal for subscription management; no custom billing UI needed
6. **Open-source funding** — Use Polar for issue funding and sponsorships; backers fund specific features
7. **Usage-based** — Create metered products for API access; track usage and bill accordingly
8. **Multi-currency** — Support USD, EUR, GBP; Polar handles currency conversion and tax calculation

Related Skills

readme-for-developers

25
from ComeOnOliver/skillshub

Write developer-oriented README as onboarding documentation. Use when creating/updating README, setting up new projects, or when new developers need to understand the codebase quickly. README = Entry point + Architecture overview + Working agreement.

Resend — Modern Email API for Developers

25
from ComeOnOliver/skillshub

You are an expert in Resend, the developer-first email API. You help developers send transactional and marketing emails using React Email templates, TypeScript SDK, webhooks for delivery tracking, batch sending, and audience management — replacing legacy email services (SendGrid, Mailgun) with a modern, type-safe developer experience.

Polars

25
from ComeOnOliver/skillshub

## Overview

polars-bio

25
from ComeOnOliver/skillshub

## Overview

monetization-strategy

25
from ComeOnOliver/skillshub

When the user wants to design or optimize their app's monetization — pricing, paywalls, subscriptions, or in-app purchases. Also use when the user mentions "pricing", "paywall", "subscription", "IAP", "how to monetize", "revenue optimization", "free trial", or "conversion to paid". For retention impact, see retention-optimization. For competitive pricing, see competitor-analysis.

Daily Logs

25
from ComeOnOliver/skillshub

Record the user's daily activities, progress, decisions, and learnings in a structured, chronological format.

Socratic Method: The Dialectic Engine

25
from ComeOnOliver/skillshub

This skill transforms Claude into a Socratic agent — a cognitive partner who guides

Sokratische Methode: Die Dialektik-Maschine

25
from ComeOnOliver/skillshub

Dieser Skill verwandelt Claude in einen sokratischen Agenten — einen kognitiven Partner, der Nutzende durch systematisches Fragen zur Wissensentdeckung führt, anstatt direkt zu instruieren.

College Football Data (CFB)

25
from ComeOnOliver/skillshub

Before writing queries, consult `references/api-reference.md` for endpoints, conference IDs, team IDs, and data shapes.

College Basketball Data (CBB)

25
from ComeOnOliver/skillshub

Before writing queries, consult `references/api-reference.md` for endpoints, conference IDs, team IDs, and data shapes.

Betting Analysis

25
from ComeOnOliver/skillshub

Before writing queries, consult `references/api-reference.md` for odds formats, command parameters, and key concepts.

Research Proposal Generator

25
from ComeOnOliver/skillshub

Generate high-quality academic research proposals for PhD applications following Nature Reviews-style academic writing conventions.