Memberships

A Membership represents a membership belonging to one or more Customers.

Schema

Attributes

  • The ID of the membership

  • The ID of the site this membership belongs to

  • 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
    Nullable

    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

List Memberships

This endpoint lists the Memberships which are associated to the provided site.

Query parameters

  • Filters memberships belonging to the specified customer

  • page
    Optional

    The page to retrieve results from

  • per_page
    Optional

    The number of results to return per page

Responses

  • 200

    The Memberships were successfully retrieved

GET/customers/memberships
200
example response
{
  "data": [
    {
      "id": "a23be437-95e2-cce4-dfd9-dbb28cb8a161",
      "site_id": "45cedbfd-f1ed-a95d-2e21-87379f5c07a5",
      "membership_number": "1234567890",
      "customer": {
        "id": "024ca74d-feda-14c9-6670-71f964a29ccf",
        "first_name": "Jane",
        "last_name": "Doe",
        "full_name": "Jane Doe",
        "phone": "+447900000000",
        "has_password": true,
        "dob": "1940-09-13",
        "brand_id": "d5e414e6-b74e-bad3-2146-8d9e4dae4810",
        "site_id": "e19f1f1b-69fe-c6ba-f64b-7993a697fa3c",
        "stripe_id": "cus_1234567890",
        "express_stripe_id": "cus_1234567890",
        "email": "janedoe@example.com",
        "labels": [
          {
            "id": "fb1aa0e0-af53-f625-09aa-71b03db97459",
            "name": "VIP",
            "color": "ff6634"
          },
          {
            "id": "64051172-dc49-8fb1-5f4e-e714ea440084",
            "name": "VIP",
            "color": "ff6634"
          },
          {
            "id": "2f3b425d-bdf5-fd26-e29a-96b2e6261b8f",
            "name": "VIP",
            "color": "ff6634"
          }
        ],
        "preferred_locale": "en",
        "locked_at": "1911-08-09T04:34:56.0Z",
        "created_at": "1965-10-07T12:01:57.0Z",
        "updated_at": "1893-03-29T12:51:07.0Z",
        "deleted_at": "1946-11-01T06:56:28.0Z",
        "last_active_at": "1930-06-29T22:14:52.0Z",
        "email_verified_at": "1896-09-04T09:17:23.0Z",
        "last_check_in": {
          "checked_in_at": "1946-02-18T09:59:24.0Z",
          "method": "Scanned"
        },
        "avatar_id": "000000-000000-000000-000000",
        "avatar": {
          "id": "f9bdb6c0-4c07-db36-7592-2c36666c1b13",
          "file_name": "super-cool-photo.jpg",
          "mime_type": "image/jpeg",
          "original_url": "https://example.com/media/super-cool-photo.jpg",
          "size": 84256,
          "url": "https://example.com/media/super-cool-photo-thumbnail@2x.jpg"
        },
        "external_ref": "occaecat in fugiat aliqua ex"
      },
      "members": [
        {
          "customer_id": "84c60969-6caf-bed8-4fea-7637bee4a66b",
          "membership_number": "1234567890",
          "is_lead": false
        },
        {
          "customer_id": "e25eb389-81d5-d468-b5e7-582f2cce5196",
          "membership_number": "1234567890",
          "is_lead": true
        },
        {
          "membership_number": "1234567890",
          "is_lead": false
        }
      ],
      "type": {
        "id": "0c557d1c-9d31-8ec9-1c03-884cd8ba8163",
        "name": "Gold tier",
        "description": "Enjoy exclusive benefits as part of being a member in our Gold tier",
        "terms": "proident",
        "brand_id": "a3623c25-a6a0-6825-2370-3c5bd6e572c0",
        "offline_payments": true,
        "disable_confirmation_email": true,
        "private": true,
        "visibility": "public",
        "minimum_start_date": "1897-02-04T17:26:55.0Z",
        "min_members": 2,
        "max_members": 4,
        "rates": [],
        "revenue_schedule": "FREQ=WEEKLY",
        "created_at": "1916-06-30T01:50:23.0Z",
        "updated_at": "1953-09-25T02:27:27.0Z",
        "deleted_at": "1892-08-23T14:22:44.0Z"
      },
      "rate": {
        "id": "a4d3b041-6fd9-9626-429c-c1ecaf41e664",
        "membership_type_id": "e800f538-6bb9-cd19-1cc5-78bfe684b58c",
        "name": "Standard rate",
        "currency": "GBP",
        "price": 5000,
        "joining_fee": 1000,
        "billing_frequency": "P1M",
        "processors": [
          "quis",
          "dolore nostrud amet esse exercitation",
          "magna labore dolor",
          "enim",
          "elit"
        ],
        "default_duration": "P1Y",
        "private": true,
        "created_at": "1957-06-30T02:04:13.0Z",
        "updated_at": "1956-10-04T20:10:51.0Z"
      },
      "status": "needs_attention",
      "source": "import",
      "payment_method": {
        "id": "amet non sunt dolor"
      },
      "start_date": "1895-04-01T01:17:55.0Z",
      "end_date": "1905-04-15T03:15:58.0Z",
      "created_at": "1958-08-26T08:57:32.0Z",
      "basket_id": "6970a77ba643dc0125000076",
      "external_ref": "in anim ut occaecat",
      "attention_reason": "payment_disputed"
    },
    {
      "id": "df97796a-3c70-ac80-eca2-3cd0e8675c20",
      "site_id": "6a14915b-473a-366f-3748-149bf8b57d1d",
      "membership_number": "1234567890",
      "customer": {
        "id": "049c3b58-cba8-8427-a826-a87367937935",
        "first_name": "Jane",
        "last_name": "Doe",
        "full_name": "Jane Doe",
        "phone": "+447900000000",
        "has_password": true,
        "dob": "1918-07-23",
        "brand_id": "7f734756-e37e-141e-945b-35e26717c662",
        "site_id": "bb0c8cff-f127-88be-7548-1177384acf13",
        "stripe_id": "cus_1234567890",
        "express_stripe_id": "cus_1234567890",
        "email": "janedoe@example.com",
        "labels": [
          {
            "id": "477d2b98-9cd1-121c-6a0a-e4ca3c895613",
            "name": "VIP",
            "color": "ff6634"
          },
          {
            "id": "cd79a769-1c66-39d7-8b37-ad86d8479fd8",
            "name": "VIP",
            "color": "ff6634"
          }
        ],
        "preferred_locale": "en",
        "locked_at": "1942-12-22T04:04:45.0Z",
        "created_at": "1939-05-16T15:56:20.0Z",
        "updated_at": "1919-02-10T07:48:30.0Z",
        "deleted_at": "1929-12-08T07:30:18.0Z",
        "last_active_at": "1922-12-07T17:10:10.0Z",
        "email_verified_at": "1966-12-01T01:35:27.0Z",
        "last_check_in": {
          "checked_in_at": "1961-06-02T04:12:11.0Z",
          "method": "Scanned"
        },
        "avatar_id": "000000-000000-000000-000000",
        "avatar": {
          "id": "19cf3a8c-e601-7c8e-f779-fb036c279879",
          "file_name": "super-cool-photo.jpg",
          "mime_type": "image/jpeg",
          "original_url": "https://example.com/media/super-cool-photo.jpg",
          "size": 84256,
          "url": "https://example.com/media/super-cool-photo-thumbnail@2x.jpg"
        },
        "external_ref": "Lorem culpa sunt minim"
      },
      "members": [
        {
          "customer_id": "58b9aab0-e42e-f2c7-d6a0-79ddb7b87982",
          "membership_number": "1234567890",
          "is_lead": false
        },
        {
          "customer_id": "358a4b10-f6d6-365d-59cf-247ee22809dc",
          "membership_number": "1234567890"
        }
      ],
      "type": {
        "id": "e02024af-4a55-8380-a265-7e795980a91d",
        "name": "Gold tier",
        "description": "Enjoy exclusive benefits as part of being a member in our Gold tier",
        "terms": "sit eiusmod voluptate",
        "brand_id": "d77cf4a9-4c98-dacb-bd4c-adc67789a65f",
        "offline_payments": false,
        "disable_confirmation_email": true,
        "private": true,
        "visibility": "link_only",
        "minimum_start_date": "1900-09-30T02:04:56.0Z",
        "min_members": 2,
        "max_members": 4,
        "rates": [
          {
            "id": "20c7dcc7-594e-fa96-0987-3076a659c162",
            "membership_type_id": "1bf5957e-89cc-325e-1269-4e48314d7aab",
            "name": "Standard rate",
            "currency": "GBP",
            "price": 5000,
            "joining_fee": 1000,
            "billing_frequency": "P1M",
            "processors": [
              "occaecat consectetur do aute in",
              "dolore aliqua aute nisi"
            ],
            "default_duration": "P1Y",
            "private": true,
            "created_at": "1910-05-10T13:12:38.0Z",
            "updated_at": "1910-09-29T22:06:05.0Z"
          },
          {
            "id": "c5ed746b-3b02-708c-0bb0-e685f8c750fa",
            "membership_type_id": "fe33d8ef-e8ca-9207-ef3a-be01979d36ae",
            "name": "Standard rate",
            "currency": "GBP",
            "price": 5000,
            "joining_fee": 1000,
            "billing_frequency": "P1M",
            "processors": [
              "Ut in ex et quis"
            ],
            "default_duration": "P1Y",
            "private": true,
            "created_at": "1939-06-23T11:21:23.0Z",
            "updated_at": "1947-12-09T21:58:01.0Z"
          },
          {
            "id": "46bc94e4-1def-c2ca-f9fc-ed51a3941b12",
            "membership_type_id": "3366ac6c-f6d6-6180-a469-58399c11c917",
            "name": "Standard rate",
            "currency": "GBP",
            "price": 5000,
            "joining_fee": 1000,
            "billing_frequency": "P1M",
            "processors": [
              "et ipsum",
              "proident",
              "officia aliquip",
              "deserunt sint velit elit",
              "cillum sint nostrud adipisicing eiusmod"
            ],
            "default_duration": "P1Y",
            "private": true,
            "created_at": "1936-09-29T18:18:01.0Z",
            "updated_at": "1940-03-29T21:23:40.0Z"
          },
          {
            "id": "1277b4c3-15bb-4652-68d4-61ce1e488e86",
            "membership_type_id": "3978c1cf-e983-4231-5690-1a35b27be4b6",
            "name": "Standard rate",
            "currency": "GBP",
            "price": 5000,
            "joining_fee": 1000,
            "billing_frequency": "P1M",
            "processors": [],
            "default_duration": "P1Y",
            "private": true,
            "created_at": "1959-11-27T11:53:31.0Z",
            "updated_at": "1921-07-31T07:59:12.0Z"
          }
        ],
        "revenue_schedule": "FREQ=WEEKLY",
        "created_at": "1939-09-20T23:21:24.0Z",
        "updated_at": "1956-05-27T21:52:43.0Z",
        "deleted_at": "1904-03-19T05:50:53.0Z"
      },
      "rate": {
        "id": "e3d7f7b3-3106-cdfc-5ea9-2efd5f5339a6",
        "membership_type_id": "cf98cc0c-82fc-15ce-70fc-cf9d242d24f1",
        "name": "Standard rate",
        "currency": "GBP",
        "price": 5000,
        "joining_fee": 1000,
        "billing_frequency": "P1M",
        "processors": [
          "non id",
          "dolor irure ex amet ut"
        ],
        "default_duration": "P1Y",
        "private": true,
        "created_at": "1931-10-03T07:30:53.0Z",
        "updated_at": "1923-04-24T10:02:55.0Z"
      },
      "status": "needs_attention",
      "source": "self_signup",
      "basket_id": "6970a77ba643dc0125000077",
      "next_billing_date": "1941-11-28T08:49:38.0Z",
      "next_charge": {
        "id": "cbd2da4a-21c3-2f5e-1da9-7753b8735afc",
        "amount": 3995,
        "currency": "GBP",
        "status": "pending",
        "billing_period_from": "1943-12-28",
        "billing_period_to": "1945-06-01"
      },
      "attention_reason": "payment_outstanding"
    }
  ],
  "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

Show a membership

Use this endpoint to retrieve a Membership by its ID.

Path parameters

Responses

  • 200

    The Membership was successfully retrieved

  • 404

    The resource couldn't be found

GET/customers/memberships/{membershipId}
200
example response
{
  "data": {
    "id": "e96dc6a7-920c-e01f-5906-0aa0bc699b9d",
    "site_id": "102c1d8a-7b34-aa1f-c28e-6d3cdbdd92c8",
    "membership_number": "1234567890",
    "customer": {
      "id": "f6b878d7-b3db-579e-a181-344d7f9dafaf",
      "first_name": "Jane",
      "last_name": "Doe",
      "full_name": "Jane Doe",
      "phone": "+447900000000",
      "has_password": true,
      "dob": "1935-02-04",
      "brand_id": "db2b71fb-042b-44b2-b91b-dad34594482e",
      "site_id": "7ea8499e-2be5-dcfa-4d78-693e7a3a1d69",
      "stripe_id": "cus_1234567890",
      "express_stripe_id": "cus_1234567890",
      "email": "janedoe@example.com",
      "labels": [
        {
          "id": "62f930af-145d-49a3-679b-e58cc50ac7f6",
          "name": "VIP",
          "color": "ff6634"
        }
      ],
      "preferred_locale": "en",
      "locked_at": "1935-05-03T02:32:56.0Z",
      "created_at": "1901-06-27T16:50:44.0Z",
      "updated_at": "1963-02-06T23:40:59.0Z",
      "deleted_at": "1953-02-27T23:32:43.0Z",
      "last_active_at": "1897-04-26T20:11:02.0Z",
      "email_verified_at": "1962-04-27T17:04:25.0Z",
      "last_check_in": {
        "checked_in_at": "1897-02-07T21:27:41.0Z",
        "method": "Scanned"
      },
      "avatar_id": "000000-000000-000000-000000",
      "avatar": {
        "id": "a7cdd4df-1fd2-e742-97ff-b065fecde17f",
        "file_name": "super-cool-photo.jpg",
        "mime_type": "image/jpeg",
        "original_url": "https://example.com/media/super-cool-photo.jpg",
        "size": 84256,
        "url": "https://example.com/media/super-cool-photo-thumbnail@2x.jpg"
      },
      "external_ref": "deserunt labore anim"
    },
    "members": [
      {
        "customer_id": "80208ba5-0fc9-f4c6-1b2a-c1e0bf41e83a",
        "membership_number": "1234567890",
        "is_lead": false
      },
      {
        "customer_id": "17c4853b-bec0-a337-11d9-53c34dca588d",
        "membership_number": "1234567890",
        "is_lead": false
      }
    ],
    "type": {
      "id": "47f67ba7-f089-0cb7-0f73-a339c54a9fd3",
      "name": "Gold tier",
      "description": "Enjoy exclusive benefits as part of being a member in our Gold tier",
      "terms": "ipsum eiusmod Lorem sed sunt",
      "brand_id": "9b29b98f-dfbf-c97c-8089-4ca3b00b992b",
      "offline_payments": true,
      "disable_confirmation_email": true,
      "private": true,
      "visibility": "public",
      "minimum_start_date": "1947-03-22T04:56:14.0Z",
      "min_members": 2,
      "max_members": 4,
      "rates": [
        {
          "id": "9de9602a-4136-2a07-94b1-5cec30004098",
          "membership_type_id": "cdd446ad-f8bb-f8ec-6913-704d048b440b",
          "name": "Standard rate",
          "currency": "GBP",
          "price": 5000,
          "joining_fee": 1000,
          "billing_frequency": "P1M",
          "processors": [
            "ullamco",
            "officia fugiat tempor aliquip",
            "sit ex dolor qui",
            "exercitation"
          ],
          "default_duration": "P1Y",
          "private": true,
          "created_at": "1926-06-13T19:08:20.0Z",
          "updated_at": "1955-01-07T18:33:07.0Z"
        },
        {
          "id": "71640f69-f19b-865e-d5f3-4854e6538ffc",
          "membership_type_id": "5d41ee20-6eec-0d64-8bd5-cf6ad785a562",
          "name": "Standard rate",
          "currency": "GBP",
          "price": 5000,
          "joining_fee": 1000,
          "billing_frequency": "P1M",
          "processors": [],
          "default_duration": "P1Y",
          "private": true,
          "created_at": "1891-09-29T03:41:42.0Z",
          "updated_at": "1958-02-09T21:48:38.0Z"
        },
        {
          "id": "c235719b-87cf-7b62-2647-3f049e211156",
          "membership_type_id": "77981b14-d599-e953-fbb6-cd23e8721600",
          "name": "Standard rate",
          "currency": "GBP",
          "price": 5000,
          "joining_fee": 1000,
          "billing_frequency": "P1M",
          "processors": [
            "consectetur",
            "sunt ut sint"
          ],
          "default_duration": "P1Y",
          "private": true,
          "created_at": "1915-10-31T05:46:24.0Z",
          "updated_at": "1968-03-22T17:22:03.0Z"
        },
        {
          "id": "b4016b31-f684-7ae9-8252-edfaa62fbbce",
          "membership_type_id": "5ccf0817-33d1-ce93-eba7-074479eb1c2a",
          "name": "Standard rate",
          "currency": "GBP",
          "price": 5000,
          "joining_fee": 1000,
          "billing_frequency": "P1M",
          "processors": [
            "dolore occaecat id amet consectetur",
            "anim"
          ],
          "default_duration": "P1Y",
          "private": true,
          "created_at": "1895-01-20T02:38:48.0Z",
          "updated_at": "1968-12-28T17:09:40.0Z"
        },
        {
          "id": "607d476d-b4c9-4c1e-66fa-74a32eaee527",
          "membership_type_id": "d48a0dda-58a9-636a-62da-3173e13cfa2b",
          "name": "Standard rate",
          "currency": "GBP",
          "price": 5000,
          "joining_fee": 1000,
          "billing_frequency": "P1M",
          "processors": [
            "aliquip",
            "consectetur in"
          ],
          "default_duration": "P1Y",
          "private": true,
          "created_at": "1899-11-20T08:45:34.0Z",
          "updated_at": "1943-11-02T15:37:37.0Z"
        }
      ],
      "revenue_schedule": "FREQ=WEEKLY",
      "created_at": "1943-08-14T08:36:58.0Z",
      "updated_at": "1949-06-19T12:58:53.0Z",
      "deleted_at": "1912-06-08T22:40:29.0Z"
    },
    "rate": {
      "id": "093b401e-6680-4304-1cc9-18f0d6df15f6",
      "membership_type_id": "3646ebcd-e277-8100-503d-74be715b0c3d",
      "name": "Standard rate",
      "currency": "GBP",
      "price": 5000,
      "joining_fee": 1000,
      "billing_frequency": "P1M",
      "processors": [
        "ipsum qui",
        "laboris minim aliquip aute dolor"
      ],
      "default_duration": "P1Y",
      "private": true,
      "created_at": "1934-01-02T19:04:38.0Z",
      "updated_at": "1894-01-01T18:42:35.0Z"
    },
    "status": "inactive",
    "source": "unknown",
    "payment_method": {
      "id": "nisi aliquip",
      "type": "direct_debit",
      "last_4": "occaecat dolore ut",
      "status": "revoked"
    },
    "start_date": "1951-01-08T15:17:29.0Z",
    "end_date": "1929-06-26T22:07:49.0Z",
    "created_at": "1969-08-29T18:32:40.0Z"
  }
}
404
example response
{
  "message": "The requested resource could not be found"
}
actionAddMembershipChargePayment

Record a manual payment against a charge

This endpoint allows a manual (off-Trybe) payment to be recorded against a membership charge.

Path parameters

Request body

  • The ID of the custom payment type this payment should be recorded as

  • amount
    Nullable

    The amount of the payment

Responses

  • 200

    A charge against a membership.

  • 404

    The resource couldn't be found

POST/shop/membership-charges/{chargeId}/payment
200
example response
{
  "data": {
    "id": "2247b709-470e-c118-fcce-ca7a20b2cbc5",
    "membership": {
      "id": "3d673f98-6589-e06a-694c-b6f4442eeea6",
      "membership_number": "00000014",
      "type_name": "Gold Membership",
      "customer_id": "2c76265d-dc3d-4675-b843-7776a80c99a5",
      "customer_name": "Jane Jones"
    },
    "processor": "adyen",
    "processor_data": {
      "cardholder_name": "Mrs J Jones",
      "last_4": 4001,
      "processor_type": "Cash"
    },
    "amount": 3995,
    "original_amount": 3995,
    "currency": "gbp",
    "tax": 1000,
    "status": "succeeded",
    "description": "exercitation consequat dolore fugiat",
    "can_download_receipt": true,
    "amount_refunded": -8163219,
    "refunded": false,
    "refunds": [
      {
        "id": "f1c55aa2-8c06-b36e-9a96-c214ab199de2",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "799d7302-da06-83bd-16bc-45ff879ab5d1",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1944-12-01T05:07:10.0Z",
        "updated_at": "1895-08-06T22:44:22.0Z"
      },
      {
        "id": "768c8f78-f74a-99d5-c3aa-afaf7a03e7b4",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "544755e2-334c-8dc6-dbeb-d103a59e4d7f",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1913-05-29T03:19:17.0Z",
        "updated_at": "1932-10-20T05:04:59.0Z"
      },
      {
        "id": "7638b609-9d5e-3028-6c19-8c9daa1dfb7e",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "refunded_by": {
          "id": "1725eb15-f2a1-8f21-58b3-05bdc7879e24",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1947-09-17T01:57:50.0Z",
        "updated_at": "1909-06-30T14:59:47.0Z"
      },
      {
        "id": "41761a12-6488-d162-6a9a-42358956e9f8",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "411e3359-077c-715f-3352-394b6a27ec57",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1947-01-01T13:43:19.0Z",
        "updated_at": "1964-04-11T07:50:22.0Z"
      }
    ],
    "site_id": "7ee2aca0-046d-4279-575c-af4606b087f8",
    "billing_period_from": "1928-12-23",
    "billing_period_to": "1953-11-09",
    "processing_at": "1934-06-08T14:25:15.0Z",
    "created_at": "1908-07-11T13:07:30.0Z",
    "updated_at": "1939-12-20T20:32:32.0Z"
  }
}
404
example response
{
  "message": "The requested resource could not be found"
}
actionProcessMembershipCharge

Manually process a charge for a membership

This endpoint allows a membership charge to be processed manually.

Path parameters

Responses

  • 200

    A charge against a membership.

  • 404

    The resource couldn't be found

POST/shop/membership-charges/{chargeId}/process
200
example response
{
  "data": {
    "id": "1e58ceaf-9f72-d910-e32f-8cb5f6bd7bb4",
    "membership": {
      "id": "59c720dc-01b3-ecaf-b30f-4517a4eabe9d",
      "membership_number": "00000014",
      "type_name": "Gold Membership",
      "customer_id": "5751e793-2c4d-8328-44ec-9d99f5618597",
      "customer_name": "Jane Jones"
    },
    "processor": "adyen",
    "processor_data": {
      "last_4": 4001,
      "processor_type_id": "6970a77ba643dc0125000078"
    },
    "amount": 3995,
    "currency": "gbp",
    "tax": 1000,
    "status": "succeeded",
    "description": "laborum magna ea commodo sint",
    "can_download_receipt": true,
    "amount_refunded": -19501219,
    "refunded": false,
    "refunds": [
      {
        "id": "5f813a90-eedb-20a7-6ede-892d2006138b",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "7001aac8-950e-7e77-e9d7-d4f7bc219856",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1895-12-01T05:04:01.0Z",
        "updated_at": "1962-11-07T13:38:40.0Z"
      }
    ],
    "site_id": "65dfee1b-3502-3b6d-79f6-90de57a2c75c",
    "billing_period_from": "1914-03-10",
    "billing_period_to": "1913-11-17",
    "processing_at": "1956-01-06T15:19:38.0Z",
    "created_at": "1950-01-15T13:08:28.0Z",
    "updated_at": "1965-08-23T21:40:52.0Z"
  }
}
404
example response
{
  "message": "The requested resource could not be found"
}
actionRetryMembershipCharge

Manually retry a charge for a membership

This endpoint allows a membership charge to be retried manually.

Path parameters

Responses

  • 200

    A charge against a membership.

  • 404

    The resource couldn't be found

POST/shop/membership-charges/{chargeId}/retry
200
example response
{
  "data": {
    "id": "f58bd7c0-b254-1b7e-1b1c-1c31b3a32a3f",
    "membership": {
      "id": "0acd075a-d140-4106-0ff6-ba45b1a4bc5e",
      "membership_number": "00000014",
      "type_name": "Gold Membership",
      "customer_id": "abd846ca-3022-9039-656c-096a577e1cc2",
      "customer_name": "Jane Jones"
    },
    "processor": "adyen",
    "processor_data": {
      "last_4": 4001,
      "processor_type": "Cash",
      "processor_type_id": "6970a77ba643dc0125000079"
    },
    "amount": 3995,
    "original_amount": 3995,
    "currency": "gbp",
    "tax": 1000,
    "status": "succeeded",
    "description": "voluptate",
    "can_download_receipt": false,
    "amount_refunded": 6797307,
    "refunded": true,
    "refunds": [
      {
        "id": "897623cc-4455-596b-e5fc-874e8f7d9d36",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "b5c58f56-7259-47db-34da-b3d129f60b0a",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1924-05-14T17:21:15.0Z",
        "updated_at": "1968-07-13T06:18:58.0Z"
      },
      {
        "id": "e0f38569-aa68-d32c-c126-4c75ea97511b",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "365b834b-fd4b-1af2-0982-16c0bae10599",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1896-03-14T18:20:03.0Z",
        "updated_at": "1910-10-07T08:12:07.0Z"
      },
      {
        "id": "e1f9be96-3c4f-eec2-8107-88935625ed41",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "refunded_by": {
          "id": "3d59f3f6-3638-2585-7eb1-449d45f348bc",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1912-07-18T17:17:11.0Z",
        "updated_at": "1946-05-26T06:13:10.0Z"
      },
      {
        "id": "9d606cad-8db0-04d6-c85c-3648a15c597f",
        "status": "succeeded",
        "amount": 995,
        "currency": "gbp",
        "notes": "Gesture of good will",
        "failure_reason": "invalid_details",
        "refunded_by": {
          "id": "c16d1aba-d1b9-ac3b-f26a-0ecc15ce2b79",
          "full_name": "Jane Jenkins"
        },
        "processor_data": {
          "processor": "adyen",
          "processor_id": "re_64301e0b2df9d11814010ea6"
        },
        "created_at": "1929-07-19T09:39:50.0Z",
        "updated_at": "1893-04-25T16:36:17.0Z"
      }
    ],
    "site_id": "86234431-d96c-2d53-a398-0eb430411572",
    "billing_period_from": "1942-12-08",
    "billing_period_to": "1915-07-14",
    "processing_at": "1949-03-06T11:25:40.0Z",
    "created_at": "1951-12-28T21:08:16.0Z",
    "updated_at": "1913-06-13T23:33:44.0Z"
  }
}
404
example response
{
  "message": "The requested resource could not be found"
}