Delete Customer
Permanently deletes a customer and deactivates or deletes the users assigned only to it.
DELETE /api/customers/:customerPublicId
Permanently deletes a customer. Its monitors, check history, incidents, reports and screenshots are removed with it. This cannot be undone.
Only organization admins may delete customers. Editors, readonly users and customer-scoped API
tokens receive 403.
Users of the customer
Users who have access only to this customer cannot keep their account without one. One of
two things always happens to them, chosen with the userAction query parameter:
userAction | Effect |
|---|---|
deactivate (default) | The users are deactivated. They can no longer use the dashboard or the API and can be reactivated later with Update User. |
delete | The users are deleted permanently. |
Users who also have access to other customers keep their account and only lose access to the deleted customer. There is no option to keep users without a customer.
Authentication
BASE_URL="https://uptimeify.io"
TOKEN="wsm_<your-api-token>"Example Request
curl -X DELETE "$BASE_URL/api/customers/6bfec6f6-245a-47ce-843b-157d97d56f88?userAction=delete" \
-H "Authorization: Bearer $TOKEN"Example Response
{
"success": true,
"message": "Customer deleted successfully",
"userAction": "delete",
"affectedUsers": 1
}affectedUsers is the number of users that were deactivated or deleted.
Common errors
400 Bad Requestwithdata.code: "invalidUserAction"whenuserActionis neitherdeactivatenordelete. Nothing is deleted.403 Forbiddenwithdata.code: "forbidden"when the caller is not an organization admin or uses a customer-scoped token404 Not Foundwithdata.code: "customerNotFound"when the customer does not exist in your organization