autumn-setup

Integrates Autumn billing by installing the SDK, creating customers, and wiring Stripe payment flows.

2.7k|244|Updated Jan 21, 2025
One-click install
npx skills add https://github.com/useautumn/autumn --skill autumn-setup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: autumn-setup
Source: https://github.com/useautumn/autumn/tree/main/packages/atmn-tests/.claude/skills/autumn-setup
Command: npx skills add https://github.com/useautumn/autumn --skill autumn-setup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Setting up billing and entitlements requires wiring SDKs, customer creation, and payment flows across your stack. This Skill guides an AI through integrating Autumn (a billing layer over Stripe) into an existing codebase, handling framework detection and customer modeling decisions.

Core Features & Use Cases

  • Stack Detection: Analyzes the codebase to detect language, framework (Next.js, Hono, React), and whether customers should map to users or organizations.
  • Fullstack or Backend-Only Paths: Provides a React + Node.js path with autumnHandler, AutumnProvider, and useCustomer hooks, or a backend-only path for Node.js, Python, or cURL.
  • Payment Flow Setup: Wires up the attach call that returns Stripe Checkout URLs and handles upgrades, downgrades, top-ups, and renewals.
  • Use Case: You have a Next.js SaaS app and want to add paid plans. The Skill installs autumn-js, mounts the handler at /api/autumn/*, wraps the app in AutumnProvider, creates customers on signup, and adds a purchase button that redirects to Stripe Checkout.

Quick Start

Set up Autumn billing in my app: install the SDK, create a customer, and add the payment flow for my Pro plan.

Frequently Asked Questions about autumn-setup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I integrate Autumn billing into a Next.js app?

Install autumn-js, then mount autumnHandler from autumn-js/next at app/api/autumn/[...all]/route.ts with an identify function returning your user or org ID. Wrap your app in AutumnProvider and use the useCustomer hook to create customers and call attach for payments.

How do I create an Autumn customer from my backend?

Call autumn.customers.getOrCreate with your internal user or org ID, name, and email after initializing the Autumn client with your secret key. Autumn uses your existing auth ID as the customer ID, so no extra ID storage is needed.

Does Autumn support Python backends?

Yes, install autumn-sdk via pip and initialize the Autumn client with your secret key. It supports customer creation via customers.get_or_create and payment flows via billing.attach, which returns a Stripe payment URL.

Should Autumn customers be users or organizations?

It depends on your product model: B2C apps map customers to individual users with their own plans, while B2B apps map customers to organizations so plans and limits are shared across the team. Check your auth setup for org or workspace models to decide.

How does the Autumn attach payment flow work?

Calling attach with a planId and redirectMode set to always returns a payment URL. New purchases redirect to Stripe Checkout, while subsequent charges use an Autumn-hosted one-click confirmation page, covering upgrades, downgrades, top-ups, and renewals.