Delete a user
DELETE/api/users/:id
Deletes a user. System administrators only. The user's activity logs are deliberately preserved (schema onDelete: SetNull nulls their userId; each entry keeps the actor's name/email in metadata), and their avatar file is cleaned up. The deleted identity is captured for the audit entry before removal.
Auth: required
Request
Responses
- 200
- 403
- 500
User deleted.
System administrators only (also returned when not signed in), or attempting to delete your own account.
Server error.