The typical Autumn flow looks like this:

1

Define your pricing model in the Autumn dashboard

The dashboard is where you define which of your users get access to what, and how much they’re charged for it. Here, you’ll create products and manage your customers.

2

Call attach when a customer wants to purchase a product

From your application, when your customer wants to purchase one of your price plans, the attach endpoint will return a Stripe checkout URL.

Once they’ve purchased, Autumn grants access to the product’s features that were defined in the dashboard.

If the customer is already paying for a plan, this will automatically handle any upgrades and downgrades too.

3

Check whether a customer has access to something

From your application, you can check in real-time whether a customer has access to:

  • a product (eg, pro tier)
  • a feature balance (eg, 10 remaining credits)
  • a feature flag (eg, premium AI models)

Autumn will return whether they’re allowed access, and you can use this to control access to your features. When you want to update your pricing model, you can do so without changing any of your code.

4

Track usage for usage-based features

For your usage-based features, if Autumn tells you they’re allowed access, you can track their usage to update their balance.

This means Autumn can enforce any usage limits you set (ie, by returning allowed: false once they hit a balance of 0). It also allows you to charge for usage (eg, $1 per AI tokens used), if you have a usage-based pricing model.

5

Display customer's information and balances

When using usage-based features, you’ll typically want to display the customer’s balance to them. You can do this from the customers route or hook, which will return customer information, the product they’ve purchased, and the balance of any usage-based features.

Now that you understand how Autumn works, check out one of the quickstart guides to get started!