Authorization: Bearer fk_… or the x-api-key header) — API keys are project-admin equivalent. The SDK endpoint (GET /api/flags/:recordId) is the one route that requires an API key. See Authentication for details.
Project, flag, group, record, and environment IDs in these paths are public reference IDs (KSUIDs, ~27 chars) shown in the dashboard — the internal database UUID is not accepted in URLs.
Flags and records resolve against an environment. Pass an optional ?env= query parameter (the environment’s key such as production, or its display name, case-insensitive) on read and check endpoints; when omitted, the project’s default environment is used.
Global Flags
List Flags
GET /api/projects/:projectId/flags
Returns all global feature flags for the project, scoped to an environment.
Path Parameters
Optional environment selector (the environment’s
key or name). Defaults to the project’s default environment; an unknown value returns [].Create Flag
POST /api/projects/:projectId/flags
Creates a new global feature flag.
Path Parameters
Request Body
Optional user-supplied public reference ID (
^[A-Za-z0-9_-]{1,128}$). Stored as-is and must be unique across the project’s flags. When omitted, a KSUID is generated.A unique, URL-friendly identifier for the flag within this project (e.g.,
dark-mode). Defaults to a slug of name when omitted. Must be unique per project and environment.Environment the flag is created in (accepts an environment
key or name). Defaults to the project’s default environment.201 Created
Get Flag
GET /api/projects/:projectId/flags/:flagId
Returns a single global flag by its ID.
Path Parameters
The flag’s public reference ID — a KSUID, or the value you supplied as
id when creating the flag.Update Flag
PUT /api/projects/:projectId/flags/:flagId
Updates a global flag’s name, enabled state, or rollout percentage.
Path Parameters
The flag’s public reference ID — a KSUID, or the value you supplied as
id when creating the flag.Delete Flag
DELETE /api/projects/:projectId/flags/:flagId
Permanently deletes a global flag.
Request
Check Flag
GET /api/projects/:projectId/flags/check/:flagKey
Checks whether a global flag is currently enabled by its key. Useful for server-side flag resolution without going through the SDK.
Path Parameters
Optional environment selector (the environment’s
key or name, case-insensitive). Defaults to the project’s default environment; an unknown value returns 404. Results are cached for 60 seconds in Redis per (project, flagKey, env).enabled already reflects the rollout roll. source is "cache" when served from the Redis cache or "global" when freshly computed.
Flag Groups
Groups are reusable collections of flags that you attach to records (users, orgs, etc.). Each group has its own set of group flags with default values; records in the group can override any flag’s value.List Groups
GET /api/projects/:projectId/groups
Request
Create Group
POST /api/projects/:projectId/groups
Request Body
A 2–5 character lowercase alphanumeric prefix used to namespace auto-generated record IDs in this group (e.g.,
beta). Must be unique per project. Auto-derived from name when omitted.201 Created
Get Group
GET /api/projects/:projectId/groups/:groupId
Request
Update Group
PUT /api/projects/:projectId/groups/:groupId
Request Body
Request
Delete Group
DELETE /api/projects/:projectId/groups/:groupId
Request
Group Flags
Group flags are the individual flags within a group. Each has adefaultEnabled and defaultPercentage that applies to all records unless overridden.
List Group Flags
GET /api/projects/:projectId/groups/:groupId/flags
Request
Create Group Flag
POST /api/projects/:projectId/groups/:groupId/flags
Request Body
Request
201 Created
Group Records
Records represent the entities (users, organizations, devices, etc.) that belong to a group. Each record’sid is either a stable identifier you supply from your own system, or — when you omit it — an auto-generated {groupPrefix}-{ksuid} value (e.g., beta-2a9bX1c0d3e4f5g6h7i8j9k0).
List Records
GET /api/projects/:projectId/groups/:groupId/records
Request
Create Record
POST /api/projects/:projectId/groups/:groupId/records
Adds a record (entity) to the group.
Request Body
Optional stable identifier from your own system (
^[A-Za-z0-9_-]{1,128}$), stored verbatim and unique across all records. When omitted, the server generates {groupPrefix}-{ksuid}. Supplying your own entity ID lets SDK callers resolve flags via GET /api/flags/{yourId} directly.id (e.g. -d '{"name": "Alice"}'); the response id will be {groupPrefix}-{ksuid}.
Response — 201 Created
Environments
Flags and overrides are scoped to environments (e.g.production, staging). Reference an environment by its key or name via the ?env= query parameter on read/check endpoints; omitting it uses the project’s default environment.
List Environments
GET /api/projects/:projectId/environments
Create Environment
POST /api/projects/:projectId/environments
Request Body
Per-Record Overrides
Set or clear an individual record’s value for a group flag in a given environment:PUT /api/projects/:projectId/groups/:groupId/records/:recordId/values/:groupFlagId
GET /api/projects/:projectId/records/:recordId/values.
SDK Endpoint
GET /api/flags/:recordId
Resolves all feature flag values for a given record. This endpoint uses API key bearer auth rather than a session cookie, so you can call it from your backend or edge functions at runtime.
The response maps each group flag key to its resolved value for the specified record and environment, taking per-record overrides into account. enabled is the final decision — the server applies the rollout dice-roll, so a flag that is on but outside the rollout returns enabled: false.
Path Parameters
The ID of the record whose flags you want to resolve — the auto-generated
{groupPrefix}-{ksuid} form or the value you supplied as id. Must belong to the same project as the API key.Optional environment selector (the environment’s
key or name). Defaults to the project’s default environment. If it doesn’t match any environment, environment is null and flags is {}.source is "record" when the value comes from a per-record override, or "group-default" when it falls back to the group flag’s defaultEnabled / defaultPercentage.