billing-automation
Manages recurring billing cycles, including trial periods, tax calculations, and dunning processes.
Install
mkdir -p .claude/skills/billing-automation && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/136" && unzip -o skill.zip -d .claude/skills/billing-automation && rm skill.zipInstalls to .claude/skills/billing-automation
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Build automated billing systems for recurring payments, invoicing, subscription lifecycle, and dunning management. Use when implementing subscription billing, automating invoicing, or managing recurring payment systems.Key capabilities
- →Process SaaS subscription billing cycles
- →Automate invoice generation and delivery
- →Manage dunning and failed payment recovery
- →Calculate prorated charges for plan changes
- →Handle VAT, GST, and sales tax
- →Support usage-based billing logic
How it works
Uses a Python BillingEngine class to orchestrate lifecycle events, applying state machine transitions from trial to active or canceled, and calculating prorated balances.
Inputs & outputs
When to use billing-automation
- →Implementing recurring subscription billing
- →Automating invoice generation
- →Managing SaaS dunning cycles
About this skill
Billing Automation
Master automated billing systems including recurring billing, invoice generation, dunning management, proration, and tax calculation.
When to Use This Skill
- Implementing SaaS subscription billing
- Automating invoice generation and delivery
- Managing failed payment recovery (dunning)
- Calculating prorated charges for plan changes
- Handling sales tax, VAT, and GST
- Processing usage-based billing
- Managing billing cycles and renewals
Core Concepts
1. Billing Cycles
Common Intervals:
- Monthly (most common for SaaS)
- Annual (discounted long-term)
- Quarterly
- Weekly
- Custom (usage-based, per-seat)
2. Subscription States
trial → active → past_due → canceled
→ paused → resumed
3. Dunning Management
Automated process to recover failed payments through:
- Retry schedules
- Customer notifications
- Grace periods
- Account restrictions
4. Proration
Adjusting charges when:
- Upgrading/downgrading mid-cycle
- Adding/removing seats
- Changing billing frequency
Quick Start
from billing import BillingEngine, Subscription
# Initialize billing engine
billing = BillingEngine()
# Create subscription
subscription = billing.create_subscription(
customer_id="cus_123",
plan_id="plan_pro_monthly",
billing_cycle_anchor=datetime.now(),
trial_days=14
)
# Process billing cycle
billing.process_billing_cycle(subscription.id)
Detailed patterns and worked examples
Detailed pattern documentation lives in references/details.md. Read that file when the navigation tier above is insufficient.
When not to use it
- →Processing one-time B2C retail transactions
- →Building inventory-based ecommerce systems
Prerequisites
Limitations
- →Requires mapping plan IDs manually
- →Not a substitute for a full payment processor (e.g., Stripe)
How it compares
Unlike a generic payment integration, this handles the full recurring lifecycle and complex state logic internally.
Compared to similar skills
billing-automation side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| billing-automation (this skill) | 10 | 2mo | No flags | Intermediate |
| plaid-fintech | 3 | 6mo | No flags | Advanced |
| kisautotrade-kis-api | 0 | 1mo | No flags | Intermediate |
| fastapi-templates | 520 | 2mo | No flags | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
More by wshobson
View all by wshobson →You might also like
plaid-fintech
davila7
Expert patterns for Plaid API integration including Link token flows, transactions sync, identity verification, Auth for ACH, balance checks, webhook handling, and fintech compliance best practices. Use when: plaid, bank account linking, bank connection, ach, account aggregation.
kisautotrade-kis-api
CountJung
Korea Investment Securities KIS Open API bridge for Codex in the repository-owned trading app. Use for authentication, TR-ID, REST/WebSocket endpoints, order, balance, execution, overseas stock, paper trading, API errors, and official sample verification.
fastapi-templates
wshobson
Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.
fastapi-pro
sickn33
Build high-performance async APIs with FastAPI, SQLAlchemy 2.0, and Pydantic V2. Master microservices, WebSockets, and modern Python async patterns. Use PROACTIVELY for FastAPI development, async optimization, or API architecture.
telegram-bot-builder
davila7
Expert in building Telegram bots that solve real problems - from simple automation to complex AI-powered bots. Covers bot architecture, the Telegram Bot API, user experience, monetization strategies, and scaling bots to thousands of users. Use when: telegram bot, bot api, telegram automation, chat bot telegram, tg bot.
stripe-integration
wshobson
Implement Stripe payment processing for robust, PCI-compliant payment flows including checkout, subscriptions, and webhooks. Use when integrating Stripe payments, building subscription systems, or implementing secure checkout flows.