paypal-integration — Claude Code skill for PayPal payments
This skill covers PayPal checkout, subscriptions, refunds, and payment notifications. Use it when adding PayPal payments or recurring billing to an application.
/plugin marketplace add wshobson/agents
/plugin install payment-processing@claude-code-workflowsWhat paypal-integration does
The skill outlines client-side integration with the JavaScript SDK and server-side integration through the REST API. Its examples show Smart Payment Buttons, order creation and capture, and backend payment verification. IPN is covered for asynchronous payment updates, with verification required.
It also covers subscriptions, refunds, and payouts to multiple recipients. The testing example uses sandbox credentials and PayPal test buyer and seller accounts; additional patterns are in references/details.md.
Install it when your project needs PayPal checkout or recurring payments. It is not relevant if you are integrating a different payment provider.
What it helps with
- add Express Checkout to an order flow
- set up recurring subscription billing
- verify and capture an order on the backend
- handle IPN payment notifications
- issue refunds or send payouts to recipients
Example prompts for the agent
- Add PayPal Smart Payment Buttons to checkout and send the orderID to the backend for verification.
- Set up PayPal subscriptions with automatic renewals.
- Show me how to test the payment flow with sandbox credentials and PayPal test accounts.
How to install paypal-integration
1Plugin marketplace
/plugin marketplace add wshobson/agents/plugin install payment-processing@claude-code-workflowsThis installs the whole payment-processing plugin with all its skills
2Skills CLI (Vercel)
npx skills add wshobson/agents --skill paypal-integration -a claude-code3Manually: put the files in place
~/.claude/skills/paypal-integration/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/paypal-integration/
1Skills CLI (Vercel)
npx skills add wshobson/agents --skill paypal-integration -a codex2Manually: put the files in place
.agents/skills/paypal-integration/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add wshobson/agents --skill paypal-integration -a cursor2Manually: put the files in place
.cursor/skills/paypal-integration/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install wshobson/agents paypal-integration2Manually: put the files in place
.github/skills/paypal-integration/SKILL.mdPlatform CLI
gemini skills install https://github.com/wshobson/agents --path plugins/payment-processing/skills/paypal-integrationManually: put the files in place
.devin/skills/paypal-integration/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set213
The whole set →Similar
Questions about paypal-integration
How do I install paypal-integration in Claude Code?
To install it with skills, run npx skills add wshobson/agents --skill paypal-integration -a claude-code. Marketplace installation commands are also provided.
What does paypal-integration do?
It covers PayPal checkout, subscriptions, refunds, and IPN handling. The examples use the JavaScript SDK and REST API.
How do I test PayPal payments?
Use sandbox credentials and buyer and seller test accounts created at developer.paypal.com. The skill includes an example payment-flow test.
Source text
SKILL.md · MIT
---
name: paypal-integration
description: Integrate PayPal payment processing with support for express checkout, subscriptions, and refund management. Use when implementing PayPal payments, processing online transactions, or building e-commerce checkout flows.
---
# PayPal Integration
Master PayPal payment integration including Express Checkout, IPN handling, recurring billing, and refund workflows.
## When to Use This Skill
- Integrating PayPal as a payment option
- Implementing express checkout flows
- Setting up recurring billing with PayPal
- Processing refunds and payment disputes
- Handling PayPal webhooks (IPN)
- Supporting international payments
- Implementing PayPal subscriptions
## Core Concepts
### 1. Payment Products
**PayPal Checkout**
- One-time payments
- Express checkout experience
- Guest and PayPal account payments
**PayPal Subscriptions**
- Recurring billing
- Subscription plans
- Automatic renewals
**PayPal Payouts**
- Send money to multiple recipients
- Marketplace and platform payments
### 2. Integration Methods
**Client-Side (JavaScript SDK)**
- Smart Payment Buttons
- Hosted payment flow
- Minimal backend code
**Server-Side (REST API)**
- Full control over payment flow
- Custom checkout UI
- Advanced features
### 3. IPN (Instant Payment Notification)
- Webhook-like payment notifications
- Asynchronous payment updates
- Verification required
## Quick Start
```javascript
// Frontend - PayPal Smart Buttons
<div id="paypal-button-container"></div>
<script src="https://www.paypal.com/sdk/js?client-id=YOUR_CLIENT_ID¤cy=USD"></script>
<script>
paypal.Buttons({
createOrder: function(data, actions) {
return actions.order.create({
purchase_units: [{
amount: {
value: '25.00'
}
}]
});
},
onApprove: function(data, actions) {
return actions.order.capture().then(function(details) {
// Payment successful
console.log('Transaction completed by ' + details.payer.name.given_name);
// Send to backend for verification
fetch('/api/paypal/capture', {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({orderID: data.orderID})
});
});
}
}).render('#paypal-button-container');
</script>
```
```python
# Backend - Verify and capture order
from paypalrestsdk import Payment
import paypalrestsdk
paypalrestsdk.configure({
"mode": "sandbox", # or "live"
"client_id": "YOUR_CLIENT_ID",
"client_secret": "YOUR_CLIENT_SECRET"
})
def capture_paypal_order(order_id):
"""Capture a PayPal order."""
payment = Payment.find(order_id)
if payment.execute({"payer_id": payment.payer.payer_info.payer_id}):
# Payment successful
return {
'status': 'success',
'transaction_id': payment.id,
'amount': payment.transactions[0].amount.total
}
else:
# Payment failed
return {
'status': 'failed',
'error': payment.error
}
```
## Detailed patterns and worked examples
Detailed pattern documentation lives in `references/details.md`. Read that file when the navigation tier above is insufficient.
## Testing
```python
# Use sandbox credentials
SANDBOX_CLIENT_ID = "..."
SANDBOX_SECRET = "..."
# Test accounts
# Create test buyer and seller accounts at developer.paypal.com
def test_payment_flow():
"""Test complete payment flow."""
client = PayPalClient(SANDBOX_CLIENT_ID, SANDBOX_SECRET, mode='sandbox')
# Create order
order = client.create_order(10.00)
assert 'id' in order
# Get approval URL
approval_url = next((link['href'] for link in order['links'] if link['rel'] == 'approve'), None)
assert approval_url is not None
# After approval (manual step with test account)
# Capture order
# captured = client.capture_order(order['id'])
# assert captured['status'] == 'COMPLETED'
```
© Seth Hobson · MIT · wshobson/agents