App Environment Management API
The App Environment Management API allows you to manage resources, scaling, and apply pending changes to app environments in Quave ONE.
Make sure to read the Get Started document to understand how the API works.
Note: All endpoints in this API accept both
appEnvIdandenvNameparameters for identifying the environment.
Apply Pending Changes
Applies any pending configuration changes to an app environment. This works like terraform apply - it takes the pending changes (from resources, scaling, env vars updates, Job config updates, startup command updates, etc.) and deploys them to the infrastructure.
Endpoint: POST /api/public/v1/app-env/apply-changes
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
appEnvId | String | Either | The ID of the app environment. |
envName | String | Either | The CLI environment name (alternative to appEnvId). |
Example
curl -X POST \
-H 'Authorization: YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b"
}' \
https://api.quave.cloud/api/public/v1/app-env/apply-changes
Example Response
{
"success": true,
"message": "Changes applied successfully",
"appEnv": {
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"name": "Production",
"status": "UPDATING"
}
}
Notes
- If there are no pending changes, the API will return a success response with a message indicating no changes were applied.
- The operation determines the type of changes (build, deploy, or scale) and executes them in the correct priority order.
- For Job apps, applying Job config changes updates the applied Job config snapshot used by future default JobRuns. It does not run the Job by itself.
- For regular Apps and Functions, applying a startup command change redeploys the current content with the saved runtime override. It does not rebuild the image. See Startup Command Overrides.
Update Resources
Updates the resource allocation for an app environment. You can use either zClouds (simplified abstraction) or custom resources (CPU/memory) for Connect accounts. Disk storage can be set for managed databases and regular app environments with a local persistent volume.
Endpoint: PATCH /api/public/v1/app-env/resources
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
appEnvId | String | Either | The ID of the app environment. |
envName | String | Either | The CLI environment name (alternative to appEnvId). |
zClouds | Number | No | Number of zClouds. 1 zCloud includes 0.5 CPU, 512 MB memory, and 5 GB of included managed-database disk allowance. |
cpu | Number | No | CPU limit in cores (e.g., 2.0). Requires a Connect account. |
cpuRequest | Number | No | CPU request (guaranteed minimum). Must not exceed cpu. Requires a Connect account. |
memory | Number | No | Memory limit in MB (e.g., 2048). Requires a Connect account. |
memoryRequest | Number | No | Memory request (guaranteed minimum). Must not exceed memory. BYOP. |
disk | Number | No | Allocated disk storage in MB. Applies only to managed databases and regular app environments with a local persistent volume (useVolume=true and useNfsVolume=false). Once this disk size has been applied, this value can only stay the same or increase. Shared NFS volumes and stateless apps do not use this disk setting. For DevOps databases, use at least 1000 MB (1 GB). Starting with July 2026 billing, eligible Direct local disk above the included zClouds * 5 GB allowance is billed as storage overage. See pricing. |
networkIngress | Number | No | Network ingress in Mbps. Requires a Connect account. |
networkEgress | Number | No | Network egress in Mbps. Requires a Connect account. |
applyImmediately | Boolean | No | If true, deploy changes immediately. Default: false (pending changes). |
Example: Update zClouds
curl -X PATCH \
-H 'Authorization: YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"zClouds": 4,
"applyImmediately": true
}' \
https://api.quave.cloud/api/public/v1/app-env/resources
Example: Update Custom Resources (Connect)
curl -X PATCH \
-H 'Authorization: YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"cpu": 2.0,
"cpuRequest": 1.0,
"memory": 2048,
"memoryRequest": 1024,
"disk": 10240
}' \
https://api.quave.cloud/api/public/v1/app-env/resources
Example Response
{
"success": true,
"message": "Resources updated and changes applied",
"appEnv": {
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"name": "Production",
"zClouds": 4
},
"appliedImmediately": true
}
Notes
- zClouds vs Custom Resources: Use
zCloudsfor simplified resource allocation, or custom fields (cpu,memory,disk) for fine-grained control. Don't mix both. - Connect Requirement: Custom resources are only available for accounts with Quave ONE Connect enabled (legacy API fields may still use BYOP names).
- Persistent Disk: Auto-provisioned database disks must be between the
minDiskMbandmaxDiskMbvalues returned byGET /api/public/v1/database-presets. Regular app local persistent volumes are limited to 1000 MB for ordinary customer accounts unless support changes the size for you. Applied disks are grow-only: updates may keep the current value or increase it, but decreases are rejected. Redis without persistence is the database exception and usesdisk: 0. - Request vs Limit: Request values are the guaranteed minimum resources; limit values are the maximum. Request must not exceed limit.
Update Scaling Options
Updates Autoscaling and Connect Scale to zero in one atomic configuration change. You may send either nested object or both. Autoscaling can be available to Direct accounts when enabled for the account; Scale to zero is available only to eligible Connect accounts with account Autoscaling enabled.
Endpoint: PATCH /api/public/v1/app-env/scaling-options
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
appEnvId / envName | String | Either | App environment identifier. |
autoscaling | Object | No | Warm container policy: autoScalingEnabled, containers (Immediate Desired), replica range, targets, steps and stabilization windows. |
scaleToZero | Object | No | Idle parking policy: enabled, idleMinutes, wakeTimeoutSeconds, and wakeMode. |
applyImmediately | Boolean | No | Deploy now with a user/API token; default is pending changes. Environment tokens can save the pending configuration, but cannot apply it immediately. |
Example
curl -X PATCH -H 'Authorization: YOUR_TOKEN' -H 'Content-Type: application/json' \
-d '{"appEnvId":"5f7b1b7b7b7b7b7b7b7b7b7b","autoscaling":{"autoScalingEnabled":true,"containers":2,"minReplicaCount":1,"maxReplicaCount":5,"cpuTargetUtilization":70},"scaleToZero":{"enabled":true,"idleMinutes":60,"wakeMode":"BLOCKING"},"applyImmediately":true}' \
https://api.quave.cloud/api/public/v1/app-env/scaling-options
Scale Containers
Manually scales the number of containers for an app environment.
Endpoint: POST /api/public/v1/app-env/scale
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
appEnvId | String | Either | The ID of the app environment. |
envName | String | Either | The CLI environment name (alternative to appEnvId). |
containers | Number | Yes | Number of containers to run (at least 1). |
applyImmediately | Boolean | No | If true, deploy changes immediately. Default: false. |
Example
curl -X POST \
-H 'Authorization: YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"containers": 5,
"applyImmediately": true
}' \
https://api.quave.cloud/api/public/v1/app-env/scale
Example Response
{
"success": true,
"message": "Container count updated and changes applied",
"appEnv": {
"appEnvId": "5f7b1b7b7b7b7b7b7b7b7b7b",
"name": "Production",
"containers": 5
},
"appliedImmediately": true
}
Notes
- If autoscaling is enabled, manual scaling will temporarily override it until the next autoscaling event.
- Consider disabling autoscaling if you need consistent manual control over container count.
Error Responses
All endpoints may return the following error responses:
| Status | Description |
|---|---|
400 | Invalid request (missing required fields, invalid values). |
401 | User not authenticated. |
403 | User doesn't have permission to access this app environment. |
404 | App environment not found for the given appEnvId or envName. |