stripe-connect
Stripe Connect
Connect your Stripe account. One API key, one minute.
How to Set Up
- User goes to dashboard.stripe.com/apikeys
- Copies the Secret key (starts with
sk_live_orsk_test_) - Pastes it in the chat
⚠️ Use a Restricted key for safety. In the Stripe Dashboard, click + Create restricted key, give it Read permissions only, and use that key instead of the full secret key. This way the AI can view data but can't create charges or modify anything.
AI Agent Flow
Check if configured:
python3 stripe-connect/scripts/stripe_connect.py --check
Returns JSON: {"configured": true, "mode": "live", "account": "..."} or {"configured": false}.
Save key (after user pastes it):
python3 stripe-connect/scripts/stripe_connect.py --set-key "sk_live_xxxxxxxxxxxxx"
Saves to ~/.config/stripe/config.json and verifies the key works by calling the Stripe API.
When Stripe is not configured, tell the user EXACTLY this:
"To connect Stripe, I just need your API key. It takes about 1 minute:
- Open this page: https://dashboard.stripe.com/apikeys
- Copy an API key — either:
- The Secret key (starts with
sk_live_orsk_test_) — has full access - Or better: create a Restricted key (starts with
rk_live_orrk_test_) with Read-only permissions
- The Secret key (starts with
- Paste the key here
For a detailed guide: https://skillpack.gitbook.io/skillpack-docs/integrations/stripe"
CRITICAL RULES
- NEVER ask for OAuth or client_id — Stripe uses a single API key
- Key starts with
sk_live_,sk_test_,rk_live_, orrk_test_— if the user pastes a publishable key (pk_), that's wrong - Recommend restricted keys — always suggest read-only restricted keys for safety
- Always show the Gitbook link when guiding setup
When a Command Fails with "Permission denied" or 403
The user's restricted key is missing permissions for that resource. Tell them:
"Your API key doesn't have permission to access [resource]. To fix this:
- Go to https://dashboard.stripe.com/apikeys
- Find your restricted key and click the pencil icon (edit)
- Scroll to the [resource category] section (e.g. Core, Billing)
- Change the permission from None to Read
- Click Save
Then try again. For a detailed guide, see: https://skillpack.gitbook.io/skillpack-docs/integrations/stripe"
Credential Storage
| File | Path |
|---|---|
| Config | ~/.config/stripe/config.json |
| Format | {"api_key": "sk_...", "mode": "live/test", "account_id": "acct_..."} |
| Permissions | 0600 (user-only read) |
Follow-Up Questions
- "Show me this month's revenue"
- "List my recent customers"
- "Check for failed payments"