Skip to content

Delete an app

DELETE/v1/apps/{uid}

Deletes the app and all of its component deployments, including their persistent volumes and data. The app and its components are marked deleted straight away (billing stops and custom domains are released), and each component's runtime is torn down by its own delete_deployment operation, web component first.

The response is 202 Accepted with status: deleted and no operation_id. The component operations are not returned; you can find them with List operations. Because the components are already deleted, they appear in the response with only role and deployment_uid.

Concurrent deletes of the same app are serialized: while one is in progress, another request returns 409 (app deletion is already in progress), unless it carries the same X-Idempotency key, in which case it gets the first request's result.

Send X-Idempotency to make retries safe. The key is recorded when the delete starts, so repeating the request with the same key returns 200 OK with is_replay: true, is_completed: true and status: deleted instead of 404. On a replay the app is gone, so app only carries uid, name and status. Reusing the key for a different action or a different app returns 409 with action: idempotency_key_reused.

Authentication

Send your API key as Authorization: Bearer <token>. The request is scoped to the workspace in X-Workspace-Slug.

Path parameters

uidstringRequired

The app's uid.

Headers

X-Workspace-SlugstringRequired

Slug of the workspace the request acts on. You can also pass it as the workspace_slug query parameter.

X-Idempotencystring

Optional key that makes retries safe. Repeating a request with a key already used for the same action returns the original result with 200 OK and is_replay: true. Reusing it for a different action or app returns 409 with action: idempotency_key_reused.

Response

202

The app was deleted and component teardown was queued.

successbooleanRequired

true when the request succeeded.

messagestringRequired

Human-readable status message.

dataobject
Show attributes
operation_idstring

UID of the app_provision operation. Omitted on delete.

appobjectRequired
Show attributes
uidstringRequired

Unique identifier of the app.

namestringRequired

Display name.

slugstringRequired

URL-safe name, unique among the workspace's apps.

templatestringRequired

Slug of the template the app was created from.

statusstringRequired

provisioning_database while backing services start, provisioning_app once they are ready and the web component is starting, active when every component is ready, failed if provisioning failed (see last_failure), deleted after deletion.

One ofprovisioning_databaseprovisioning_appactivefaileddeleted

public_urlstring

URL of the app, taken from the web component (including a verified custom domain).

last_failurestring

Why provisioning failed. Omitted when there is no failure.

created_atstring (date-time)Required

When the app was created.

componentsarray of objects

The app's component deployments, in deploy order.

Show item attributes
rolestringRequired

Role of the component.

One ofdatabaseweb

deployment_uidstringRequired

UID of the component's deployment. Use it with the deployment endpoints.

namestring

Name of the component deployment. Omitted once the component is deleted.

statusstring

Status of the component deployment (see status on Get a deployment). Omitted once deleted.

plan_slugstring

Plan of the component deployment. Omitted once deleted.

setup_notestring

First-run instructions from the template, with the app's URL filled in.

env_docs_urlstring

Link to the software's configuration reference.

statusstringRequired

running (the provisioning operation's status) on create, deleted on delete. On a replayed create, the operation's current status (running, succeeded or failed).

events_urlstring

Path of the server-sent events stream with provisioning progress. Omitted on delete.

is_replaybooleanRequired

true when an X-Idempotency key was reused and the original result is returned.

is_completedboolean

true when a replayed operation has already finished (always on a replayed delete). Omitted unless true.

Response

200

Replay. The app was already deleted with this X-Idempotency key, so nothing is done again.

successbooleanRequired

true when the request succeeded.

messagestringRequired

Human-readable status message.

dataobject
Show attributes
operation_idstring

UID of the app_provision operation. Omitted on delete.

appobjectRequired
Show attributes
uidstringRequired

Unique identifier of the app.

namestringRequired

Display name.

slugstringRequired

URL-safe name, unique among the workspace's apps.

templatestringRequired

Slug of the template the app was created from.

statusstringRequired

provisioning_database while backing services start, provisioning_app once they are ready and the web component is starting, active when every component is ready, failed if provisioning failed (see last_failure), deleted after deletion.

One ofprovisioning_databaseprovisioning_appactivefaileddeleted

public_urlstring

URL of the app, taken from the web component (including a verified custom domain).

last_failurestring

Why provisioning failed. Omitted when there is no failure.

created_atstring (date-time)Required

When the app was created.

componentsarray of objects

The app's component deployments, in deploy order.

Show item attributes
rolestringRequired

Role of the component.

One ofdatabaseweb

deployment_uidstringRequired

UID of the component's deployment. Use it with the deployment endpoints.

namestring

Name of the component deployment. Omitted once the component is deleted.

statusstring

Status of the component deployment (see status on Get a deployment). Omitted once deleted.

plan_slugstring

Plan of the component deployment. Omitted once deleted.

setup_notestring

First-run instructions from the template, with the app's URL filled in.

env_docs_urlstring

Link to the software's configuration reference.

statusstringRequired

running (the provisioning operation's status) on create, deleted on delete. On a replayed create, the operation's current status (running, succeeded or failed).

events_urlstring

Path of the server-sent events stream with provisioning progress. Omitted on delete.

is_replaybooleanRequired

true when an X-Idempotency key was reused and the original result is returned.

is_completedboolean

true when a replayed operation has already finished (always on a replayed delete). Omitted unless true.

Errors

StatusMeaning
401The API key is missing, invalid, expired or revoked.
403You cannot access the workspace, your role does not allow this action, or the account is suspended.
404The resource does not exist or you cannot access it.
409The X-Idempotency key was already used for a different action or app (action: idempotency_key_reused), or another delete of this app is in progress (app deletion is already in progress).

Errors use the standard error format.