/v1/deployments/{uid}Changes a deployment's settings. Send only the fields you want to change.
Settings are saved immediately but most only take effect on the next build or deploy
(a manual deploy or a git push). Changing
artifact_retention deletes older build images right away. Turning scale-to-zero off
wakes a sleeping (idle) deployment's status back to active.
Rules enforced:
- A persistent volume can be added, and its size can only grow. Once created it cannot be removed. A volume limits the app to one replica and is incompatible with preview apps.
- Scale-to-zero needs
min_replicasof1. Free plans always scale to zero and run one replica, so sendingscale_to_zero_enabled: falseon a Free plan is rejected. - Component deployments of one-click apps cannot scale to zero.
- Preview apps need a GitHub repository (
git_repo_full_name). - For GitHub App repositories, a changed
branchorroot_directoryis checked against the repository.
To change the plan, use Change a deployment plan.
The response is the updated deployment without last_run_status, so display_status
equals status.
Authentication
Send your API key as Authorization: Bearer <token>. The request is scoped to the workspace in X-Workspace-Slug.
Path parameters
uidstringRequiredThe deployment's uid.
Headers
X-Workspace-SlugstringRequiredSlug of the workspace the request acts on. You can also pass it as the workspace_slug query parameter.
Request body
branchstringBranch to build. Cannot be empty.
root_directorystringFolder inside the repository to build from. Must be relative and stay inside the repository. Empty builds from the root.
app_typestringservice or static (aliases backend, api, frontend and web are accepted).
One ofservicestatic
build_commandstringBuild command override. Send an empty string to clear it.
start_commandstringStart command override. Send an empty string to clear it.
health_check_pathstringHealth check path. Must start with /. Empty resets it to /.
portintegerPort your app listens on. Must be positive.
min 1
auto_deploy_enabledbooleanBuild and deploy automatically on every push to the branch.
security_scan_enabledbooleanScan built images for vulnerabilities.
preview_apps_enabledbooleanCreate a preview app for each pull request.
artifact_retentionintegerHow many built images to keep for rollbacks. 0 keeps all. The live image and in-flight runs are never pruned.
min 0 · max 50
volume_mount_pathstringAbsolute mount path of the persistent volume. Same rules as on create.
volume_size_gibintegerVolume size in GiB. Can only grow.
min 1 · max 512
scale_to_zero_enabledbooleanLet the app sleep when idle.
scale_to_zero_idle_minutesintegerIdle minutes before the app sleeps. 0 means 5.
min 1 · max 1440
min_replicasintegerInstances always running.
min 1 · max 5
max_replicasintegerAutoscaling upper bound.
min 1 · max 5
target_request_rateintegerRequests per second per replica before scaling out.
min 1 · max 10000
Response
The updated deployment.
successbooleanRequiredtrue when the request succeeded.
messagestringRequiredHuman-readable status message.
dataobjectShow attributesHide attributes
uidstringRequiredUnique identifier of the deployment.
namestringRequiredDisplay name.
slugstringRequiredURL-safe name, unique in the workspace.
statusstringRequiredbuilding until the first version is live, then active. failed when the last
deploy failed and nothing is live, idle while a scale-to-zero app is asleep (it wakes
on the next request), paused while the account is suspended for non-payment (the
app is scaled to zero and stops billing for compute; it is resumed automatically once
the account is active again), deleted after deletion. A deployment created without
deploy_now is active even though nothing has been deployed.
One ofactivebuildingfailedpausedidledeleted
display_statusstringStatus to show to people. Same as status, except updating while a live deployment's next version is still building, and starting once that build has an image and the app is coming up. Only computed by list and get; elsewhere equal to status.
plan_slugstringRequiredSlug of the deployment's plan.
plan_namestringName of the plan.
vcpuintegerWhole vCPU count of the plan. Coarse; prefer cpu_limit_millis.
cpu_limit_millisintegerCPU limit per replica in millicores.
memory_mibintegerMemory limit per replica in MiB.
monthly_price_centsintegerPlan price per month per replica, in cents. Omitted for free plans.
hourly_price_centsintegerHourly price in whole cents. Omitted when 0.
hourly_price_microsintegerHourly price in millionths of the currency unit. Omitted for free plans.
currencystringISO currency code of the prices.
free_allowance_countintegerPresent on Free plans with the per-account allowance.
repo_urlstringRequiredGit repository the deployment builds from. Empty for one-click app components, which run a prebuilt image.
git_providerstringgithub_app when the repository is connected through the RumptyCloud GitHub App.
git_repo_full_namestringowner/repository on GitHub.
git_repo_idstringGitHub repository ID.
branchstringRequiredBranch that is built.
root_directorystringFolder inside the repository that is built. Omitted when building from the root.
app_typestringRequiredKind of app.
One ofservicestatic
build_methodstringRequiredHow the image is built. image is used by one-click app components, which run a prebuilt image.
One ofrailpackdockerfileimage
build_commandstringBuild command override, if set.
start_commandstringStart command override, if set.
health_check_pathstringPath probed for health.
portintegerRequiredPort the app listens on.
auto_deploy_enabledbooleanRequiredWhether pushes to the branch deploy automatically.
security_scan_enabledbooleanRequiredWhether built images are scanned for vulnerabilities.
preview_apps_enabledbooleanRequiredWhether pull requests get preview apps.
artifact_retentionintegerRequiredHow many built images are kept for rollbacks. 0 keeps all.
previewsarray of objectsLive pull request previews. Only returned by Get a deployment.
Show item attributesHide item attributes
uidstringRequiredUID of the preview deployment.
pr_numberintegerRequiredPull request number.
branchstringRequiredPull request branch.
statusstringRequiredPreview status, using the same values as a deployment's display_status.
commit_shastringCommit of the preview's latest run.
public_urlstringURL of the preview.
expires_atstring (date-time)When the preview is removed automatically.
volume_mount_pathstringMount path of the persistent volume. Omitted without a volume.
volume_size_gibintegerSize of the persistent volume(s) in GiB. Omitted without a volume.
scale_to_zero_enabledbooleanPresent and true when the app sleeps when idle.
scale_to_zero_idle_minutesintegerIdle minutes before the app sleeps.
min_replicasintegerInstances always running.
max_replicasintegerAutoscaling upper bound.
target_request_rateintegerRequests per second per replica before scaling out.
current_replicasintegerReplicas running now. Each is billed at the plan rate.
app_uidstringSet when the deployment is a component of a one-click app. Such deployments cannot be deleted or change plan on their own.
custom_domainstringThe verified custom domain that public_url uses, if any.
last_run_uidstringUID of the most recent run.
last_run_statusstringStatus of the most recent run. Only returned by list and get.
One ofqueuedbuildingreadyfailedcanceled
public_urlstringURL the app is served at. Uses the custom domain once one is verified. Empty after deletion.
default_public_urlstringThe app's URL on the platform domain. Point custom domain CNAME records at its host.
created_atstring (date-time)RequiredWhen the deployment was created.
last_failurestringReadable reason for the last failure. Omitted when there is none.
env_changes_pendingbooleanPresent and true when environment variables changed since the last deploy and are waiting to be applied. Only returned by Get a deployment.
env_changes_require_buildbooleanPresent and true when the pending changes need a rebuild (Deploy a deployment) rather than Apply environment changes. Only returned by get.
crashloopobjectPresent while the platform is holding the app down because it was not healthy.
Show attributesHide attributes
statestringRequiredpaused: the app was serving, became unhealthy and is retried automatically. stopped: nothing more happens until you restart or redeploy.
One ofpausedstopped
sincestring (date-time)When the app was taken down.
reasonstringWhy the app was taken down.
next_retry_atstring (date-time)Next automatic attempt. Only while paused.
Errors
| Status | Meaning |
|---|---|
400 | Validation failed. Examples: invalid request, branch is required, invalid port number, artifact_retention must be between 0 (keep all) and 50, connect GitHub before enabling preview apps, the persistent volume cannot be removed once created, volume size can only grow: this deployment already has 10 GiB, min_replicas cannot exceed max_replicas, one-click apps cannot scale to zero; they stay always on. |
401 | The API key is missing, invalid, expired or revoked. |
403 | You cannot access the workspace, your role does not allow this action, or the account is suspended. |
404 | The resource does not exist or you cannot access it. |
Errors use the standard error format.