Environment Variables

Merge new environment variables into the existing set

Changed on

Adds or updates environment variables. Existing variables not present in the request body are preserved. Up to 256 variables per application; each key max 1024 chars; each value max 4096 chars.

Names are letters, digits, underscores, dots and hyphens, not starting with a digit. A value with spaces or shell characters (such as & or ;) is stored single-quoted, as the dashboard does, because the application loads its variables with a shell; a value already quoted is kept as sent. A reference to another variable ($HOST, ${HOST}, alone or inside double quotes) keeps working; command substitution ($(...), backticks) is stored as plain text. The 4096-character limit counts the value, not the quotes added around it.

Requires the workspace Administrator role (or ownership) when called against a workspace-shared application.

post/v2/apps/{appId}/envs

Request

Path parameters

appIdstring required

Application identifier. Optionally suffixed with -<workspaceId> to act on a workspace-shared application.

Request body

envsobject required

Variables to merge into the existing set.

Response

The whole updated set. A key without envs:read gets back only the variables it sent in this request.

status'success' required
responseEnvVars required

Environment variables as an arbitrary { key: value } map of strings.

Changes

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new SNAPSHOTS_UNAVAILABLE enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRITE_FAILED enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status

    • warning

      added the new WRONG_HOST enum value to the //// response property for the response status