Automated summary
This skill processes payments via Stripe, PayPal, or ACH, including scheduling, execution, confirmation, and full audit trail.
Strengths
- Supports multiple payment gateways (Stripe, PayPal, ACH).
- Handles payment scheduling and webhook processing.
- Includes strong validation and audit logging.
Limitations
- Requires API keys and per-tenant gateway configuration.
- Error handling can be complex (failures, refunds).
- Depends on external services (Stripe, PayPal).
Use this skill to automate payment processing for invoices or customer payments.
Do not use for simple manual payments or if using an unsupported payment gateway.
Security analysis
CautionThe skill processes live payments and updates databases, which carries inherent financial risk. It follows security best practices (idempotency, PCI compliance, RBAC, parameterized queries), but the operational power of the actions (charging cards, transferring funds) warrants caution to prevent misuse or accidental execution.
- •Instructs execution of real financial transactions (Stripe, PayPal, ACH) with monetary impact
- •SQL update and insert operations that modify database state
- •Uses environment variables for API secrets; exposure risk if the skill runtime is compromised
Examples
Pay invoice INV-2025-001 for $500.00 using Stripe, with approval from user admin@example.com.Schedule payment for invoice INV-2025-002 via ACH on March 1, 2025. Approved by user jdoe.Refund payment pi_1234abc for invoice INV-2025-003. The original payment was made via PayPal.name: payment-gateway description: "Process payments via Stripe, PayPal, or ACH. Use when paying invoices, processing customer payments, or managing payment methods. Handles payment scheduling, execution, and confirmation with full audit trail."
Payment Gateway Skill
Purpose
Processes payments securely through integrated payment gateways (Stripe, PayPal, ACH), with proper authorization, audit logging, and error handling.
Triggers
- Invoice approved and ready for payment
- Customer payment submitted
- Scheduled payment due date reached
- Manual payment initiated
Capabilities
- Payment Processing - Execute payments via Stripe/PayPal/ACH
- Payment Scheduling - Schedule future payments
- Payment Confirmation - Verify payment succeeded
- Refund Processing - Handle refunds and reversals
- Payment Method Management - Store and manage payment methods
- Webhook Handling - Process payment status webhooks
Instructions
Step 1: Validate Payment Request
Required fields:
- tenant_id - For multi-tenant isolation
- invoice_id or amount - What to pay
- payment_method - stripe, paypal, ach
- approved_by - User ID who approved payment
- scheduled_date - When to execute (can be immediate)
Validations:
- Invoice status is 'approved'
- Amount matches invoice amount
- Payment method is configured for tenant
- User has permission to approve payments
- Sufficient funds (if applicable)
Step 2: Execute Payment
Stripe Payment
const stripe = new Stripe(process.env.STRIPE_SECRET_KEY);
const payment_intent = await stripe.paymentIntents.create({
amount: invoice.amount, // cents
currency: invoice.currency,
description: `Invoice ${invoice.invoice_number} - ${invoice.vendor_name}`,
metadata: {
tenant_id: invoice.tenant_id,
invoice_id: invoice.id,
},
});
// Confirm payment
const confirmed = await stripe.paymentIntents.confirm(payment_intent.id, {
payment_method: tenant_payment_method_id,
});
ACH Payment
// Via Stripe or Plaid
const transfer = await stripe.transfers.create({
amount: invoice.amount,
currency: invoice.currency,
destination: vendor_stripe_account_id,
});
PayPal Payment
// Via PayPal SDK
const payment = await paypal.createPayment({
amount: cents_to_dollars(invoice.amount),
currency: invoice.currency,
recipient: vendor_paypal_email,
});
Step 3: Update Invoice Status
On success:
UPDATE invoices
SET status = 'paid',
paid_at = NOW(),
updated_at = NOW()
WHERE id = $1 AND tenant_id = $2;
On failure:
- Log error to agent_runs table
- Create alert for manual review
- Do NOT mark as paid
Step 4: Audit Log
INSERT INTO audit_log (tenant_id, user_id, action, entity_type, entity_id, changes)
VALUES (
$1, -- tenant_id
$2, -- user_id (approved_by)
'approve', -- action
'invoices', -- entity_type
$3, -- invoice_id
jsonb_build_object(
'payment_method', 'stripe',
'payment_intent_id', payment_intent.id,
'amount', invoice.amount,
'status', 'paid'
)
);
Step 5: Confirmation
Return payment confirmation:
{
"success": true,
"invoice_id": "uuid",
"payment_id": "pi_1234...", // Stripe payment intent ID
"amount": 50000, // cents
"currency": "USD",
"status": "paid",
"paid_at": "2026-01-15T14:30:00Z",
"payment_method": "stripe",
"confirmation_number": "..."
}
Payment Scheduling
For future payments:
INSERT INTO scheduled_payments (
tenant_id, invoice_id, amount, currency,
payment_method, scheduled_date, status
)
VALUES ($1, $2, $3, $4, $5, $6, 'pending');
Cron job checks scheduled_payments daily and executes when scheduled_date <= NOW().
Webhook Handling
Process Stripe webhooks:
payment_intent.succeeded- Mark invoice as paidpayment_intent.payment_failed- Alert user, retry or manual reviewcharge.refunded- Create refund transaction
Error Handling
- Insufficient Funds - Alert user, reschedule payment
- Payment Method Invalid - Request updated payment method
- API Error - Retry with exponential backoff (3 attempts)
- Network Timeout - Check payment status before retry (idempotency)
- Declined Payment - Alert user, mark for manual review
Integration Points
- stripe-integrator (Integration worker) - Stripe API
- paypal-integrator (Integration worker) - PayPal API
- payment-processor (AP worker) - Payment execution logic
- audit-trail - Immutable audit log
Models
- Payment Logic: Deterministic (no LLM)
- Error Analysis: Claude Sonnet 4 (for complex error scenarios)
Security
- Idempotency - Use idempotency keys for Stripe to prevent duplicate charges
- PCI Compliance - Never store full credit card numbers
- Secrets Management - API keys in environment variables, never in code
- Rate Limiting - Respect payment gateway rate limits
- Audit Trail - Log all payment attempts (success and failure)
- User Authorization - Verify user can approve payments (RBAC)
- Amount Verification - Confirm amount matches invoice before payment
Invoke this skill when executing vendor payments or processing customer payments through integrated gateways.
From the file to a first result
The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.
View the source and supporting filesThis download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.
1. Download the file
Download SKILL.mdFrom the root of a test project, save the file as .skill-downloads/payment-gateway-mmbizkcb/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.
Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.
mkdir -p '.skill-downloads/payment-gateway-mmbizkcb' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/payment-gateway-mmbizkcb/download' --output '.skill-downloads/payment-gateway-mmbizkcb/SKILL.md.part' && mv '.skill-downloads/payment-gateway-mmbizkcb/SKILL.md.part' '.skill-downloads/payment-gateway-mmbizkcb/SKILL.md'2. Check prerequisites
Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.
No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.
The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.
3. Load the skill
After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.
Claude Code
test -f '.skill-downloads/payment-gateway-mmbizkcb/SKILL.md' && test -s '.skill-downloads/payment-gateway-mmbizkcb/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/payment-gateway' && cp -R '.skill-downloads/payment-gateway-mmbizkcb' '.claude/skills/payment-gateway'OpenSkills
OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.
Official OpenSkills installationopenskills install './.skill-downloads/payment-gateway-mmbizkcb'openskills read 'payment-gateway-mmbizkcb'Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.
For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.
openskills syncManual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.
4. Try a first task
Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:
Read .skill-downloads/payment-gateway-mmbizkcb/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.
React Hook Form Best Practices
Development
Master React Hook Form: avoid anti-patterns, manage subscriptions, and handle reset, dirty state, and controlled inputs correctly.
Emotion to Mantine Migration
Development
Migrate Emotion styled-components to Mantine components with style props and CSS modules. Use when converting .styled.tsx files or removing @emotion imports.
Scope Creep Detector
Development
Analyzes git diffs against a stated intent to detect scope creep, unrelated files, broad PRs, and oversized changes, then suggests keep, split, or justify actions.