Get all activities with optional site filtering

GET /api/configuration/activities

Success: 200 OK

Overview

Lists the activities configured across the estate — the bookable things a member can take part in, such as a swim, a badminton court hire or a fitness class — optionally narrowed to particular sites. For most booking integrations this is the first call you make: it is how you discover the activity identifiers that every later availability and booking call is built on.

Activity identifiers are tenant-specific and operator-chosen. They are short strings such as SWIM or BADMINTON, defined by whoever configured the system, not codes from a Gladstone-wide list. They differ between customers and between environments, so read them from here at runtime rather than hard-coding them or copying them from a test system. The same applies to siteId.

An empty result is a 200, never a 404. Filtering by a site that does not exist returns []; so does a tenant with nothing configured. There is no error to distinguish "you asked for the wrong site" from "this site has no activities", so validate site identifiers against the sites endpoint if that distinction matters to you.

Watch the field names. name is the activity's short label and description is its longer text, so do not assume description is the short one.

Changes to activity configuration can take a moment to appear: a read taken moments after a change can still return the previous data, whether or not you filter by site.

This endpoint is operator-scoped: a member token is rejected with 403 rather than returning a filtered view.

Endpoint

GET {base_url}/api/configuration/activities

{base_url} is the environment URL issued to your integration. See Authenticating with Gladstone APIs.

Query parameters

NameTypeRequiredDescription
siteidsstringNoA comma-separated list of site identifiers to restrict the results to — for example siteids=NORTH,SOUTH. Whitespace around each entry is trimmed and matching is case-insensitive, so nOrtH and north both work. Sites that do not exist are ignored rather than rejected, so a list mixing real and unreal sites returns the activities of the real ones. Omit the parameter entirely to get every activity from every site. Do not send it empty: siteids= is treated as a filter for one site whose identifier is the empty string, which matches nothing and returns [] — quite different from omitting it.

Sample request

cURL
curl -X GET '{base_url}/api/configuration/activities' \
  -H 'Authorization: Bearer {accessToken}' \
  -H 'X-Use-SSO: true'

Response fields

FieldTypeDescription
[].idstringThe activity identifier, and the value every booking call expects when it asks for an activity. Up to 15 characters, always returned upper-cased, chosen by the operator and unique within the tenant rather than globally — never carry one between customers or environments. Each activity belongs to exactly one site, so the same activity run at several sites appears as several entries with different identifiers; pair id with siteId when you store it.
[].namestringThe activity's short label, suitable for a list or a button — this is the one to show in a selector.
[].descriptionstringThe longer explanatory text about the activity, for a detail panel rather than a list. It can be null or empty when the operator has not filled it in, so do not rely on it being present.
[].siteIdstringThe site this activity belongs to, in the site's own casing rather than the lower-cased form used for filtering. Use it to group results when you have asked for several sites at once, and as the value to send back to siteids.
[].translationsarray of objectLocalised versions of the activity's text, one entry per translated field and culture. Returned as an empty array, not null, when the activity has no translations, so you can iterate without a null check. Only cultures that have actually been translated appear — there is no placeholder entry for the rest, so fall back to name and description.
[].translations[].TypestringWhich piece of text this entry translates. Note the capital T — this one field is returned in Pascal case while its siblings are camel case, so a case-sensitive parser needs to allow for it.
[].translations[].culturestringThe culture code the translated text is for, matching the codes configured in the tenant's cultures list. Pick the entry matching your user's culture; if none matches, use the untranslated name and description.
[].translations[].textstringThe translated text itself, to be shown in place of the field named by Type when the user is in the matching culture.

Sample response

200 OK
[
  {
    "id": "string",
    "name": "string",
    "description": "string",
    "siteId": "string",
    "translations": [
      {
        "Type": "string",
        "culture": "string",
        "text": "string"
      }
    ]
  }
]

Errors

StatusMeaningWhen
403ForbiddenThe token is a member token rather than an operator or partner one. This endpoint has no member-facing view.
500Internal server errorThe activities or their translations could not be retrieved. The body is empty. Note that nothing about siteids can cause an error — unrecognised sites are silently ignored.

This page as markdown · All pages · llms.txt