Skip to main content

Membership Lifecycle

High Level Overview

  1. A customer is sent to the Stripe Payment Link for a product which renews
  2. Upon successful signup they have entered their credit card details and the very first membership invoice has been generated (IE: for the next week if it's a weekly membership) which is how stripe handles all Memberships (pay in advance)
  3. When that period ends a new invoice is generated and the credit card is charged. The cycle continues forever until the subscription is cancelled. 
  4. The BOS is notified of all subscriptions and subscription invoices. It links up the subscription invoices with the classes that are covered by that subscription (IE: The $50 membership for cycling classes is mapped immediately to the two cycling classes that client has booked in for this week at $25 each). 
  5. Any changes to the class attendances (IE: joining an extra cycling class, cancelling one) will cause The BOS to reallocate the funds interally (IE: cancelling one of the classes means that the remaining class is billed off as $50)
  6. At the end of the invoice period the finalised invoice is sent to Nookal. 

Benefits of the Memberships System

Automated Billing in Nookal saves time and prevents errors. 

Class attendances are automatically billed off at the end of the billing cycle so administration staff don't need to manually bill of each attendance and cross reference data between multiple systems (class attendances in nookal calendar vs active stripe subscriptions).

This process gets more time consuming and more error prone as both number of subscriptions and number of types of subscriptions (each with their own list of permitted classes) increases. 

Definitions

Term DefinitionData SourceDescription

Stripe Subscription

Stripe
Subscription created in stripe (usually via sign-up page) for an individual customer.

Class

Nookal
A type of Class set up in your PMS

Membership Type

BOS
Links a Stripe Product with one or more Classes so The BOS can report on Memberships using this product and generate matching invoices. 

Stripe Invoice
StripeAn Invoice is generated at the start of every subscription period. 
EG: A Weekly subscription will generate a new invoice covering the next 7 days on the signup date and every week after. 

Matching Classes
BOS When looking at a particular Invoice the matching classes are classes that are:
  • attended by the client who the subscription belongs to
  • covered by that MembershipType
  • not cancelled or DN
Nookal InvoiceBOS then NookalA Nookal Invoice is generated at the end of a Stripe Invoice period and sent to Nookal to bill off any class attendances in that period

How the Nookal Invoice is calculated

Find Matching Classes

Matching classes are determined by: Invoice.Subscription.Membership.MatchingClasses which means:

  1. Find the Stripe Subscription that this invoice belongs to
  2. Find the matching BOS Managed Membership that has been set up (if any)
  3. Find the classes that this BOS Managed Membership has been set up for

The BOS then finds any classes of those types that have been booked for the patient associated with the subscription, then ignores any of the following:

  • Any attendances that are marked as Cancelled or DNA
  • Any attendances that have been marked as invoiced manually (IE: not by BOS Memberships system)

Any classes that remain will be included in the Nookal Invoice. If there are no classes remaining then an AdHoc Invoice is generated, which is associated with the client but is not linked to any classes and is just there to represent that the client was charged. 

To calculate the charges:

  • The 'normal' price of a class is completely ignored.
  • Divide subscription amount (full amount client was charged) by the number of classes
  • Make small adjustments to amounts to ensure that the totals match (EG: 3 classes at $100.00 would be $33.33, $33.33, and $33.34 so it matches exactly $100). 

If you use the Invoice Shipper: The 'normal' stripe invoice is shipped to Xero so it will simply be a charge for whatever the subscription is called, not an itemised invoice for individual classes like we send to Nookal.