API 参考Employees
Remove an employee (must be INACTIVE)
Permanently deletes the employee record. Only allowed when status is INACTIVE.
Requires employees:write scope. Requires Idempotency-Key header.
Authorization
apiKey AuthorizationBearer <token>
API key: Authorization: Bearer mpk_live_<key>
In: header
Path Parameters
employee_id*string
Employee/user identifier
Header Parameters
Idempotency-Key*string
UUID v4. Required on all write operations. Prevents duplicate execution on retry.
Format
uuidResponse Body
application/json
curl -X DELETE "https://motivation-money.vercel.app/api/v1/employees/usr_emp456" \ -H "Idempotency-Key: 7f3c4d2a-8b1e-4f6a-9c2d-1a5b8e3f7d4c"Empty
{
"error": {
"code": "INVALID_STATUS_TRANSITION",
"message": "Cannot delete an employee in ACTIVE status.",
"details": {
"current_status": "ACTIVE"
},
"recovery_hint": "Set the employee to INACTIVE first via PATCH /v1/employees/{id}."
}
}