stripe-integration-expert
Production-grade Stripe integrations: subscriptions with trials and proration, one-time payments, usage-based billing, checkout sessions, idempotent webhook…
Skill by mouadja02
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/mouadja02-stripe-integration-expert
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: frontend, backend, finance
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 2
codeload.github.com· found in install commandgithub.com· found in code
Files it touches
~/.claude/skills/stripe-integration-expert
What's inside
- Skill name
stripe-integration-expert- Description
- Production-grade Stripe integrations: subscriptions with trials and proration, one-time payments, usage-based billing, checkout sessions, idempotent webhook handlers, customer portal, and invoicing. Covers Next.js, Express, and Django patterns. Use when integrating Stripe for the first time, debugging webhook reliability issues, migrating from a different payment provider, or adding usage-based billing to an existing subscription product.
- License
- MIT
- Instructions
- 475 lines in SKILL.md · view on GitHub
Files (3)
- LICENSE
- SKILL.md
- _meta.json
SKILL.md (first lines)
> **Attribution:** Sourced from [alirezarezvani/claude-skills](https://github.com/alirezarezvani/claude-skills) by [Alireza Rezvani](https://github.com/alirezarezvani), licensed MIT. Modified for this collection.
# Stripe Integration Expert
**Tier:** POWERFUL
**Category:** Engineering Team
**Domain:** Payments / Billing Infrastructure
---
## Overview
Implement production-grade Stripe integrations: subscriptions with trials and proration, one-time payments, usage-based billing, checkout sessions, idempotent webhook handlers, customer portal, and invoicing. Covers Next.js, Express, and Django patterns.
---
## Core Capabilities
- Subscription lifecycle management (create, upgrade, downgrade, cancel, pause)
- Trial handling and conversion tracking
- Proration calculation and credit application
- Usage-based billing with metered pricing
- Idempotent webhook handlers with signature verification
- Customer portal integration
- Invoice generation and PDF access
- Full Stripe CLI local testing setup
---
## When to Use
- Adding subscription billing to any web app
- Implementing plan upgrades/downgrades with proration
- Building usage-based or seat-based billing
- Debugging webhook delivery failures
- Migrating from one billing model to another
---
## Subscription Lifecycle State Machine
```
FREE_TRIAL ──paid──► ACTIVE ──cancel──► CANCEL_PENDING ──period_end──► CANCELED
│ │ │
│ downgrade reactivate
│ ▼ │
│ DOWNGRADING ──period_end──► ACTIVE (lower plan) │
│ │
└──trial_end without payment──► PAST_DUE ──payment_failed 3x──► CANCELED
│
payment_success
│
▼
ACTIVE
```
### DB subscription status values:
`trialing | active | past_due | canceled | cancel_pending | paused | unpaid`
---
## Stripe Client Setup
```typescript
// lib/stripe.ts
import Stripe from "stripe"
export const stripe = new Stripe(process.env.STRIPE_SECRET_KEY!, {
apiVersion: "2024-04-10",
typescript: true,
appInfo: {
name: "myapp",
version: "1.0.0",
},
})
// Price IDs by plan (set in env)
export const PLANS = {
starter: {
monthly: process.env.STRIPE_STARTER_MONTHLY_PRICE_ID!,
yearly: process.env.STRIPE_STARTER_YEARLY_PRICE_ID!,
features: ["5 projects", "10k events"],
},
pro: {
monthly: process.env.STRIPE_PRO_MONTHLY_PRICE_ID!,
yearly: process.env.STRIPE_PRO_YEARLY_PRICE_ID!,
features: ["Unlimited projects", "1M events"],
},
} as const
```
---
## Checkout Session (Next.js App Router)
```typescript
// app/api/billing/checkout/route.ts
import { NextResponse } from "next/server"
import { stripe } from "@/lib/stripe"
import { getAuthUser } from "@/lib/auth"
import { db } from "@/lib/db"
export async function POST(req: Request) {
const user = await getAuthUser()
if (!user) return NextResponse.json({ error: "Unauthorized" }, { status: 401 })
const { priceId, interval = "monthly" } = await req.json()
// Get or create Stripe customer
let stripeCustomerId = user.stripeCustomerId
if (!stripeCustomerId) {
const customer = await stripe.customers.create({
email: user.email,
name: "username-undefined"
metadata: { userId: user.id },
})
stripeCustomerId = customer.id
await db.user.update({ where: { id: user.id }, data: { stripeCustomerId } })
}From mouadja02/skills, MIT.
More from mouadja02/skills
- 0.637score
gdpr-compliant
mouadja02
Apply GDPR-compliant engineering practices across your codebase.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
semantic-kernel
mouadja02
Create, update, refactor, explain, or review Semantic Kernel solutions using shared guidance plus language-specific references for .NET and Python.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
python-pypi-package-builder
mouadja02
End-to-end skill for building, testing, linting, versioning, and publishing a production-grade Python library to PyPI.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
ai-team-orchestration
mouadja02
Bootstraps and runs a multi-agent development team with roles (dev, QA, DevOps), parallel work, and sprint plans that survive context resets.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
eval-driven-dev
mouadja02
Improve AI application with evaluation-driven development.
SkillAFreshness: A★ 11Claude Code +9 - 0.634score
nano-banana-pro-openrouter
mouadja02
Generate or edit images via OpenRouter with the Gemini 3 Pro Image model.
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
autoresearch
luiscantero
Runs an autonomous experiment loop on any programming task: you define the goal, metric, and eval command; the agent edits code, measures, and keeps or…
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
structured-autonomy-plan
mouadja02
Use when an autonomous agent run needs a plan before execution — decomposing the goal, setting explicit boundaries and stop conditions, and defining what the…
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
memory-merger
mouadja02
Merges mature lessons from a domain memory file into its instruction file.
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
create-agentsmd
mouadja02
Generates a complete AGENTS.md at the repository root following the agents.md format: setup, build, test, style, and PR conventions coding agents need.
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
rich-claude-code-tui-clone
mouadja02
Use when building a Python terminal UI inspired by Claude Code with Rich.
SkillAFreshness: A★ 11Claude Code +9 - 0.632score
bmm-skills
mouadja02
Routes requests to the BMad Method (v6.12.4) agile framework: persona agents, planning skills (brief, PRFAQ, PRD, UX, spec, architecture, epics, sprint…
SkillAFreshness: A★ 11Claude Code +9
Compare and alternatives
Featured in
Signals
- Stars
- 11
- Forks
- 5
- Open issues
- 25
- Last commit (this folder)
- Oct 16, 2026 (11 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/mouadja02/skills
- Website
- mouadja02.github.io/skills/
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from mouadja02
- 0.637score
python-pypi-package-builder
mouadja02
End-to-end skill for building, testing, linting, versioning, and publishing a production-grade Python library to PyPI.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
gdpr-compliant
mouadja02
Apply GDPR-compliant engineering practices across your codebase.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
eval-driven-dev
mouadja02
Improve AI application with evaluation-driven development.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
semantic-kernel
mouadja02
Create, update, refactor, explain, or review Semantic Kernel solutions using shared guidance plus language-specific references for .NET and Python.
SkillAFreshness: A★ 11Claude Code +9 - 0.637score
ai-team-orchestration
mouadja02
Bootstraps and runs a multi-agent development team with roles (dev, QA, DevOps), parallel work, and sprint plans that survive context resets.
SkillAFreshness: A★ 11Claude Code +9 - 0.634score
nano-banana-pro-openrouter
mouadja02
Generate or edit images via OpenRouter with the Gemini 3 Pro Image model.
SkillAFreshness: A★ 11Claude Code +9
Cite this page
stripe-integration-expert skill. Agent Mart. https://agentmart.dev/skills/mouadja02-stripe-integration-expert (last updated 2026-10-24)