Delete user
Overview
Soft-delete a user (and their person), anonymises the email, revokes any live tokens (SOC 2 CC6.2) and removes the user's email reports. You cannot delete your own account and the target must belong to the caller's company. Audited via USER_DELETED.
Prerequisites
- A bearer token in the
Authorizationheader.
Base URL
| Environment | URL |
|---|---|
| Production | https://production-api.shoutaboutus.com |
| Development | https://development-api.shoutaboutus.com |
Endpoint
DELETE /api/v1/users/delete
Authentication
-
Requires a bearer token in the
Authorization: Bearer <bearer-token>header. -
Authenticated company-admin — collection bearer token.
-
Gate: the target's
company_idmust equal the caller's, and the target ≠ self. Otherwise it returns403 Permission denied.
Rate limit
- No rate limit.
Request body
(DELETE request carries a JSON body.)
| Field | Type | Required | Description |
|---|---|---|---|
user | integer | Required | Id of the user to delete. |
{
"user": 12
}How it works
- Synchronous (DB transaction).
200on success. 403on company mismatch or self-delete (Permission denied.).500on delete failure (rolled back).
Response
200 OK · 200
200{
"data": {
"status": "success",
"response": "User has been deleted successfully."
}
}403 Permission denied · 403
403{
"message": "Forbidden",
"status": "error",
"errors": "Permission denied."
}Errors
| Status | Meaning |
|---|---|
401 | The bearer token is missing, expired or invalid |
403 | Permission denied |
422 | The request failed validation — the response names the fields |
500 | Returned on delete failure (rolled back) |
Example request
curl --request DELETE \
--url "https://production-api.shoutaboutus.com/api/v1/users/delete" \
--header 'Authorization: Bearer <bearer-token>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"user": 12}'Updated 11 days ago
Did this page help you?
