Customer Memberships API Documentation

Overview

This collection contains customer memberships — the records of customers enrolled in your organization's membership types. Each record represents one membership owned by a customer, including its status, term dates, billing details, and (for group memberships) the members it covers. This is the collection to pull to learn who your members are.

Each record links to its membership type via membership_id (see the Membership Types collection) and to its owning customer via owner_id (see the Customers collection). For a per-member view with one row per person (including covered group members), see the Members collection.

This collection is read-only: only the list and read operations are supported. Results are ordered by membership start date, newest first.

Memberships that never completed their initial payment (statuses PAY and IPC) are never returned. All other statuses — including active, frozen, ended/cancelled, denied, and not-yet-started memberships — are returned by default. See Statuses and Pulling All Members.

Fields

All fields are read-only. They are grouped below by purpose for readability; all groups appear together in each record.

Member & Owner

NameTypeDescription
idintegerThe unique identifier of the customer membership record. This is placed in the URL when making API calls for the membership.
urlstring (URL)The unique API URL of the customer membership.
owner_idintegerThe identifier of the customer who owns the membership.
owner_urlstring (URL)The API URL of the owning customer.
owner_first_namestringThe owner's first name.
owner_last_namestringThe owner's last name.
owner_emailstringThe owner's email address.
owner_birthdaystring (ISO-8601 date) or nullThe owner's birthday.
owner_home_location_idinteger or nullThe identifier of the owner's home location.
owner_home_location_namestring or nullThe name of the owner's home location.
owner_is_memberbooleanWhether the owner is themselves a covered member of the membership (an owner may pay for a membership without being a member of it).

Membership Type

These fields describe the membership type this record is enrolled in.

NameTypeDescription
membership_idintegerThe identifier of the membership type.
membership_urlstring (URL)The API URL of the membership type.
namestringThe membership type's name.
membership_statusstringThe membership type's own status (DRA, ACT, or RET) — not the member's status.
purchase_typestringThe membership type's purchase type: REC (Recurring), PRE (Prepaid), or BEN (Benefit).
intervalstringThe membership type's billing interval for recurring types (e.g. MON), or empty for prepaid. See billing intervals.
is_groupbooleanWhether this is a group membership covering multiple members.
is_youth_programmingbooleanWhether the membership type is a youth programming membership.
has_fixed_date_rangesbooleanWhether the membership type runs over fixed calendar date ranges.
duration_yearsinteger or nullThe membership type's duration in years, if applicable.
duration_monthsinteger or nullThe membership type's duration in months, if applicable.
duration_daysinteger or nullThe membership type's duration in days, if applicable.

Status & Dates

NameTypeDescription
statusstringThe membership's status. One of the statuses.
is_pending_staff_approvalbooleanWhether the membership is awaiting staff approval and not yet usable for entry.
start_datestring (ISO-8601 date)The membership's start date, in the local time of your organization.
has_startedbooleanWhether the membership has started as of now. A membership with a future start_date has has_started of false.
end_datestring (ISO-8601 date)The membership's end date (or next bill date for recurring memberships), in organization-local time.
days_remainingintegerThe number of days remaining (or days frozen, if frozen).
membership_cancel_datestring (ISO-8601 date) or nullThe scheduled cancellation date, if a cancellation is scheduled.
membership_freeze_datestring (ISO-8601 date) or nullThe scheduled freeze date, if a freeze is scheduled.
membership_unfreeze_datestring (ISO-8601 date) or nullThe scheduled unfreeze date, if applicable.
new_end_date_if_unfrozenstring (ISO-8601 date) or nullThe projected end date if the membership were unfrozen now. Null if not frozen.
last_date_frozenstring (ISO-8601 date) or nullThe date the membership was last frozen.
days_frozeninteger or nullThe number of days remaining at the time of freezing; null when frozen until the next bill date.
created_atstring (ISO-8601 datetime)When the membership record was created, as a UTC timestamp.
updated_atstring (ISO-8601 datetime)When the membership record was last updated, as a UTC timestamp.

Members Covered (Group Memberships)

NameTypeDescription
all_customerslist of JSON objectsAll members covered by this membership. See the covered member object.
customers_less_ownerlist of JSON objectsThe covered members excluding the owner, in the same shape as all_customers.
unlinked_customerslist of JSON objectsCovered people who do not have their own customer account. Each object has id, first_name, and last_name.
customer_add_onsJSON objectA map of customer ID to the list of add-ons currently applied to that member. Keys for unlinked members are prefixed with u.
customer_add_ons_to_addJSON objectAdd-ons scheduled to be added at the next billing cycle (recurring memberships only).
customer_add_ons_to_removeJSON objectAdd-ons scheduled to be removed at the next billing cycle.
customer_add_on_optionslist of JSON objectsThe add-on options available for this plan and location.

Billing & Payment

NameTypeDescription
billing_amountstring (decimal)The amount billed each interval for recurring memberships (after any recurring discount); 0 for non-recurring memberships.
billing_location_idinteger or nullThe identifier of the location used for billing.
billing_location_urlstring (URL) or nullThe API URL of the billing location.
billing_location_namestring or nullThe name of the billing location.
location_idinteger or nullThe identifier of the membership's location.
location_urlstring (URL) or nullThe API URL of the membership's location.
location_namestring or nullThe name of the membership's location.
payment_processor_connection_idinteger or nullThe identifier of the resolved payment-processor connection.
payment_processor_typestring or nullThe payment processor type (e.g. Stripe).
has_payment_methodbooleanWhether a saved payment method is on file for the membership.
payment_method_typestring or nullThe type of the saved payment method.
payment_method_last4string or nullThe last four digits of the saved payment method.
payment_method_exp_monthinteger or nullThe expiry month of the saved card.
payment_method_exp_yearinteger or nullThe expiry year of the saved card.
upcoming_bill_dateslist of datesThe next bill dates (up to twelve) for recurring memberships; empty otherwise.
has_freeze_feebooleanWhether a freeze fee applies to this membership.
one_off_discount_typestringThe type of any one-off discount: CUR (currency amount) or PER (percentage).
one_off_discount_amountstring (decimal)The amount of any one-off discount.
one_off_discount_applies_to_add_onsbooleanWhether the one-off discount applies to add-ons.
one_off_discount_namestringThe name of the one-off discount.

Recurring memberships additionally include a set of recurring_discount_* fields describing any automatic recurring discount applied to the membership (its type, amount, name, code, and the association, plan, or referral it derives from). These are null for memberships with no recurring discount.

Invoices & Totals

NameTypeDescription
last_invoice_idinteger or nullThe identifier of the most recent invoice for this membership.
last_invoice_amountstring (decimal) or nullThe amount of the most recent invoice.
last_invoice_tax_amountstring (decimal) or nullThe tax amount of the most recent invoice.
last_invoice_datestring (ISO-8601 date) or nullThe date of the most recent invoice.
first_completed_invoice_datestring (ISO-8601 date) or nullThe date of the first completed invoice for this membership.
total_paid_to_datestring (decimal)The total amount paid toward this membership to date.
total_refunded_to_datestring (decimal)The total amount refunded for this membership to date.

Referral, Staff & Other

NameTypeDescription
referring_customer_idinteger or nullThe identifier of the customer who referred this membership, if any. Accompanied by referring_customer_url, referring_customer_first_name, referring_customer_last_name, referring_customer_birthday, and referring_customer_email.
staff_user_idinteger or nullThe identifier of the staff member who sold the membership, if any. Accompanied by staff_user_email, staff_user_first_name, and staff_user_last_name.
rolling_event_type_idinteger or nullFor memberships tied to a rolling event type, the identifier of that event type.
rolling_event_type_roster_idinteger or nullThe identifier of the associated roster, if any.
rolling_event_type_roster_namestring or nullThe name of the associated roster, if any.
event_granting_benefit_idinteger or nullThe identifier of the event that granted this membership as a benefit, if any.
event_granting_benefit_namestring or nullThe name of the event that granted this membership as a benefit, if any.
status_change_logs_urlstring (URL)The API URL of this membership's status-change log sub-collection.

Covered Member Object

Each entry in all_customers and customers_less_owner is a JSON object with the following fields:

NameTypeDescription
idintegerThe covered member's customer ID.
member_idintegerThe identifier of the membership-member link record.
first_namestringThe covered member's first name.
last_namestringThe covered member's last name.
is_individually_frozenbooleanWhether this member is individually frozen.
is_pending_additionbooleanWhether this member is pending addition to the membership.
is_pending_removalbooleanWhether this member is pending removal from the membership.
member_freeze_datestring (ISO-8601 date) or nullThe member's scheduled freeze date, if any.
member_unfreeze_datestring (ISO-8601 date) or nullThe member's scheduled unfreeze date, if any.

Statuses

The two initial statuses below are never returned by this collection; all others are returned.

NameSyntaxReturned?
Awaiting Initial PaymentPAYNo
Initial Payment CancelledIPCNo
Initial Payment ProcessingIPPYes
ActiveACTYes
FrozenFRZYes
Renewal Payment PendingPPEYes
Renewal Payment ProcessingPPRYes
Renewal Payment FailedPAFYes
Freeze Payment PendingFPEYes
Freeze Payment ProcessingFPRYes
Freeze Payment FailedFPFYes
Denied Staff ApprovalDENYes
Ended (cancelled or expired)ENDYes

There is no distinct "future" status: a not-yet-started membership has status ACT with a future start_date and has_started of false.

Filters

See the filtering documentation for more information on how to use filters in the Capitan API.

NameSyntaxDescription
Membership Type membership_id Filters for memberships enrolled in the given membership type ID.
Status status_in Filters for memberships whose status is one of the given comma-separated codes. For example, ACT,FRZ.
Minimum Start Date start_date_min Filters for memberships starting on or after the given date (organization-local).
Maximum Start Date start_date_max Filters for memberships starting on or before the given date (organization-local, inclusive).
Minimum End Date end_date_min Filters for memberships ending on or after the given date (organization-local).
Maximum End Date end_date_max Filters for memberships ending on or before the given date (organization-local, inclusive).
Purchase Type membership_purchase_type Filters for memberships whose membership type has the given purchase type (REC, PRE, or BEN).
Is Recurring membership_is_recurring If true, filters for recurring memberships; if false, excludes them.
Is Group membership_is_group Filters for memberships whose plan is (true) or is not (false) a group membership.
Is Youth Programming membership_is_youth_programming Filters for memberships whose plan is (true) or is not (false) a youth programming membership.
Owner Home Location owner_home_location_id Filters for memberships whose owner's home location is the given ID.
Has Payment Method has_payment_method Filters for memberships that have (true) or do not have (false) a saved payment method.

Operations

List

Request
GET /api/customer-memberships/

Response
200 OK
{
    "count": 540,
    "next": "https://api.hellocapitan.com/api/customer-memberships/?page=2",
    "previous": null,
    "results": [
        {
            "id": 84213,
            "url": "https://api.hellocapitan.com/api/customer-memberships/84213/",
            "membership_id": 412,
            "name": "Adult Monthly Membership",
            "status": "ACT",
            "purchase_type": "REC",
            "interval": "MON",
            "start_date": "2025-03-01",
            "has_started": true,
            "end_date": "2026-07-01",
            "owner_id": 53120,
            "owner_first_name": "Jordan",
            "owner_last_name": "Rivera",
            "owner_email": "jordan.rivera@example.com",
            "all_customers": [
                {"id": 53120, "member_id": 70881, "first_name": "Jordan", "last_name": "Rivera",
                 "is_individually_frozen": false, "is_pending_addition": false, "is_pending_removal": false,
                 "member_freeze_date": null, "member_unfreeze_date": null}
            ],
            "billing_amount": "59.00",
            "total_paid_to_date": "885.00",
            "created_at": "2025-03-01T16:04:22.511000Z",
            "updated_at": "2026-06-01T09:15:03.220000Z",
            ...
        },
        ...
    ]
}

Read

Request
GET /api/customer-memberships/84213/

Response
200 OK
{
    "id": 84213,
    "url": "https://api.hellocapitan.com/api/customer-memberships/84213/",
    "membership_id": 412,
    ...
}

Pulling All Members

To pull every member — active, frozen, ended/cancelled, denied, and not-yet-started — issue an unfiltered, paginated request. No status parameter is required to include non-active records; all statuses except the two never-paid initial states (PAY, IPC) are returned by default.

GET /api/customer-memberships/?page_size=100

Page through results using the next link until it is null; see the pagination documentation. To restrict to current members, filter with status_in=ACT,FRZ. Each record carries an updated_at timestamp you can use to detect changes between snapshots.