v1.0.0
OpenAPI 3.1.0

Get a segment's dependencies

US region

Client Libraries

Get a segment's dependencies

Use this endpoint to find out which automations and newsletters use a segment.

Path Parameters
  • segment_id
    Type: integerFormat: int32
    required

    The identifier for a segment. You can find your segment's ID on its page in the dashboard—go to Segments, select your segment, and find the ID under Usage. Or you can find your segment using the App API.

Responses
  • application/json
  • 404

    The segment_id does not exist.

  • application/json
Request Example for get/v1/segments/{segment_id}/used_by
curl https://api.customer.io/v1/segments/1/used_by \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN'
{
  "segment_id": 7,
  "used_by": {
    "campaigns": [
      1
    ],
    "sent_newsletters": [
      1
    ],
    "draft_newsletters": [
      1
    ]
  }
}