New to Claude Skills? Learn how to install them →

civitai on GitHub

Stripe

Free

Manage Stripe customer billing and subscriptions efficiently.

by civitai7.2k stars on civitai/civitai
2 views
Updated Aug 10, 2026
Get this skill

Free · Opens the source repo

What Stripe does

The Stripe skill allows developers and support teams to interact with Stripe's API directly from their command line. This skill is particularly useful for investigating billing issues, handling subscription cancellations, and processing refunds. By leveraging this skill, users can perform a variety of operations such as looking up customer details, checking subscription statuses, and issuing refunds, all without needing to navigate through the Stripe dashboard manually.

To get started, users must set up their environment with the required STRIPE_SECRET_KEY, which can be obtained from the Stripe Dashboard. Once configured, the skill provides a series of commands that facilitate customer management. Users can look up customers by email, search for customers using Stripe's search syntax, and retrieve detailed information about subscriptions and payment methods. This direct access to customer data streamlines the support process, enabling quicker resolutions to customer inquiries.

The skill also includes powerful commands for managing subscriptions and refunds. Users can cancel subscriptions immediately or at the end of the billing period, ensuring that they can handle customer requests effectively. Additionally, refunding charges is straightforward, with options for full or partial refunds and the ability to specify reasons for refunds. The dry-run feature allows users to preview refundable charges before executing any transactions, minimizing the risk of errors.

Overall, the Stripe skill is designed for support teams and developers who need efficient access to customer billing information. It simplifies the management of subscriptions and payments, making it an essential tool for any organization that relies on Stripe for payment processing.

When to use it

Use this skill when investigating billing issues, processing refunds, or managing subscription cancellations for customers.

When not to use it

This skill may not be suitable for users unfamiliar with command-line interfaces or those who prefer a graphical user interface for managing billing.

What you can build with it

Investigating Billing Issues

Quickly look up customer billing history and subscription details to resolve support tickets.

Processing Customer Refunds

Easily issue refunds for charges based on customer requests or billing errors.

Managing Subscription Cancellations

Cancel subscriptions immediately or schedule cancellations for the end of the billing period as requested by users.

How to install Stripe

View source

1. Install with the skills CLI

npx skills add civitai/civitai/stripe --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by civitai

Stripe

Look up and manage Stripe customers, subscriptions, charges, and refunds for support investigations.

Setup

Required

  • STRIPE_SECRET_KEY — from Stripe Dashboard > Developers > API Keys (Secret key)

Quick Reference

SKILL_DIR=".claude/skills/stripe"

# Look up a customer by email (shows subscriptions, charges, invoices)
node "$SKILL_DIR/query.mjs" customer user@example.com

# Search customers using Stripe Search syntax
node "$SKILL_DIR/query.mjs" search "email:'user@example.com'"

# Get subscription details
node "$SKILL_DIR/query.mjs" subscription sub_1ABC123

# List charges for a customer
node "$SKILL_DIR/query.mjs" charges user@example.com

# List payment methods
node "$SKILL_DIR/query.mjs" payment-methods user@example.com

# Cancel a subscription IMMEDIATELY
node "$SKILL_DIR/query.mjs" cancel sub_1ABC123

# Cancel at end of billing period
node "$SKILL_DIR/query.mjs" cancel sub_1ABC123 --at-period-end

# Refund a specific charge (full)
node "$SKILL_DIR/query.mjs" refund ch_1ABC123

# Partial refund (amount in cents)
node "$SKILL_DIR/query.mjs" refund ch_1ABC123 --amount 500

# Refund with reason
node "$SKILL_DIR/query.mjs" refund ch_1ABC123 --reason requested_by_customer

# Preview all refundable charges (dry run)
node "$SKILL_DIR/query.mjs" refund-all user@example.com --dry-run

# Refund ALL charges for a customer
node "$SKILL_DIR/query.mjs" refund-all user@example.com --reason requested_by_customer

Commands

CommandDescription
customer <email>Full customer lookup — details, subscriptions, charges, invoices
search <query>Search customers using Stripe Search syntax
subscription <sub_xxx>Get detailed subscription info
charges <cus_xxx|email>List charges for a customer
payment-methods <cus_xxx|email>List saved payment methods
cancel <sub_xxx>Cancel subscription immediately
cancel <sub_xxx> --at-period-endCancel at end of current billing period
refund <ch_xxx>Full refund of a charge
refund <ch_xxx> --amount <cents>Partial refund
refund-all <cus_xxx|email>Refund all charges for a customer
refund-all <cus_xxx|email> --dry-runPreview refundable charges without refunding

Refund Reasons

Valid --reason values:

  • duplicate — Charge was a duplicate
  • fraudulent — Charge was fraudulent
  • requested_by_customer — Customer requested the refund

Global Flags

FlagDescription
--jsonOutput raw JSON (useful for piping/processing)

Safety Notes

  • Cancel terminates the subscription immediately by default. Use --at-period-end for graceful cancellation.
  • Refund-all with --dry-run first to preview. Without --dry-run, it refunds every non-refunded charge.
  • Refunds and cancellations are destructive and irreversible. Always confirm with the human operator before executing.
  • The customer command is read-only and safe to run at any time.

When to Use This Skill

  • Investigating billing/subscription issues reported in support tickets
  • Verifying payment history for disputed charges
  • Canceling subscriptions for users who request immediate termination
  • Processing refunds for confirmed billing errors
  • Cross-referencing Stripe data with Civitai's CustomerSubscription table

Frequently asked questions about Stripe

Similar skills