v7

latestOpenAPI 3.0.3raw.githubusercontent.com2026-08-013764062.2 MB
Environments

Get the environments available to a project

Gets the environments that are available for this project. An environment is available for a project if enabled in the project configuration

get/api/admin/environments/project/{projectId}

Path parameters

projectIdstring required

Response

environmentsProjectSchema

versioninteger required

Version of the environments schema

Example response

{
  "version": 1,
  "environments": [
    {
      "name": "development",
      "type": "production",
      "enabled": true,
      "sortOrder": 1,
      "projectApiTokenCount": 5,
      "projectEnabledToggleCount": 7,
      "defaultStrategy": {
        "id": "6b5157cb-343a-41e7-bfa3-7b4ec3044840",
        "name": "flexibleRollout",
        "title": "Gradual Rollout 25-Prod",
        "featureName": "myAwesomeFeature",
        "sortOrder": 9999,
        "segments": [
          1,
          2
        ],
        "constraints": [
          {
            "contextName": "appName",
            "operator": "IN",
            "values": [
              "my-app",
              "my-other-app"
            ],
            "value": "my-app"
          }
        ],
        "variants": [
          {
            "name": "blue_group",
            "weightType": "fix",
            "stickiness": "custom.context.field",
            "payload": {
              "type": "json",
              "value": "{\"color\": \"red\"}"
            }
          }
        ]
      },
      "visible": true,
      "requiredApprovals": 3
    }
  ]
}