approvals

Embed
Preview of the card
<a href="https://lucidace.com/docs/ref-approvals"><img src="https://lucidace.com/docs/_api/public/orgs/af34862a-c837-4478-8335-0505efe40459/spaces/da916cd3-c0fc-4b63-b971-b3c13623daf3/pages/f44b3eae-684c-499c-b9e8-e99890145698/social-card.svg?v=3e7ae33eec8b" alt="approvals" width="600" height="315"></a>
GEThttps://lucidace.com/v1/projects/{project_id}/approval-policyScope settings:read

Parameters

project_idstringpathrequired

Code samples

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

Responses

200
Example
{
  "required": [
    "string"
  ],
  "rules": {}
}
Schema
requiredstring[]required
Policy keys that need approval: cohort.delete, dashboard.delete, experiment.start, experiment.pause, experiment.stop, experiment.update (split or variant change after launch), flag.release (every release pipeline phase), flag.enable, flag.disable, flag.rollout (rollout-only edits), flag.conditions (targeting edits), flag.variants, experiment.custom_code (per-variant custom CSS/JS or HTML in a web experiment), segment.update (editing or scheduling a saved flag segment).
rulesobject
Per-key rule; keys without one use the default (one admin, 7 days, any change).
404
PUThttps://lucidace.com/v1/projects/{project_id}/approval-policyScope admin

Parameters

project_idstringpathrequired

Request body

application/json
requiredstring[]required
Policy keys that need approval: cohort.delete, dashboard.delete, experiment.start, experiment.pause, experiment.stop, experiment.update (split or variant change after launch), flag.release (every release pipeline phase), flag.enable, flag.disable, flag.rollout (rollout-only edits), flag.conditions (targeting edits), flag.variants, experiment.custom_code (per-variant custom CSS/JS or HTML in a web experiment), segment.update (editing or scheduling a saved flag segment).
rulesobject
Per-key rule; keys without one use the default (one admin, 7 days, any change).
{
  "required": [
    "string"
  ],
  "rules": {}
}

Code samples

cURL
curl -X PUT "https://lucidace.com/v1/projects/{project_id}/approval-policy" \
  -H "Content-Type: application/json" \
  -d '{"required":["string"],"rules":{}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

400
403
404
POSThttps://lucidace.com/v1/projects/{project_id}/approvals

Parameters

project_idstringpathrequired

Request body

application/json
actionstringrequired
delete
resource_idstringrequired
subjectstringrequired
cohort | dashboard
{
  "action": "string",
  "resource_id": "string",
  "subject": "string"
}

Code samples

cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/approvals" \
  -H "Content-Type: application/json" \
  -d '{"action":"string","resource_id":"string","subject":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201
Example
{
  "applied_version": 0,
  "approvals": [
    {}
  ],
  "base_version": 0,
  "created_at": "2024-01-01T00:00:00Z",
  "environment": "string",
  "experiment_id": "string",
  "expires_at": "2024-01-01T00:00:00Z",
  "failure_reason": "string",
  "flag_id": "string",
  "id": "string",
  "policy_key": "string",
  "project_id": "string",
  "proposal": {},
  "quorum": 0,
  "requested_by": "string",
  "review_note": "string",
  "reviewed_at": "2024-01-01T00:00:00Z",
  "reviewed_by": "string",
  "status": "string",
  "subject": "string"
}
Schema
applied_versioninteger
approvalsobject[]required
[{user_id, note, at}], one entry per approver so far.
base_versioninteger
Flag version the request was made against; apply fails when the flag moved on.
created_atstringrequired
environmentstring
experiment_idstring
expires_atstring
Pending or approved requests past this instant expire unused.
failure_reasonstring
Why a failed request could not be applied.
flag_idstring
idstringrequired
policy_keystring
The approval-policy key whose rule governs this request (flag.rollout, ...).
project_idstringrequired
proposalobjectrequired
quorumintegerrequired
Approvals needed before the request counts as approved.
requested_bystring
review_notestring
reviewed_atstring
reviewed_bystring
statusstringrequired
subjectstringrequired
400
403
404
Updated