Get segments
Learn more about the Segmentation Api to retrieve segment details.
The Get Segments API will retrieve and list existing segments. The response to this API contains list of segments the current user owns or has shared as public.
Request
GET /{tenantId}/segments
Parameter | Required | Description | |
---|---|---|---|
Headers | Authorization
| Yes | Information about authentication access token in the format "Bearer <accessToken> ". For more information, see Authentication API. |
Query | sort | No | Denotes the field that is used to sort the results. |
order | No | Indicates whether the segments are sorted in ascending or descending order. | |
filter | No | The Search API filter conditions against the segment fields. | |
offset | No | The pagination offset. | |
max | No | The maximum results to be displayed in the response. |
Response
{
"total": 123, //total number of segments
"segments": [ // array of full SegmentTO objects
{
"id": "S1",
"label": "Platinum Members",
"lastEvaluationDate": "2000-10-31T01:30:00.000-05:00",
"favorite":true
...
},
{
"id": "S2",
"label": "Small Business owners",
"lastEvaluationDate": "2000-10-31T01:30:00.000-05:00"
...
}
]
}