Environments

Update Organization Environment

Changed on

Update an organization environment’s title, description, color or order. The key slug is frozen at create time — renaming the title never re-derives it. The built-in environments (production / staging) cannot be edited.

Requires Org Owner role. Available on cloud-hosted plans with organizations.

Note: Environment APIs are available only with self-hosted Enterprise plans and cloud-hosted plans. Creating custom environments requires a plan that includes the custom-environments feature.

patch/api/v3/meta/orgs/{orgId}/environments/{environmentId}

Request

Path parameters

orgIdstring required

Organization ID

environmentIdstring required

Environment ID

Request body

titlestring

New environment name. The key slug is NOT re-derived on rename.

descriptionstring

Optional description shown on the environment card / editor

colorstring

Solid color (hex) used for the environment’s dot / badge

ordernumber

Display position among environments. Write-only — it is persisted but is not returned on any environment response.

Example request

{
  "title": "QA Renamed",
  "description": "Pre-release verification",
  "color": "#c2410c",
  "order": 1
}

Response

Updated environment

idstring required

Environment ID. Custom environments use a generated ID; the built-in environments use their reserved key (production / staging).

keystring required

Stable slug auto-derived from the title at create time and frozen thereafter — renaming the title never changes it. Used to reference the environment.

titlestring required

Human-readable environment name

descriptionstring nullable

Optional description shown on the environment card / editor

colorstring nullable

Solid color (hex) used for the environment’s dot / badge

is_defaultboolean required

True only for the built-in production environment — the fallback whose configuration is the integration’s own config.

is_lockedboolean required

True for the built-in environments (production / staging) — they cannot be renamed or deleted.

workspace_idstring

Present on workspace-scoped custom environments. At most one of workspace_id / org_id is set; both are absent on the virtual built-in environments.

org_idstring

Present on organization-scoped environments, which are shared by all of the organization’s workspaces.

created_atstring date-time

Creation timestamp (absent on the virtual built-in environments)

updated_atstring date-time

Last update timestamp (absent on the virtual built-in environments)

created_bystring

ID of the user who created the environment (absent on the virtual built-in environments)

Example response

{
  "id": "envabc12345",
  "key": "qa",
  "title": "QA",
  "description": "Pre-release verification",
  "color": "#6A7184",
  "workspace_id": "w6dw3fo0",
  "org_id": "org123",
  "created_by": "usr1234567"
}

Changes