Skip to main content

Subscription Object

Subscriptions enable recurring payments for memberships, services, or product deliveries. They automatically charge customers at specified intervals using their stored HSA/FSA or regular payment method.

The Subscription Object

Attributes

Subscription Status

Billing Intervals

Subscription Lifecycle

A subscription moves through these states:
  • trialing - Subscription created with trial period
  • active - Subscription is active and billing normally (can come from trialing or be created without trial)
  • past_due - Payment failed, retrying (can come from trialing or active)
  • cancelled - Cancel requested, will end at period end
  • ended - Subscription has ended (can come from cancelled, past_due after max retries, or active for immediate cancellation)

Trial Periods

Subscriptions can include a free trial period:
During trial:
  • Customer is not charged
  • Payment method is verified
  • First charge occurs when trial ends

Payment Method

Cancellation Behavior

Cancel at Period End

Customer retains access until period end.

Immediate Cancellation

Access ends immediately.

Past Due Handling

When a payment fails:
  1. Status changes to past_due
  2. Automatic retry attempts (days 3, 7, 14)
  3. Customer receives notification
  4. After max retries, subscription ends

Examples

Monthly Membership

Quarterly Subscription

Annual Plan with Trial