Skip to main content
GET
/
v1
/
segments
List segments
curl --request GET \
  --url https://{cluster}.voucherify.io/v1/segments \
  --header 'X-App-Id: <api-key>' \
  --header 'X-App-Token: <api-key>'
{
  "object": "list",
  "data_ref": "data",
  "data": [
    {
      "id": "seg_5ix74s3gM3N7",
      "name": "Customers with placed order",
      "created_at": "2023-08-03T10:37:49.285Z",
      "updated_at": null,
      "type": "auto-update",
      "filter": {
        "junction": "and",
        "events.payment_placed.count": {
          "conditions": {
            "$more_than": [
              "0"
            ]
          }
        }
      },
      "object": "segment"
    },
    {
      "id": "seg_fi47Ds3gM3N7",
      "name": "Newsletter subscribers",
      "created_at": "2023-08-03T10:37:49.264Z",
      "updated_at": null,
      "type": "auto-update",
      "filter": {
        "junction": "and",
        "events.newsletter_subscribed.count": {
          "conditions": {
            "$more_than": [
              "0"
            ]
          }
        }
      },
      "object": "segment"
    },
    {
      "id": "seg_f0r4hs3gM3N7",
      "name": "Reviewers",
      "created_at": "2023-08-03T10:37:49.244Z",
      "updated_at": null,
      "type": "auto-update",
      "filter": {
        "junction": "and",
        "events.review_left.count": {
          "conditions": {
            "$more_than": [
              "0"
            ]
          }
        }
      },
      "object": "segment"
    },
    {
      "id": "seg_t4ir0Ds3gM3N7",
      "name": "Sign up customers",
      "created_at": "2023-08-03T10:37:49.225Z",
      "updated_at": null,
      "type": "auto-update",
      "filter": {
        "junction": "and",
        "events.sign_up.count": {
          "conditions": {
            "$more_than": [
              "0"
            ]
          }
        }
      },
      "object": "segment"
    }
  ],
  "total": 99
}

Documentation Index

Fetch the complete documentation index at: https://docs.voucherify.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-App-Id
string
header
required
X-App-Token
string
header
required

Query Parameters

limit
integer

Limits the number of objects to be returned. The limit can range between 1 and 100 items. If no limit is set, it returns 10 items.

Required range: 1 <= x <= 100
order
enum<string>

Apply this filter to order the segments according the date and time when they were created. By default, lists the segments from the newest to the oldest. Use created_at to list from the oldest to the newest.

Available options:
created_at,
-created_at
filters
object

Filters for listing templates.

ids
string[]

Contains the list of segments in the sequence defined by the order parameter.

Response

200 - application/json

Returns a data array with segment objects.

Response body schema for GET v1/segments.

object
enum<string>
default:list
required

The type of the object represented by JSON. This object stores information about segments.

Available options:
list
data_ref
enum<string>
default:data
required

Identifies the name of the attribute that contains the array of segments.

Available options:
data
total
integer
required

Total number of segments returned for given filters and query parameters with the exception of limit.

segments
Segment · object[]

An array of segment objects. Returns an empty array if there are no results matching query parameters.

Last modified on May 4, 2026