Get the audience

SDK platic.campaigns.audience.get()

Read the contacts in a campaign audience, page by page.

Example

await platic.campaigns.audience.get("campaign_123");

Path parameters

ParameterTypeDescriptionRequired
campaignIdstringUnique identifier of the campaignrequired

Query parameters

ParameterTypeDescriptionRequired
limitnumberContacts per page, from 1 to 500. Default: 50—
pageTokenstringThe nextPageToken from the previous page. Send it with the same sortBy, sortDirection, limit, and workspace—
sortByenumField to sort by: lastUpdate (default), creationDate, or name—
sortDirectionenumSort direction: desc (default) or asc—
workspacestringOnly if the credential covers several workspaces: the campaign's workspace. It is required there—

Response

{
  "status": "success",
  "data": [
    {
      "id": "client_abc001",
      "phoneNumber": "521234567890",
      "name": "Ana Smith",
      "firstname": "Ana",
      "lastname": "Smith",
      "email": "ana.smith@example.com",
      "birthdate": null,
      "gender": "female",
      "company": "Acme Inc.",
      "country": "MX",
      "state": "Jalisco",
      "city": "Guadalajara",
      "address": null,
      "postalCode": null,
      "tags": ["campaign-abc123", "Qualified lead"],
      "owners": ["agent@acme.com"],
      "customFields": {},
      "creationDate": "2026-03-02T18:32:28.903Z",
      "lastUpdate": "2026-03-05T16:54:25.221Z"
    },
    {
      "id": "client_abc002",
      "phoneNumber": "529876543210",
      "name": "Carlos Mendoza",
      "firstname": "Carlos",
      "lastname": "Mendoza",
      "email": null,
      "birthdate": null,
      "gender": null,
      "company": null,
      "country": null,
      "state": null,
      "city": null,
      "address": null,
      "postalCode": null,
      "tags": ["campaign-abc123"],
      "owners": [],
      "customFields": {},
      "creationDate": "2026-03-03T10:15:00.000Z",
      "lastUpdate": "2026-03-03T10:15:00.000Z"
    }
  ],
  "nextPageToken": null
}

Response fields

FieldTypeDescription
dataarrayThe contacts on this page
nextPageTokenstring | nullToken to request the next page; null on the last one

Each item in data

FieldTypeDescription
idstringInternal ID of the contact
phoneNumberstringPhone number in international format
namestring | nullFull name of the contact
firstnamestring | nullFirst name of the contact
lastnamestring | nullLast name of the contact
emailstring | nullEmail address
birthdatestring | nullBirth date in ISO 8601
genderstring | nullGender
companystring | nullCompany
countrystring | nullCountry
statestring | nullState
citystring | nullCity
addressstring | nullAddress
postalCodestring | nullPostal code
tagsstring[]The contact's tags (includes the campaign's tag)
ownersstring[]Emails of the users responsible for the contact
customFieldsobjectThe contact's custom fields
creationDatestring | nullCreation date in ISO 8601
lastUpdatestring | nullLast update date in ISO 8601

Errors

Statusdetails.codeWhen
400INVALID_REQUESTA parameter is not valid, the pageToken is not from this list (another order, another limit, or another workspace), or the credential covers several workspaces and workspace is missing or is not one of them (details.available lists the valid ones)
401UNAUTHENTICATEDThe credential is missing or invalid
403FORBIDDENThe credential does not have the Campaigns permission in that workspace
404NOT_FOUNDThe campaign does not exist in the workspace or was deleted
{
  "code": 400,
  "error": "Bad Request - The request has validation errors",
  "details": {
    "code": "INVALID_REQUEST",
    "message": "pageToken does not match the requested filters, sort or limit; restart pagination without it"
  }
}

See Errors for the full shape of an error.