Skip to content

Delete a tenant

DELETE
/tenants/{id}
curl --request DELETE \
--url https://localhost:3000/api/v1/tenants/example \
--header 'Authorization: <Authorization>' \
--header 'Content-Type: application/json' \
--data '{ "transfer_triggers": true }'

Deletes a tenant. Owner only. With transfer_triggers=true its triggers move to the owner’s personal account (private, out of any group); with false (the default when the body is omitted) they are deleted with their events, panes and access grants. Returns 409 trigger_name_conflict, with the colliding names, when a transferred trigger shares its name with one the owner already has; nothing is changed.

id
required
string

Tenant ID (UUID)

Delete options

Media typeapplication/json
object
transfer_triggers
required

TransferTriggers moves the tenant’s triggers to the owner’s personal account (private, out of any group) instead of deleting them with their events. Defaults to false.

boolean

Example

true

No Content

Media typeapplication/json

Invalid request

Media typeapplication/json
object
error
required
string
message
string

Example

{
"error": "invalid_request",
"message": "Invalid request body"
}

Unauthorized

Media typeapplication/json
object
error
required
string
message
string

Example

{
"error": "invalid_request",
"message": "Invalid request body"
}

Not the owner

Media typeapplication/json
object
error
required
string
message
string

Example

{
"error": "invalid_request",
"message": "Invalid request body"
}

Tenant not found

Media typeapplication/json
object
error
required
string
message
string

Example

{
"error": "invalid_request",
"message": "Invalid request body"
}

Trigger name conflict on transfer

Media typeapplication/json
object
error
required
string
message
string
names
required
Array<string>

Example

{
"error": "trigger_name_conflict",
"message": "trigger names already used by the owner",
"names": [
"signups",
"deploys"
]
}

Internal error

Media typeapplication/json
object
error
required
string
message
string

Example

{
"error": "invalid_request",
"message": "Invalid request body"
}