skillfed

polar-billing

Polar Billing is a reference for Polar's complete billing infrastructure, covering core entities like checkouts, orders, subscriptions, and transactions alongside their relationships and data flows. It details Stripe integration, subscription lifecycle management including trials and cancellations, proration logic, and benefit grants. The skill maps key services, background task handling, dunning retry strategies, and transaction ledger mechanics to help developers navigate payment workflows end-to-end.

Polar Billing provides comprehensive documentation of billing entities, Stripe integration, subscription lifecycle, and benefit provisioning workflows.

AI-generated summary based on this skill's SKILL.md

820 70 Apache-2.0 updated by fcakyon

Install

fcakyon/claude-codex-settings/polar-billing · repository language: Python

git clone https://github.com/fcakyon/claude-codex-settings
cp -r claude-codex-settings/plugins/polar-skills/skills/polar-billing ~/.claude/skills/polar-billing
npx skillfed install fcakyon/claude-codex-settings/polar-billing

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

How does Polar billing work?

Polar Billing is a reference for Polar's complete billing infrastructure covering core entities like checkouts, orders, subscriptions, and transactions alongside their relationships and data flows. It details Stripe integration, subscription lifecycle management including trials and cancellations, proration logic, and benefit grants, mapping key services, background task handling, dunning retry strategies, and transaction ledger mechanics to help developers navigate payment workflows end-to-end.

What is the subscription lifecycle management process?

Polar Billing implements subscription lifecycle management including creation, renewal, and cancellation workflows. The system handles trial period setup, proration calculations during upgrades or downgrades, dunning and payment retry logic for failed payments, and automated benefit provisioning tied to subscription state transitions. Background tasks via Dramatiq orchestrate these workflows reliably.

How does Polar integrate Stripe payment processing?

Polar Billing integrates Stripe payment processing through checkout flows, webhook handling for payment events, and transaction ledger mechanics. The system processes payments, manages customer billing addresses and tax calculations, handles refunds and disputes, and coordinates with Stripe's payment retry infrastructure for dunning strategies on failed transactions.

How are benefit grants and revocation workflows configured?

Polar Billing configures benefit grants, revocation, and provisioning workflows tied to subscription state changes. Benefits are provisioned when subscriptions activate and revoked upon cancellation or expiration. The system tracks benefit entitlements through the transaction ledger and audit logs, ensuring consistent state across provisioning and revocation events.

What entities and relationships define Polar's billing system?

Polar Billing's core entities include checkouts, orders, subscriptions, and transactions with defined relationships and data flows. The system also covers meter credits and usage tracking, seat-based pricing implementation, payout mechanics, and customer billing address management. These entities interconnect through the transaction ledger and audit logs for complete billing visibility.

How do I debug billing issues like failed payments or missing benefits?

Polar Billing provides debugging support for billing issues including failed payments, proration errors, and missing benefits. The transaction ledger and billing entry audit log track all state changes and payment attempts. Developers can inspect webhook processing logs, dunning retry logic execution, and benefit provisioning workflows to identify root causes and resolve issues systematically.

SKILL.md

rendered from the published skill — quoted content, verbatim

Polar Billing System

Comprehensive guide to Polar's billing infrastructure, covering entities, flows, Stripe integration, and benefit provisioning.

Quick Reference

Checkout → Payment → Order → Transaction → Benefits
                         ↓
                   Subscription (if recurring)
                         ↓
                   Subscription Cycle → Order → ...

Table of Contents

  1. Core Entities
  2. Entity Relationships
  3. Main Services
  4. Dramatiq Background Tasks
  5. Stripe Integration
  6. Subscription Lifecycle
  7. Proration System
  8. Benefits & Credits
  9. Dunning & Payment Retry
  10. Transaction Ledger
  11. Key File Locations

1. Core Entities

(truncated - see the full file via the links below)

Read as markdown · JSON record · Browse the source repository

File tree — 1 file
plugins/polar-skills/skills/polar-billing/SKILL.md

Related skills

Tags

payment-processor recurring-billing checkout-session ledger-accounting benefit-provisioning proration-logic dunning-retry webhook-integration payout-settlement usage-metering