User Segments
Creates a user segment in the resolved project.
Requires at least Member. Re-fetches via ListUserSegmentsQuery (there is no single-segment query) and locates the new segment by the id returned from CreateUserSegmentCommand so the response reflects exactly what was persisted (e.g. server-assigned condition ids, folded into the public shape via FromDto).
post/api/v1/orgs/{org}/projects/{project}/segments
Request
- Base URL: https://api.featureflip.io
- URL: https://api.featureflip.io/api/v1/orgs/{org}/projects/{project}/segments
- Auth: API key in header Authorization
Path parameters
orgstring required
projectstring required
Request body
Example request
{
"key": "beta-testers",
"name": "Beta Testers",
"description": "Users enrolled in the beta program.",
"conditions": [
{
"attribute": "email",
"operator": "EndsWith",
"values": [
"@acme.com"
],
"negate": false
}
]
}Response
Created
Example response
{
"id": "0197b6a1-3c4d-7e5f-8a6b-7c8d9e0f1a2b",
"key": "beta-testers",
"name": "Beta Testers",
"description": "Users enrolled in the beta program.",
"conditions": [
{
"attribute": "email",
"operator": "EndsWith",
"values": [
"@acme.com"
],
"negate": false
}
],
"createdAt": "2026-06-01T12:00:00Z",
"updatedAt": "2026-06-15T08:30:00Z"
}Changes
No recorded changes to this operation across all 1 revision of this API.