flags

Embed
Preview of the card
<a href="https://lucidace.com/docs/ref-flags"><img src="https://lucidace.com/docs/_api/public/orgs/af34862a-c837-4478-8335-0505efe40459/spaces/da916cd3-c0fc-4b63-b971-b3c13623daf3/pages/b5c3688b-7e55-4666-be20-ed9c5f8c72a6/social-card.svg?v=3e7ae33eec8b" alt="flags" width="600" height="315"></a>
GEThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/impactScope flag:read insight:read

Parameters

project_idstringpathrequired
idstringpathrequired
metric_idstringquery
eventstringquery
daysintegerquery

Code samples

cURL
curl -X GET "https://lucidace.com/v1/projects/{project_id}/flags/{id}/impact"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200
Example
{
  "flag": "string",
  "query": {},
  "result": {
    "columns": [
      "string"
    ],
    "meta": {
      "bytes_read": 0,
      "cache_hit": true,
      "cache_key": "string",
      "clamped_range": true,
      "computed_at": "2024-01-01T00:00:00Z",
      "execution_ms": 0,
      "next_allowed_client_refresh": "2024-01-01T00:00:00Z",
      "rows_read": 0,
      "sampled": true,
      "sql_hash": "string"
    },
    "rows": [
      [
        {}
      ]
    ]
  }
}
Schema
flagstringrequired
queryobjectrequired
The trends query that produced result (open it as an insight).
resultobjectrequired
Rows: series, period, bucket, bd_0 (variant), value.
Show child parameters
columnsstring[]required
metaobjectrequired
Show child parameters
bytes_readinteger
Bytes ClickHouse read, like rows_read.
cache_hitbooleanrequired
cache_keystringrequired
Stable hash of the cache key (project, SQL, timezone, canonical query).
clamped_rangebooleanrequired
computed_atstringrequired
When the result was computed (last_refresh).
execution_msinteger
Wall time of the ClickHouse call; None on a cache hit.
next_allowed_client_refreshstringrequired
Before this, refresh: "force_*" recomputes but the dashboards' auto refresh serves the cache.
rows_readinteger
Rows ClickHouse read (its X-ClickHouse-Summary header); None when not reported.
sampledbooleanrequired
sql_hashstringrequired
rowsobject[][]required
400
404
POSThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/killScope flag:write

One-click off: sets `kill_switch` in the base filters and every environment override, bypassing approvals (emergency path; the change is still versioned, audited and pushed as `flag.killed`).

Parameters

project_idstringpathrequired
idstringpathrequired

Request body

application/json
activeboolean
reasonstring
Why (rollback / incident reason); stored on the history row and the audit entry.
{
  "active": true,
  "reason": "string"
}

Code samples

cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/flags/{id}/kill" \
  -H "Content-Type: application/json" \
  -d '{"active":true,"reason":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200
Example
{
  "created_at": "2024-01-01T00:00:00Z",
  "created_by": "string",
  "description": "string",
  "enabled": true,
  "environment_state": {},
  "expires_at": "2024-01-01T00:00:00Z",
  "filters": {},
  "holdout_id": "string",
  "id": "string",
  "key": "string",
  "kind": "string",
  "lifecycle": "string",
  "name": "string",
  "namespace_id": "string",
  "owner_user_id": "string",
  "payloads": {},
  "protected_envs": [
    "string"
  ],
  "stickiness": "string",
  "tags": [
    "string"
  ],
  "updated_at": "2024-01-01T00:00:00Z",
  "variants": {},
  "version": 0
}
Schema
created_atstringrequired
created_bystring
descriptionstringrequired
enabledbooleanrequired
environment_stateobjectrequired
expires_atstring
filtersobjectrequired
holdout_idstring
idstringrequired
keystringrequired
kindstringrequired
lifecyclestringrequired
draft | active | launched | deprecated (advisory; stale detection surfaces the last two).
namestringrequired
namespace_idstring
owner_user_idstring
payloadsobjectrequired
protected_envsstring[]required
stickinessstringrequired
tagsstring[]required
updated_atstringrequired
variantsobjectrequired
versionintegerrequired
403
404
GEThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/linksScope flag:read

Parameters

project_idstringpathrequired
idstringpathrequired

Code samples

cURL
curl -X GET "https://lucidace.com/v1/projects/{project_id}/flags/{id}/links"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200
Example
{
  "data": [
    {
      "created_at": "2024-01-01T00:00:00Z",
      "created_by": "string",
      "external_key": "string",
      "id": "string",
      "kind": "string",
      "object_id": "string",
      "object_type": "string",
      "title": "string",
      "url": "string"
    }
  ],
  "templated": [
    {
      "kind": "string",
      "template_id": "string",
      "title": "string",
      "url": "string"
    }
  ]
}
Schema
dataResourceLink[]required
Show child parameters
created_atstringrequired
created_bystring
external_keystring
Issue key when the link was created by filing an issue (e.g. ENG-12).
idstringrequired
kindstringrequired
jira | linear | github | gitlab | docs | other
object_idstringrequired
object_typestringrequired
titlestringrequired
urlstringrequired
templatedTemplated[]required
Show child parameters
kindstringrequired
template_idstringrequired
titlestringrequired
urlstringrequired
404
POSThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/linksScope flag:write

Parameters

project_idstringpathrequired
idstringpathrequired

Request body

application/json
kindstringrequired
jira | linear | github | gitlab | docs | other
titlestringrequired
urlstringrequired
An http(s) URL.
{
  "kind": "string",
  "title": "string",
  "url": "string"
}

Code samples

cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/flags/{id}/links" \
  -H "Content-Type: application/json" \
  -d '{"kind":"string","title":"string","url":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201
Example
{
  "created_at": "2024-01-01T00:00:00Z",
  "created_by": "string",
  "external_key": "string",
  "id": "string",
  "kind": "string",
  "object_id": "string",
  "object_type": "string",
  "title": "string",
  "url": "string"
}
Schema
created_atstringrequired
created_bystring
external_keystring
Issue key when the link was created by filing an issue (e.g. ENG-12).
idstringrequired
kindstringrequired
jira | linear | github | gitlab | docs | other
object_idstringrequired
object_typestringrequired
titlestringrequired
urlstringrequired
400
403
404
POSThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/links/issueScope flag:write

Parameters

project_idstringpathrequired
idstringpathrequired

Request body

application/json
bodystring
connection_idstringrequired
A project issue tracker connection (Settings, Issue trackers).
titlestringrequired
{
  "body": "string",
  "connection_id": "string",
  "title": "string"
}

Code samples

cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/flags/{id}/links/issue" \
  -H "Content-Type: application/json" \
  -d '{"body":"string","connection_id":"string","title":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

400
403
404
422
PUThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/purposeScope flag:write

Set or clear one flag's purpose.

Parameters

project_idstringpathrequired
idstringpathrequired

Request body

application/json
purposestring
One of the purposes, or null to clear.
{
  "purpose": "string"
}

Code samples

cURL
curl -X PUT "https://lucidace.com/v1/projects/{project_id}/flags/{id}/purpose" \
  -H "Content-Type: application/json" \
  -d '{"purpose":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 {purpose}
400
403
404
GEThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/releaseScope flag:read

Parameters

project_idstringpathrequired
idstringpathrequired

Code samples

cURL
curl -X GET "https://lucidace.com/v1/projects/{project_id}/flags/{id}/release"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200
Example
{
  "awaiting_cr": "string",
  "baseline": {},
  "created_at": "2024-01-01T00:00:00Z",
  "current_phase": 0,
  "flag_id": "string",
  "id": "string",
  "paused_reason": "string",
  "phase_applied_at": "2024-01-01T00:00:00Z",
  "phases": [
    {}
  ],
  "pipeline_id": "string",
  "project_id": "string",
  "started_by": "string",
  "status": "string",
  "updated_at": "2024-01-01T00:00:00Z"
}
Schema
awaiting_crstring
Change request the next phase waits on.
baselineobjectrequired
{env: {enabled, filters}} at start: what a rollback restores.
created_atstringrequired
current_phaseintegerrequired
Index of the last applied phase (-1 = none yet).
flag_idstringrequired
idstringrequired
paused_reasonstring
Why the automation paused (guardrail breach or a person).
phase_applied_atstring
When the current phase went live (the automation's hold counts from here).
phasesobject[]required
Copy of the pipeline's phases taken at start.
pipeline_idstring
project_idstringrequired
started_bystring
statusstringrequired
active | paused | completed | aborted | rolled_back
updated_atstringrequired
404 the flag never had a release
POSThttps://lucidace.com/v1/projects/{project_id}/flags/{id}/releaseScope flag:write

Parameters

project_idstringpathrequired
idstringpathrequired

Request body

application/json
pipeline_idstringrequired
{
  "pipeline_id": "string"
}

Code samples

cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/flags/{id}/release" \
  -H "Content-Type: application/json" \
  -d '{"pipeline_id":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

403
404
409

Updated