List segments
curl --request GET \
--url https://api.example.com/api/v2/segmentsimport requests
url = "https://api.example.com/api/v2/segments"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v2/segments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v2/segments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v2/segments"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/v2/segments")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v2/segments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodySegments
List segments
List the reusable filter sets you’ve authored
GET
/
api
/
v2
/
segments
List segments
curl --request GET \
--url https://api.example.com/api/v2/segmentsimport requests
url = "https://api.example.com/api/v2/segments"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v2/segments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v2/segments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v2/segments"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/v2/segments")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v2/segments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyLists the segments (reusable filter sets) owned by the user. Code-side these are
segments; user-facing we call them “segments”.
To create a new segment, see POST /api/v2/segments. To author + attach to a stream in one shot, see POST /api/v2/streams (the pairs field accepts inline segment objects).
Query parameters
| Name | Type | Description |
|---|---|---|
excludeArchived | boolean | Default true - hides archived segments |
Response
{
"segments": [
{
"id": 12,
"userFacingId": "seg_12",
"name": null,
"description": "AI founders building developer tools",
"genderValues": [],
"appliedSearchFilters": { "job_role": ["Founder", "CEO"] },
"followerCountTiers": [],
"linkedStreamCount": 2,
"createdAt": "2026-06-01T10:00:00Z",
"updatedAt": "2026-06-01T10:00:00Z"
}
]
}
Notes
Editing a segment’s filters in place is intentionally NOT exposed on the public API (mutating a segment affects classification across every stream that references it - too easy to get wrong from an integration). Workflow:POST /api/v2/segmentsto create a new segment with the desired filtersPATCH /api/v2/streams/{id}to swap the affected streams’ pairs to use the new segment