Skip to content

Environments API

Manage environments (base URLs, model selection) and environment variables.

Environments define where sessions run and what context is available (base URL, variables, model selection, version). Web and API projects use baseUrl; mobile projects can also provide Appium/mobile runtime overrides for a specific device or app target.

List environments (overview)

GET/api/environments/overviewBearer Token

List environments (paged)

GET/api/environmentsBearer Token

Query uses page and pageSize.

Create environment

POST/api/environmentsBearer Token

Update environment

PUT/api/environments/{id}Bearer Token

This is how you update fields like baseUrl, anthropicModel, and version. For API projects, baseUrl becomes the agent container's TARGET_BASE_URL.

For mobile projects, send mobileRuntimeOverrides to override the project defaults for a specific environment:

{
  "name": "Android Staging",
  "key": "android-staging",
  "mobileRuntimeOverrides": {
    "deviceName": "Pixel 8",
    "udid": "emulator-5554",
    "androidAppPackage": "com.example.staging",
    "androidAppActivity": ".MainActivity"
  }
}

Delete environment

DELETE/api/environments/{id}Bearer Token

Variables

GET/api/environments/{id}/variablesBearer Token
POST/api/environments/{id}/variablesBearer Token
PUT/api/environments/{envId}/variables/{varId}Bearer Token
DELETE/api/environments/{envId}/variables/{varId}Bearer Token