agentleFS
alanalvestechalanalvestech/hitank/skills/stripe/SKILL.md

stripe

Skill38 starsChanged 8 months agoMITView on GitHub

Manage Stripe payments, customers, subscriptions, invoices and products via REST API

20 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 17 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If the output is OK, proceed to the Flow section.

    line 43
  2. Very specific:

    If the output is SETUP_NEEDED, guide the user step by step.

    line 45
  3. Distinctive:

    If the script outputs an error, the key is invalid.

    line 62

“Common” is measured: kept by at least 6 in 10 of the 17 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

/stripe

Connect to Stripe to manage payments, customers, subscriptions, invoices and products. Pure Ruby, zero gems — stdlib only.

Structure

scripts/
├── auth.rb              # Bearer token auth + stripe_request helper (required by all scripts)
├── check_setup.rb       # Check if token exists (outputs OK or SETUP_NEEDED)
├── save_token.rb        # Save and validate an API key
├── customers.rb         # List customers
├── customer.rb          # Get customer details
├── create_customer.rb   # Create a customer
├── charges.rb           # List charges
├── payments.rb          # List payment intents
├── create_payment.rb    # Create a payment intent
├── subscriptions.rb     # List subscriptions
├── subscription.rb      # Get subscription details
├── create_subscription.rb # Create a subscription
├── invoices.rb          # List invoices
├── invoice.rb           # Get invoice details
├── products.rb          # List products
├── create_product.rb    # Create a product
├── prices.rb            # List prices
├── create_price.rb      # Create a price
└── balance.rb           # Get account balance

Setup (check before using)

ruby ~/.claude/skills/stripe/scripts/check_setup.rb

If the output is OK, proceed to the Flow section.

If the output is SETUP_NEEDED, guide the user step by step. Present ONE step at a time, wait for the user to confirm before moving to the next.

Step 1 — Ask the user to get their API key:

You need a Stripe API key.

  1. Go to https://dashboard.stripe.com/apikeys
  2. Copy your Secret key (starts with sk_test_ or sk_live_)

Paste the API key here.

Step 2 — When the user pastes the key, save it:

ruby ~/.claude/skills/stripe/scripts/save_token.rb 'PASTED_KEY'

If the script outputs an error, the key is invalid. Ask the user to double-check and try again.

If setup is not complete, DO NOT proceed to the Flow. Complete all steps first.

Flow

The argument $ARGUMENTS may contain an action or customer email.

Step 1: Check balance

ruby ~/.claude/skills/stripe/scripts/balance.rb

Present the balance and ask what the user wants to do.

Step 2: Actions

List customers:

ruby ~/.claude/skills/stripe/scripts/customers.rb
ruby ~/.claude/skills/stripe/scripts/customers.rb --limit 5 --email user@example.com

Get customer details:

ruby ~/.claude/skills/stripe/scripts/customer.rb CUSTOMER_ID

Create a customer (requires user confirmation):

ruby ~/.claude/skills/stripe/scripts/create_customer.rb "user@example.com" --name "John Doe" --phone "+1234567890"

List charges:

ruby ~/.claude/skills/stripe/scripts/charges.rb
ruby ~/.claude/skills/stripe/scripts/charges.rb --limit 10 --customer CUSTOMER_ID

List payment intents:

ruby ~/.claude/skills/stripe/scripts/payments.rb
ruby ~/.claude/skills/stripe/scripts/payments.rb --limit 10 --customer CUSTOMER_ID

Create a payment intent (requires user confirmation):

ruby ~/.claude/skills/stripe/scripts/create_payment.rb 2000 usd --customer CUSTOMER_ID --description "Order #123"

List subscriptions:

ruby ~/.claude/skills/stripe/scripts/subscriptions.rb
ruby ~/.claude/skills/stripe/scripts/subscriptions.rb --limit 10 --customer CUSTOMER_ID --status active

Get subscription details:

ruby ~/.claude/skills/stripe/scripts/subscription.rb SUBSCRIPTION_ID

Create a subscription (requires user confirmation):

ruby ~/.claude/skills/stripe/scripts/create_subscription.rb CUSTOMER_ID PRICE_ID

List invoices:

ruby ~/.claude/skills/stripe/scripts/invoices.rb
ruby ~/.claude/skills/stripe/scripts/invoices.rb --limit 10 --customer CUSTOMER_ID --status paid

Get invoice details:

ruby ~/.claude/skills/stripe/scripts/invoice.rb INVOICE_ID

List products:

ruby ~/.claude/skills/stripe/scripts/products.rb
ruby ~/.claude/skills/stripe/scripts/products.rb --limit 10 --active true

Create a product (requires user confirmation):

ruby ~/.claude/skills/stripe/scripts/create_product.rb "Premium Plan" --description "Full access to all features"

List prices:

ruby ~/.claude/skills/stripe/scripts/prices.rb
ruby ~/.claude/skills/stripe/scripts/prices.rb --limit 10 --product PRODUCT_ID

Create a price (requires user confirmation):

ruby ~/.claude/skills/stripe/scripts/create_price.rb PRODUCT_ID 2000 usd
ruby ~/.claude/skills/stripe/scripts/create_price.rb PRODUCT_ID 2000 usd --interval month

Get account balance:

ruby ~/.claude/skills/stripe/scripts/balance.rb

Notes

  • Pure Ruby, zero gems — stdlib only (json, net/http, uri, fileutils)
  • Auth via Bearer token (API key starting with sk_test_ or sk_live_)
  • Token file: ~/.config/stripe/token (outside the repo, never commit)
  • Base URL: https://api.stripe.com/v1
  • POST/PUT bodies are sent as application/x-www-form-urlencoded (not JSON)
  • Amounts are in the smallest currency unit (e.g., cents for USD: 2000 = $20.00)
  • Creating customers, payments, subscriptions, products, and prices requires explicit user confirmation

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.