- Delete an end user by primary ID or foreign key
Deletes an end user and associated data from the system.
This endpoint applies to end users (C2 users), not admin users.
You must provide exactly one of the following identifier options: Option A — Delete by primary ID
primary_idOption B — Delete by foreign keyforeign[system]andforeign[key]
Rules
- Provide either
primary_idor bothforeign[system]andforeign[key]. - Do not provide both identifier options in the same request.
- If parameters are missing, incomplete, or conflicting, the API returns 400.
Important:
To delete JWT users who do not have a foreign system mapping (for example, users whose data exists in DynamoDB but not in the SQL database), provide zephr as the value for the foreign[system] parameter.
Examples:
Delete by primary ID:
DELETE /zephr/integration/users/v1/users?primary_id=123456Delete by foreign key:
DELETE /zephr/integration/users/v1/users?foreign[system]=my-system&foreign[key]=alexuser-12345Delete JWT user with no foreign mapping (DynamoDB-only):
DELETE /zephr/integration/users/v1/users?foreign[system]=zephr&foreign[key]=alexuser-12345
- https://demo.api.zephr.comhttps://demo.api.zephr.com/zephr/integration/users/v1/users
curl -i -X DELETE \
'https://demo.api.zephr.com/zephr/integration/users/v1/users?primary_id=123456&foreign%5Bsystem%5D=zephr&foreign%5Bkey%5D=user_998877' \
-H 'Authorization: ZEPHR-HMAC-* <YOUR_TOKEN_HERE>'