Skip to main content

List all audiences

Get the audiences associated with the authorization token.

URL: https://api.courier.com/audiences

Method: GET

Query Parameters

cursorstring
A unique identifier that allows for fetching the next set of audiences

Responses

status: 200 Audiences associated with the `authorization` token.

itemsarray
List of audiences
+ Show Properties
pagingobject
The bulk job user data paging info
+ Show Properties

status: 400 Bad Request

messagestring
A message describing the error that occurred.
typestring
[invalid_request_error] The type of error that occurred.

Request Example

curl --request GET \
--url https://api.courier.com/audiences?cursor=MTU4OTQ5NTI1ODY4NywxLTVlYmRjNWRhLTEwODZlYWFjMWRmMjEwMTNjM2I0ZjVhMA \
--header 'Accept: application/json'

Responses Example

{
"items": [
{
"id": "developer-audience",
"name": "Developer Audience",
"description": "Audience for developers",
"filter": {
"operator": "EQ",
"value": "engineer",
"path": "title"
}
}
],
"paging": {
"cursor": "randomcursor",
"more": true
}
}
{
"message": "filteroperator should be equal to one of the allowed values AND, EQ, GT, GTE, INCLUDES, LT, LTE, NEQ, OMIT, OR",
"type": "invalid_request_error"
}

Example

Method: GET

URL: https://api.courier.com/audiences

Was this helpful?