v1
latestOpenAPI 3.0.02026-07-141,4077,1665.2 MBFeature Flags
Update a feature flag
Updates an existing feature flag's metadata such as name and description. Does not modify targeting rules or allocations.
put/api/v2/feature-flags/{feature_flag_id}
Path parameters
feature_flag_idstring uuid required
Example:550e8400-e29b-41d4-a716-446655440000
The ID of the feature flag.
Request body
Example request
{
"data": {
"attributes": {
"description": "Updated description for feature flag XYZ789",
"json_schema": "{\"type\": \"object\", \"properties\": {\"enabled\": {\"type\": \"boolean\"}}}",
"name": "Updated Feature Flag XYZ789"
},
"type": "feature-flags"
}
}Response
OK
Example response
{
"data": {
"attributes": {
"archived_at": "2023-01-01T00:00:00Z",
"created_at": "2023-01-01T00:00:00Z",
"created_by": "550e8400-e29b-41d4-a716-446655440010",
"description": "This is an example feature flag for demonstration",
"distribution_channel": "ALL",
"feature_flag_environments": [
{
"default_allocation_key": "allocation-default-123abc",
"default_variant_id": "550e8400-e29b-41d4-a716-446655440002",
"environment_id": "550e8400-e29b-41d4-a716-446655440001",
"environment_name": "env-search-term",
"environment_queries": [
"test-feature-flag",
"env-search-term"
],
"override_allocation_key": "allocation-override-123abc",
"override_variant_id": "550e8400-e29b-41d4-a716-446655440003",
"pending_suggestion_id": "550e8400-e29b-41d4-a716-446655440099",
"status": "ENABLED"
}
],
"json_schema": "{\"type\": \"object\", \"properties\": {\"enabled\": {\"type\": \"boolean\"}}}",
"key": "feature-flag-abc123",
"last_updated_by": "550e8400-e29b-41d4-a716-446655440010",
"name": "Feature Flag ABC123",
"staleness_status": "ACTIVE",
"tags": [],
"updated_at": "2023-01-01T00:00:00Z",
"value_type": "BOOLEAN",
"variants": [
{
"created_at": "2023-01-01T00:00:00Z",
"id": "550e8400-e29b-41d4-a716-446655440002",
"key": "variant-abc123",
"name": "Variant ABC123",
"updated_at": "2023-01-01T00:00:00Z",
"value": "true"
}
]
},
"id": "550e8400-e29b-41d4-a716-446655440000",
"type": "feature-flags"
}
}