Get all data processing campaigns

GET /api/configuration/consent/data-processing

Success: 200 OK

Overview

Lists the data processing campaigns configured for the tenant. A data processing campaign is a named purpose for which the operator processes member data, and against which a member records a consent decision. Use it to build the consent screen, and to learn the campaignId values the member consent endpoints will accept.

Three things to know before you build against it:

Campaigns the operator has flagged as hidden are excluded from every response regardless of onlyActive, so this endpoint cannot be used to enumerate them.

A campaign the operator has just added or deactivated may not appear immediately. Campaign ids are operator-defined, not platform constants — see [].campaignId.

Endpoint

GET {base_url}/api/configuration/consent/data-processing

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

Query parameters

NameTypeRequiredDescription
onlyActivebooleanNoFilters the list on the campaign's active flag, and matches the flag rather than switching the filter on and off. true returns only active campaigns; false returns only inactive ones. Omit the parameter to return both — this is the only way to get the full list. It takes no account of expiryDate: an active campaign whose expiry date has passed is still returned by onlyActive=true.

Sample request

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

Response fields

FieldTypeDescription
[].campaignIdstringThe campaign's identifier, and the value you send to the member consent endpoints. It is unique within your tenant. Up to 16 characters, and already trimmed by this endpoint, so you receive "NEWSLETTER" rather than a padded string — unlike the communication channels list, which is not trimmed. Operator-defined per tenant: campaigns are created by the operator, so an id present in one tenant may be absent or mean something different in another. Never hard-code one.
[].campaignNamestringThe campaign's short label, for use as the heading of a consent option. Maximum 50 characters. Nullable, so it can be null while campaignId is populated — fall back to campaignId when rendering. It must be unique at the point of creation (the create endpoint rejects a name already in use), but nothing stops it being edited into a duplicate afterwards, so do not treat it as a key.
[].campaignDescriptionstringThe longer explanation of what the member is consenting to, shown as the body text of the consent option. Maximum 1024 characters. Nullable and frequently empty — a consent screen that renders nothing when it is absent will show an unlabelled checkbox, so plan a fallback.
[].expiryDatestring (date-time)The date and time after which the operator considers the campaign to have lapsed. null when no expiry is set, which is the common case. Purely informational here: the endpoint does not compare it against the current time, does not clear isActive when it passes, and onlyActive=true will happily return a campaign whose expiry date is in the past. If expiry matters to your consent flow you must evaluate this field yourself.
[].isActivebooleanWhether the operator currently has the campaign switched on, and the field onlyActive filters against. Always present. false means the operator has retired the campaign but not deleted it — existing member consents against it are untouched, so you can still receive consent records referencing an inactive campaign. Do not offer inactive campaigns as new consent options, but do keep handling them when reading a member's existing consents.
[].protectedbooleanAlways false on this endpoint, so its value carries no information. Campaigns do have a system flag, but it is not exposed here. Do not use this field to decide whether a campaign may be edited or deleted.
[].translationsarray of objectLocalised overrides for the campaign's text, one entry per culture and per translated property. Always present, and an empty array when the operator has provided no translations — which is the default, so most tenants return [] here. Prefer the entry matching the user's culture and fall back to campaignName and campaignDescription. Do not assume every culture returned by the cultures list has an entry; translations are added one at a time.
[].translations[].typestringWhich property of the campaign this entry translates — the name, the description, and so on. The exact set of property names in use is whatever the operator's translation records contain, so match against the values you actually receive rather than a fixed list, and skip entries whose type you do not recognise.
[].translations[].culturestringThe culture this text is for, matching a code from the available cultures list — the value always resolves to a real culture. Up to 20 characters, and in the same lower-case form as that endpoint returns (en-gb, cy-gb), which is not the mixed-case form a browser sends in Accept-Language. Lower-case both sides before matching.
[].translations[].textstringThe translated text itself, replacing whichever property type names. No length limit. Never null within an entry — an untranslated property has no entry at all rather than an entry with empty text.

Sample response

200 OK
[
  {
    "campaignId": "string",
    "campaignName": "string",
    "campaignDescription": "string",
    "expiryDate": "2026-08-14T19:00:00Z",
    "isActive": true,
    "protected": true,
    "translations": [
      {
        "type": "string",
        "culture": "string",
        "text": "string"
      }
    ]
  }
]

Errors

StatusMeaningWhen
500Internal server errorAny unexpected server-side failure while reading the campaigns. The response is a bare status code with no body, so there is no detail to branch on. Retry with backoff.

This page as markdown · All pages · llms.txt