Create a geo-segment
Create a draft geo-segment for a domain. The first segment created becomes the catch-all default. Requires a write-scoped key.
Authorization
bearerAuth Your al_live_<prefix>_<secret> API key. Mint and manage keys in the dashboard.
In: header
Path Parameters
The domain hostname.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/admin/segments/string" \ -H "Content-Type: application/json" \ -d '{ "name": "Tier 1", "countries": [ "US", "GB", "CA" ], "is_default": false, "lang": "en" }'{ "segment_id": "s_1a2b3c4d", "domain": "links.creator.com", "name": "Tier 1", "countries": [ "US", "GB", "CA" ], "position": 0, "is_default": false, "match": null, "ab": null, "lang": "en"}{ "detail": { "code": "invalid_request", "message": "Invalid value for field." }}{ "detail": "auth required"}{ "detail": { "code": "domain_not_found", "message": "Domain not found" }}List geo-segments for a domain
List the draft geo-segments for a domain, ordered by position. A segment buckets visitors by country (with optional device/OS/time/language conditions) and owns an ordered button stack. Requires a read-scoped key.
Update a geo-segment
Update a draft segment's name, countries, default flag, conditions, A/B, or language. Only provided fields change. Exactly one default segment is always enforced. Requires a write-scoped key.