v1

latestOpenAPI 3.0.02026-07-24161215397.4 KB
Memberships

Get a list of memberships

Retrieve a list of sets of day memberships based on provided filters

Required scopes: flex.community.memberships.read

get/api/v2/organizations/{orgSlug}/memberships

Path parameters

orgSlugstring required

organization slug

Query parameters

_idstring

Filter by membership id. Supports single id (e.g. _id=xxx) or multiple (e.g. _id[$in]=id1,id2).

companystring
Example:603dfbc260f4054084125d30

Filter by company id.

memberstring
Example:603dfbc260f4054084125d33

Filter by member id.

calculatedStatus'not_started' | 'active' | 'expired' | 'not_approved'

The actual membership status calculated by the platform.

Filter by the calculated status of the membership (e.g. active, expired, not_started, not_approved).

locationstring
Example:603dfbc260f4054084125d33

Filter by location id.

planstring

Filter by plan id. Supports single id (e.g. plan=xxx) or multiple (e.g. plan[$in]=id1,id2).

modifiedAtstring
Example:modifiedAt[$gte]=YYYY-MM-DDTHH:mm:ssZ

Filter by the modified date. Supports date comparison filters: $gt, $gte, $lt, $lte

createdAtstring
Example:createdAt[$gte]=YYYY-MM-DDTHH:mm:ssZ

Support date comparison filters: $gt, $gte, $lt, $lte

propertiesstring
Example:properties[customProperty1]=value1

Filter by custom properties. Uses deepObject style in query. Only string values are supported.

$selectstring
Example:recipient,sender

Select fields to return

$cursorNextstring
$cursorPrevstring
$limitnumber

Response

rangeStartnumber
rangeEndnumber
cursorNextstring
cursorPrevstring

Example response

{
  "results": [
    {
      "properties": {
        "customProperty1": "value1",
        "customProperty2": "value2"
      },
      "_id": "603dfbc260f4054084125d30",
      "name": "Private Office",
      "location": "603dfbc260f4054084125d33",
      "plan": "603dfbc260f4054084125d33",
      "company": "603dfbc260f4054084125d33",
      "member": "603dfbc260f4054084125d33",
      "startDate": "2024-01-01T00:00:00Z",
      "endDate": "2024-01-01T00:00:00Z",
      "intervalCount": 6,
      "price": 20,
      "deposit": 5,
      "discount": "603dfbc260f4054084125d33",
      "discountAmount": 5,
      "calculatedDiscountAmount": 5,
      "discountedPrice": 5,
      "contract": "603dfbc260f4054084125d33",
      "source": "admin",
      "createdAt": "2024-04-12T00:00:00.000Z",
      "createdBy": "6080186f490fcf6e0537ec27",
      "modifiedAt": "2024-05-12T00:00:00.000Z",
      "modifiedBy": "6080186f490fcf6e0537ec54"
    }
  ]
}