A Membership
represents a membership belonging to one or more Customer
s.
The ID of the membership
The ID of the site this membership belongs to
membership_number
The unique membership number of the lead member. This is always a 10 digit numeric string.
Since this field only relates to the lead member, this is now deprecated.
Instead, find the membership for the relevant customer in the members
array.
Possible values are active
, needs_dd_mandate
, needs_attention
, reserved
, inactive
, expired
and upcoming
Where the membership was created
Possible values are self_signup
, app
, import
and unknown
Details about the payment method attached to this membership. This payment method is used to take payment on the monthly billing period. If a payment method hasn't been set up, this will be null.
The date which the membership starts
The date which the membership ends
The datetime which the membership was created
The basket ID which was used to purchase this membership, if applicable.
An external reference for this membership.
The date which the membership will next be billed
next_charge
A summary of the next charge that's due for this membership.
This property is only populated when the membership was retrieved using the `getCustomerMemberships endpoint.
A string describing what kind of action needs to take place
Possible values are no_mandate
, setup_unpaid
, mandate_revoked
, payment_failed
, payment_disputed
, payment_outstanding
and site_id
""
listMemberships
This endpoint lists the Membership
s which are associated to the provided site.
The Membership
s were successfully retrieved
{
"data": [
{
"id": "0f7fe39b-0132-618f-0900-16b2bade2a81",
"site_id": "109dcaa6-c374-d28c-bb55-5379bc8fe88c",
"membership_number": "1234567890",
"customer": {
"id": "9374f81c-8699-a010-30be-e2659bc244ec",
"first_name": "Jane",
"last_name": "Doe",
"full_name": "Jane Doe",
"phone": "+447900000000",
"has_password": true,
"dob": "1944-12-30",
"brand_id": "63e6cb6a-b0ad-d0ce-d8a2-8ac20ef746c9",
"site_id": "fa1d3469-8a52-6028-5d62-8a7e8d3bca95",
"stripe_id": "cus_1234567890",
"express_stripe_id": "cus_1234567890",
"email": "janedoe@example.com",
"labels": [
{
"id": "13607b25-32c0-84c0-0b98-f86ccc2e5fed",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "57efd812-cebc-2ce6-795f-d84cfb16c31e",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "3ed56269-6c31-2e1f-a8c5-fbd05727c212",
"value": "VIP",
"colour": "ff6634"
}
],
"preferred_locale": "en",
"locked_at": "1947-12-26T08:45:30.0Z",
"created_at": "1890-07-05T01:54:40.0Z",
"updated_at": "1961-02-23T07:08:55.0Z",
"deleted_at": "1895-08-20T16:13:39.0Z",
"last_active_at": "1908-01-30T16:08:27.0Z",
"email_verified_at": "1950-09-28T15:48:33.0Z",
"last_check_in": {
"checked_in_at": "1939-03-22T09:51:57.0Z",
"method": "Scanned"
},
"avatar_id": "000000-000000-000000-000000",
"avatar": {
"id": "c27f48a7-8a59-800d-4588-82d1c9449bef",
"file_name": "super-cool-photo.jpg",
"mime_type": "image/jpeg",
"size": 84256,
"url": "https://example.com/media/super-cool-photo.jpg"
},
"external_ref": "laboris"
},
"members": [
{
"customer_id": "dcd2afe3-5510-e77d-a61e-4c992de91c46",
"membership_number": "1234567890",
"is_lead": false
},
{
"customer_id": "5d02cd68-3f23-0138-a3e4-6c42dde525ba",
"membership_number": "1234567890",
"is_lead": true
}
],
"type": {
"id": "2f1ef4af-893d-0b3a-f6df-f4b744bfdea4",
"name": "Gold tier",
"description": "Enjoy exclusive benefits as part of being a member in our Gold tier",
"terms": "commodo",
"brand_id": "952c1e2f-7f44-e78b-e84d-ccc87c2a8052",
"offline_payments": false,
"disable_confirmation_email": false,
"private": true,
"visibility": "public",
"minimum_start_date": "1947-07-27T17:15:39.0Z",
"min_members": 2,
"max_members": 4,
"rates": [
{
"id": "161fd90a-826a-6569-2383-452e26295615",
"membership_type_id": "9158b534-5dfc-813b-6162-60ab4b3a9dc2",
"name": "Standard rate",
"currency": "GBP",
"price": 5000,
"joining_fee": 1000,
"tax": 1250,
"billing_frequency": "P1M",
"processors": [
"nulla ad sit Ut voluptate",
"ullamco Excepteur reprehenderit mollit",
"irure consectetur et deserunt",
"reprehenderit do",
"officia adipisicing in elit"
]
},
{
"id": "d6ad538c-040b-71b0-f331-400d824b4c34",
"membership_type_id": "6cf524f6-0597-93d1-eceb-5bda91cd0861",
"name": "Standard rate",
"currency": "GBP",
"price": 5000,
"joining_fee": 1000,
"tax": 1250,
"billing_frequency": "P1M",
"processors": [
"sunt anim pariatur",
"nisi ea"
],
"default_duration": "P1Y",
"private": true
},
{
"id": "2d7220c6-8675-61d8-beac-083d89301d3b",
"processors": [
"sed tempor ipsum",
"Duis minim",
"amet"
],
"default_duration": "P1Y",
"created_at": "1900-11-18T11:30:55.0Z",
"updated_at": "1949-03-07T12:08:07.0Z"
},
{
"membership_type_id": "30ea7c8f-11a5-e893-da3d-a986be793ed9",
"tax": 1250,
"billing_frequency": "P1M",
"processors": [
"veniam",
"anim reprehenderit Lorem deserunt",
"esse"
],
"default_duration": "P1Y",
"private": true,
"created_at": "1895-02-13T22:33:28.0Z",
"updated_at": "1938-06-10T16:53:30.0Z"
},
{
"id": "aacf22c3-2a3f-ac55-2871-8d504f4b49bf",
"membership_type_id": "28195c20-7201-a81b-f080-54803810da6a",
"name": "Standard rate",
"currency": "GBP",
"price": 5000,
"joining_fee": 1000,
"tax": 1250,
"billing_frequency": "P1M",
"processors": [
"Excepteur non in",
"qui reprehenderit quis",
"velit",
"nulla ullamco",
"in sint fugiat aute"
],
"default_duration": "P1Y",
"private": true,
"created_at": "1911-08-03T23:17:45.0Z"
}
],
"revenue_schedule": "FREQ=WEEKLY",
"created_at": "1922-07-06T13:16:11.0Z",
"updated_at": "1930-09-30T10:45:37.0Z",
"deleted_at": "1936-03-09T04:19:12.0Z"
},
"rate": {
"id": "646c9059-8d1e-b1ec-83fc-89fa0a7b75a8",
"membership_type_id": "ddb9c7d6-efcc-0309-5056-01eab5cfd2cc",
"name": "Standard rate",
"currency": "GBP",
"price": 5000,
"joining_fee": 1000,
"tax": 1250,
"billing_frequency": "P1M",
"processors": [
"mollit pariatur",
"pariatur"
],
"default_duration": "P1Y",
"private": true
},
"status": "needs_attention",
"source": "import",
"payment_method": {
"id": "tempor Lorem",
"type": "direct_debit",
"status": "revoked",
"card_brand": "amex"
},
"start_date": "1896-10-08T08:36:23.0Z",
"basket_id": "68e39645594ee2011f0000a0",
"next_billing_date": "1954-09-08T12:45:39.0Z",
"next_charge": {
"id": "e47bce05-c2b7-8aea-ee47-01c91c4cee95",
"amount": 3995,
"currency": "GBP",
"status": "processing",
"billing_period_from": "1952-11-10",
"billing_period_to": "1958-11-19"
},
"attention_reason": "setup_unpaid"
}
],
"meta": {
"from": 1,
"to": 2,
"total": 2,
"current_page": 1,
"last_page": 2,
"per_page": 15,
"path": "http://example.com/api"
},
"links": {
"first": "http://example.com?page=1",
"next": "https://example.com?page=3",
"prev": "https://example.com?page=1",
"last": "https://example.com?page=4"
}
}
getMembership
Use this endpoint to retrieve a Membership
by its ID.
membershipId
The ID of the membership
{
"data": {
"site_id": "f3573e9f-0be6-31ae-24de-91473d6bf69b",
"membership_number": "1234567890",
"customer": {
"id": "1d7076c4-af40-37f0-ff4e-8c535f16150b",
"first_name": "Jane",
"last_name": "Doe",
"full_name": "Jane Doe",
"phone": "+447900000000",
"has_password": true,
"dob": "1900-08-30",
"brand_id": "5fde5e99-7327-e157-85aa-4b8d13ea5c7f",
"site_id": "a17fe62d-baa5-8302-46be-d7e50042ef27",
"stripe_id": "cus_1234567890",
"express_stripe_id": "cus_1234567890",
"email": "janedoe@example.com",
"labels": [
{
"id": "13efe6bf-0277-f720-a68c-e2904945114e",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "16290d4a-8ae5-3b89-605d-80170ca39102",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "d2d585ce-e793-accf-5e04-64197f5d9661",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "5c2b05fa-5a0f-b754-b5da-89b637878c00",
"value": "VIP",
"colour": "ff6634"
},
{
"id": "ba5e072b-e7ea-0859-38a0-a911a3b51958",
"value": "VIP",
"colour": "ff6634"
}
],
"preferred_locale": "en",
"locked_at": "1892-05-24T02:10:03.0Z",
"created_at": "1951-04-04T03:43:49.0Z",
"updated_at": "1918-06-19T14:55:27.0Z",
"deleted_at": "1935-05-11T14:32:01.0Z",
"last_active_at": "1954-05-17T15:03:36.0Z",
"email_verified_at": "1891-04-23T17:43:15.0Z",
"last_check_in": {
"checked_in_at": "1917-12-12T13:14:48.0Z",
"method": "Scanned"
},
"avatar_id": "000000-000000-000000-000000",
"avatar": {
"id": "b1b2c996-d531-fc54-c197-e18ebb22db35",
"file_name": "super-cool-photo.jpg",
"mime_type": "image/jpeg",
"size": 84256,
"url": "https://example.com/media/super-cool-photo.jpg"
},
"external_ref": "sed commodo incididunt"
},
"members": [
{
"customer_id": "0f654ab7-3756-d9a1-1adb-3dcab6cb5ecd",
"membership_number": "1234567890"
},
{
"customer_id": "174e51a0-7db9-a326-6ec3-a6684ed032c1",
"membership_number": "1234567890"
},
{
"is_lead": false
},
{
"customer_id": "740b6b7b-4e65-0074-d351-818f6bb718c3",
"membership_number": "1234567890",
"is_lead": false
},
{
"customer_id": "3c69b029-a1a4-0d48-3e6b-d6c9f283070a",
"membership_number": "1234567890",
"is_lead": false
}
],
"rate": {
"id": "44b37203-0db1-1db4-a904-df59894d0194",
"membership_type_id": "2574e9a7-c939-f948-2bec-3470d26a4425",
"name": "Standard rate",
"currency": "GBP",
"price": 5000,
"joining_fee": 1000,
"tax": 1250,
"processors": [
"nisi",
"minim Excepteur"
],
"private": true,
"created_at": "1936-07-31T19:01:17.0Z"
},
"status": "inactive",
"source": "unknown",
"payment_method": {
"id": "in nulla commodo",
"status": "revoked",
"card_brand": "amex"
},
"external_ref": "dolore Ut voluptate",
"next_charge": {
"id": "83a262c2-71a5-9167-400d-cfa194471fde",
"amount": 3995,
"currency": "GBP",
"status": "pending",
"billing_period_from": "1901-10-27",
"billing_period_to": "1920-06-21"
}
}
}
{
"message": "The requested resource could not be found"
}
actionAddMembershipChargePayment
This endpoint allows a manual (off-Trybe) payment to be recorded against a membership charge.
chargeId
The ID of the charge
payment_type_id
The ID of the custom payment type this payment should be recorded as
amount
The amount of the payment
{
"data": {
"id": "d040dc14-ce7d-c7f3-5024-d6c3dfcf579c",
"membership": {
"id": "8a4746dd-a61c-b1e3-8c4f-8de000557755",
"membership_number": "00000014",
"type_name": "Gold Membership",
"customer_id": "d8ccb84e-c14f-2243-05a4-5bd706304882",
"customer_name": "Jane Jones"
},
"processor": "adyen",
"processor_data": {
"cardholder_name": "Mrs J Jones",
"last_4": 4001,
"processor_type": "Cash",
"processor_type_id": "68e39645594ee2011f0000a1"
},
"amount": 3995,
"currency": "gbp",
"tax": 1000,
"status": "succeeded",
"description": "consectetur adipisicing cillum fugiat Excepteur",
"can_download_receipt": false,
"amount_refunded": "laboris ut",
"refunded": "ullamco culpa non",
"refunds": [
{
"id": "c3ac1b58-d5b2-13ac-0cad-d7e0c10ef931",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "b11e77ca-48e9-27dd-2345-2357db169347",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1918-03-24T11:01:31.0Z",
"updated_at": "1915-09-11T08:45:54.0Z"
},
{
"id": "2f361659-c91a-0a4d-1ec9-cc6532a2c0f0",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1946-03-02T13:35:37.0Z",
"updated_at": "1930-10-15T15:12:56.0Z"
},
{
"id": "7b03543d-9095-521b-2c97-a7733e2ec864",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "abf7671f-2af0-b630-47c9-79f58d39154e",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1920-07-09T21:10:33.0Z",
"updated_at": "1928-05-31T09:06:29.0Z"
},
{
"id": "3f012f30-d955-9fd4-815b-9f6fd1a5e83d",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "51e34be2-ed16-134d-9b71-7bccc909c87e",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1890-07-30T01:14:08.0Z",
"updated_at": "1918-08-15T16:37:10.0Z"
},
{
"id": "cf376c09-6a1d-e2fb-c825-52607041e6c2",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "604d5225-7d9d-1d01-e7ed-071ea12b135a",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1969-10-31T06:57:34.0Z",
"updated_at": "1894-01-17T22:51:51.0Z"
}
],
"site_id": "0cd33dfa-81a1-f496-26fa-e9f7924a2455",
"billing_period_from": "1906-06-08",
"billing_period_to": "1936-04-03",
"created_at": "1906-01-16T01:33:51.0Z",
"updated_at": "1913-11-07T18:09:17.0Z"
}
}
{
"message": "The requested resource could not be found"
}
actionProcessMembershipCharge
This endpoint allows a membership charge to be processed manually.
chargeId
The ID of the charge
{
"data": {
"id": "f636db6b-9548-14df-e827-dfd653464b7d",
"membership": {
"id": "4ed14b7d-de8d-5d97-c929-eb8cfff9c01a",
"membership_number": "00000014",
"type_name": "Gold Membership",
"customer_id": "b9158791-cbfe-b4bd-ae37-db5d557f74b6",
"customer_name": "Jane Jones"
},
"processor": "adyen",
"processor_data": {
"last_4": 4001,
"processor_type": "Cash"
},
"amount": 3995,
"original_amount": 3995,
"currency": "gbp",
"tax": 1000,
"status": "succeeded",
"description": "non aute",
"can_download_receipt": true,
"amount_refunded": "ea commodo dolore tempor",
"refunded": "est eiusmod",
"refunds": [
{
"id": "0e4e4db9-b210-1c38-1364-71c05c3453cc",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "7fb8ae38-b06f-b5dc-36de-a0c03e3a085b",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1913-11-22T02:33:32.0Z",
"updated_at": "1908-05-17T21:54:01.0Z"
}
],
"site_id": "a3d2e92f-7c86-03d4-9734-42b4856d0b8e",
"billing_period_from": "1912-01-16",
"billing_period_to": "1949-10-08",
"processing_at": "1945-01-07T15:38:02.0Z",
"created_at": "1907-02-08T01:43:04.0Z",
"updated_at": "1905-02-09T18:16:44.0Z"
}
}
{
"message": "The requested resource could not be found"
}
actionRetryMembershipCharge
This endpoint allows a membership charge to be retried manually.
chargeId
The ID of the charge
{
"data": {
"id": "1c2b9882-3d63-426c-e566-7f2f71963697",
"membership": {
"id": "543e7e81-4d5b-47c3-3efd-a84e4628cc53",
"membership_number": "00000014",
"type_name": "Gold Membership",
"customer_id": "9e884035-54d7-6083-73b2-04e2f45f390d"
},
"processor": "adyen",
"processor_data": {
"last_4": 4001,
"processor_type": "Cash"
},
"amount": 3995,
"original_amount": 3995,
"currency": "gbp",
"tax": 1000,
"status": "succeeded",
"description": "nulla cillum non ipsum fugiat",
"can_download_receipt": false,
"amount_refunded": "in",
"refunded": "ut",
"refunds": [
{
"id": "e45c6822-3e53-4c5f-1a0e-38fbc4e09cc1",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "5fde09a8-65f4-5c17-86ba-94d816dc4e4b",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1917-02-21T06:08:10.0Z",
"updated_at": "1903-03-18T13:09:10.0Z"
},
{
"id": "569ed957-062f-72e1-1e05-4b3f0af97497",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "e63b7290-6104-9444-10cc-5a95887b34de",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1900-05-27T11:12:46.0Z",
"updated_at": "1959-01-11T04:58:13.0Z"
},
{
"id": "c5ea2bf6-b16c-2719-3c95-6ac4158cc26a",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1917-11-20T13:39:16.0Z",
"updated_at": "1897-07-13T01:07:52.0Z"
},
{
"id": "7dd6600f-9574-3844-ca69-82c800363b3e",
"status": "succeeded",
"amount": 995,
"currency": "gbp",
"notes": "Gesture of good will",
"failure_reason": "invalid_details",
"refunded_by": {
"id": "9977a9f7-f958-4f48-78a6-7ce00f2842c1",
"full_name": "Jane Jenkins"
},
"processor_data": {
"processor": "adyen",
"processor_id": "re_64301e0b2df9d11814010ea6"
},
"created_at": "1918-04-15T06:09:19.0Z",
"updated_at": "1943-02-25T19:56:19.0Z"
}
],
"site_id": "c097d989-38a8-380f-3f08-72f9b497443d",
"billing_period_from": "1938-08-09",
"billing_period_to": "1911-08-28",
"processing_at": "1922-01-19T20:33:55.0Z",
"created_at": "1925-06-16T15:35:38.0Z",
"updated_at": "1928-04-28T07:12:23.0Z"
}
}
{
"message": "The requested resource could not be found"
}