SuperAPI AI Directory

stripe-setup

Marketing & growth

View repository

Updated 10-15 16:57

About this skill

Stripe Auto-Setup

Connect your Stripe account to Affitor with a single command. Automatically configures webhooks for payment tracking.

Quick Setup

npx affitor setup stripe

This command:

  1. Opens your browser to authorize Stripe Connect (read-only access)
  2. Creates a webhook endpoint on your Stripe account pointing to Affitor
  3. Subscribes to the required payment events
  4. Saves the connection to your Affitor program

What Gets Configured

The CLI creates a webhook endpoint that listens for:

Event Purpose
customer.created New customer attribution
checkout.session.completed One-time payment tracking
invoice.paid Subscription payment tracking
invoice.payment_failed Failed payment handling
charge.refunded Refund processing
customer.subscription.deleted Churn tracking

Prerequisites

  • Run npx affitor init first (creates your program)
  • Have a Stripe account with API access
  • .affitor/config.json must exist in your project

After Setup

Verify the connection:

npx affitor status

Test a sale event:

npx affitor test sale

You can also verify in your Stripe Dashboard under Developers → Webhooks — you should see the Affitor endpoint listed.

Manual Alternative

If you prefer not to use OAuth, you can add Stripe metadata manually instead. See the sale-tracking skill for the metadata approach.