The intercom API reference.
The intercom API reference.
A segment is a group of your contacts defined by the rules that you set.
Type of the contact: contact (lead) or user.
{ "type": "segment", "id": "56203d253cba154d39010062", "name": "Active", "created_at": 1394621988, "updated_at": 1394622004, "person_type": "contact", "count": 3 }
curl -i -X GET \ 'https://api.intercom.io/contacts/{contact_id}/segments' \ -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \ -H 'Intercom-Version: 2.10'
{ "type": "list", "data": [ { … } ] }
curl -i -X GET \ 'https://api.intercom.io/segments?include_count=true' \ -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \ -H 'Intercom-Version: 2.10'
{ "type": "segment.list", "segments": [ { … }, { … } ] }
curl -i -X GET \ 'https://api.intercom.io/segments/{id}' \ -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \ -H 'Intercom-Version: 2.10'
{ "type": "segment", "id": "6657ad3a6abd0166b52ae2e8", "name": "John segment", "created_at": 1717022010, "updated_at": 1717022010, "person_type": "user" }