Skip to main content
POST
/
v1
/
projects
/
{projectId}
/
environments
/
{envId}
/
flags
/
{flagKey}
/
proposals
curl -X POST https://nest.feather.mupeni.dev/v1/projects/proj_01hx.../environments/env_01hx.../flags/new-checkout/proposals \
  -H "Authorization: Bearer <server_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "version": 3,
    "enabled": true,
    "defaultValue": false,
    "rules": [
      {
        "id": "rule-1",
        "name": "All users",
        "enabled": true,
        "conditionOperator": "AND",
        "conditions": [],
        "value": true
      }
    ]
  }'
{
  "id": "prop_01hx...",
  "flagId": "flag_01hx...",
  "environmentId": "env_01hx...",
  "status": "pending",
  "proposedConfig": { ... },
  "createdBy": "key_01hx...",
  "createdAt": "2024-04-10T14:00:00.000Z"
}
Only valid for protected environments. Requires Enterprise plan. Only one pending proposal can exist per flag + environment at a time.

Proposal lifecycle

pending ──approve──▶ approved  (flag version created, edge cache updated)
        ──reject───▶ rejected
approved and rejected are terminal — neither can be re-opened. To make another change to a protected environment after a proposal is resolved, create a new proposal.

Path parameters

projectId
string
required
envId
string
required
flagKey
string
required

Body

Same shape as Update Flag Config body.
version
number
required
The current latest version of the flag config in this environment. Recorded as the proposal’s intended base so reviewers can see what the change is based on. The actual stored version is assigned at approval time (always latest + 1) — this field is not used as a concurrency gate.
enabled
boolean
required
defaultValue
boolean | string | number
required
rules
Rule[]
required
variants
Variant[]
curl -X POST https://nest.feather.mupeni.dev/v1/projects/proj_01hx.../environments/env_01hx.../flags/new-checkout/proposals \
  -H "Authorization: Bearer <server_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "version": 3,
    "enabled": true,
    "defaultValue": false,
    "rules": [
      {
        "id": "rule-1",
        "name": "All users",
        "enabled": true,
        "conditionOperator": "AND",
        "conditions": [],
        "value": true
      }
    ]
  }'
{
  "id": "prop_01hx...",
  "flagId": "flag_01hx...",
  "environmentId": "env_01hx...",
  "status": "pending",
  "proposedConfig": { ... },
  "createdBy": "key_01hx...",
  "createdAt": "2024-04-10T14:00:00.000Z"
}