Vincent is here! Just say the word, and Vincent will build the campaigns for you! Get early access.
curl --request GET \
--url https://{cluster}.voucherify.io/v1/customers/{customerId}/segments \
--header 'X-App-Id: <api-key>' \
--header 'X-App-Token: <api-key>'{
"object": "list",
"data_ref": "data",
"data": [
{
"id": "seg_DNAOhUtJffvX0f57ajLMFBYR",
"name": "area code not 123",
"object": "segment"
},
{
"id": "seg_IPIYx96l92Op0Sy5MOaImhgw",
"name": "not bob.smith@email.com",
"object": "segment"
},
{
"id": "seg_1wc52c5z6r1kQ81brO8j9Hk2",
"name": "Birthday After Dec 31",
"object": "segment"
},
{
"id": "seg_ZEbbT4mq1ePpM9PzR02lcww2",
"name": "Start with S",
"object": "segment"
},
{
"id": "seg_WJv55MbzQwnr56ttJ2xUrSgt",
"name": "Loyalty Card",
"object": "segment"
}
],
"total": 5
}Returns the list of segments IDs to which the customer belongs to.
If you pass a customerId which is not stored and recognized by Voucherify as an existing customer in the system, the response will generate a list of segments that the customer would potentialy qualify for if they were to become a customer tracked in the system.
curl --request GET \
--url https://{cluster}.voucherify.io/v1/customers/{customerId}/segments \
--header 'X-App-Id: <api-key>' \
--header 'X-App-Token: <api-key>'{
"object": "list",
"data_ref": "data",
"data": [
{
"id": "seg_DNAOhUtJffvX0f57ajLMFBYR",
"name": "area code not 123",
"object": "segment"
},
{
"id": "seg_IPIYx96l92Op0Sy5MOaImhgw",
"name": "not bob.smith@email.com",
"object": "segment"
},
{
"id": "seg_1wc52c5z6r1kQ81brO8j9Hk2",
"name": "Birthday After Dec 31",
"object": "segment"
},
{
"id": "seg_ZEbbT4mq1ePpM9PzR02lcww2",
"name": "Start with S",
"object": "segment"
},
{
"id": "seg_WJv55MbzQwnr56ttJ2xUrSgt",
"name": "Loyalty Card",
"object": "segment"
}
],
"total": 5
}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.
Unique identifier of a customer represented by an internal customer ID or customer source ID.
"cust_nk0N1uNQ1YnupAoJGOgvsODC"
The method returns segment(s) to which the given customer belongs to.
Response body schema for GET v1/customers/{customerId}/segments.
The type of the object represented by JSON. This object stores information about customer segments.
Identifies the name of the JSON property that contains the array of segment IDs.
A dictionary that contains an array of segment IDs and names.
Show child attributes
Total number of segments the customer belongs to.
Was this page helpful?