Skip to main content
GET
Get a segment

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string<uuid>
required

The ID of the saved segment

Example:

"0198a123-4567-7890-abcd-ef0123456789"

Response

The requested Segment

A saved set of rules that selects contacts. Membership is worked out each time the segment is used. Optional fields with no value are left out of responses. Lists page with cursor: pass the previous page's next_cursor until there is none.

id
string
required
read-only

Unique identifier for the segment

Example:

"0198a123-4567-7890-abcd-ef0123456789"

workspace_id
string
required
read-only

Workspace that owns the segment

Example:

"0198a123-4567-7890-abcd-ef0123456788"

name
string
required

Name of the segment, up to 150 characters

Required string length: 1 - 150
Example:

"Active trial users"

description
null | string
required

Description, up to 500 characters, or null when unset

Required string length: 1 - 500
Example:

"Signed up in the last 30 days"

definition
object
required

Rules that select contacts. A contact matches when it matches every clause of at least one group. A definition that compiles to more than 4 KB gives 400; keep long value lists short.

segment_type
enum<string>
required
read-only

Always dynamic: membership is worked out when the segment is used

Available options:
dynamic
Example:

"dynamic"

schema_version
enum<integer>
required
read-only

Version of the definition format

Available options:
1
Example:

1

revision
integer
required
read-only

Current revision; send it as expected_revision when updating

Required range: x >= 1
Example:

1

timestamp_created
string<date-time>
required
read-only

Timestamp when the segment was created

Example:

"2026-11-24T11:57:07.732Z"

timestamp_updated
string<date-time>
required
read-only

Timestamp when the segment was last updated

Example:

"2026-11-24T11:57:07.732Z"

created_by
string
required
read-only

ID of the user who created the segment, or api_key

Example:

"0198a123-4567-7890-abcd-ef0123456787"

updated_by
string
required
read-only

ID of the user who last updated the segment, or api_key

Example:

"0198a123-4567-7890-abcd-ef0123456787"