Environments

Update an environment

Updates the configuration of an environment. All fields are optional; omitted fields are preserved.

patch/projects/{id}/environments/{envId}

Request

  • Base URL: /v1 (relative, and the document was published on a file host, not at the API’s origin)
  • URL: /v1/projects/{id}/environments/{envId}
  • Auth: HTTP bearer

Path parameters

idstring required

The project ID (UUID).

envIdstring required

The environment ID (UUID).

Request body

$schemastring uri

A URL to the JSON Schema for this object.

branchstring

The branch to track.

build_machine_tierstring

The build machine tier.

dockerfile_pathstring

The Dockerfile path.

min_replicasinteger

The minimum number of VM replicas.

root_directorystring

The build root directory.

runtime_machine_tierstring

The runtime machine tier.

Example request

{
  "$schema": "/v1/schemas/UpdateEnvironmentInputBody.json"
}

Response

OK

$schemastring uri

A URL to the JSON Schema for this object.

branchstring required

The branch this environment tracks.

build_machine_tierstring required

The build machine tier: standard, enhanced, or performance.

created_atstring date-time required
dockerfile_pathstring required

The Dockerfile path relative to the root directory.

idstring required

The environment ID (UUID).

min_replicasinteger required

The minimum number of VM replicas.

root_directorystring required

The build root directory.

runtime_machine_tierstring required

The runtime machine tier: small, medium, or large.

slugstring required

The environment slug, unique within the project.

typestring required

The environment type: production or preview.

updated_atstring date-time required

Example response

{
  "$schema": "/v1/schemas/EnvironmentResponse.json"
}

Changes

No recorded changes to this operation across all 3 revisions of this API.