Skip to contentSkip to navigation

Delete Workspace Beta

Permanently delete a workspace and all of its data.

DELETE /api/v1/workspaces/{workspace_id}

Requires an API key with the Requires an API key with the writeandadminscopes. Theadminscope is opt-in: no default key carries it. The call runs in the key's own workspace andX-Workspace-Idis ignored. It is recorded as anaudit.workspace.deleted event in the key's workspace, visible in [List Events](/api-reference/webhooks/list-events). scope.

Irreversible: leads, campaigns, email accounts, inbox and API keys of the workspace are deleted with it. The workspace must be owned by the key's creator. The call is refused for a personal workspace, for the workspace the key belongs to (400 cannot_delete_own_workspace), and for a workspace with a live paid subscription (409 subscription_active): cancel the subscription in Billing first. The audit event is written to the key's workspace so it survives the deletion.

Path Parameters

workspace_id string path required

The workspace to delete.

Query Parameters

confirm boolean query required

Must be true. Without it the call returns 400 confirmation_required and deletes nothing.

Errors

StatusDescription
401Missing, invalid, revoked or expired API key
403API key does not have the required scope: Requires an API key with the writeandadminscopes. Theadminscope is opt-in: no default key carries it. The call runs in the key's own workspace andX-Workspace-Idis ignored. It is recorded as anaudit.workspace.deleted event in the key's workspace, visible in [List Events](/api-reference/webhooks/list-events).
400confirm is not true, the workspace is personal, or it is the key's own workspace
403Key lacks write or admin, or the key's creator does not own the workspace
404Workspace not found
409The workspace has a live paid subscription

Rate Limit

  • 120 requests per minute, shared by every write call in your workspace. Fixed 60-second window.
  • Every response includes X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset (unix epoch seconds) and X-RateLimit-Bucket (write).
  • A 429 response includes a Retry-After header (seconds until the bucket resets).

For client-side patterns, see Rate Limiting.

Was this page helpful?