Delete a contact
SDK platic.clients.delete()
Deletes a contact's profile data and notes. Channel identifiers and conversation history are kept. Deletion cannot be undone.
Example
curl -X DELETE https://api.platic.ai/v1/clients/$CLIENT_ID \
-H "Authorization: Bearer $PLATIC_API_KEY" await platic.clients.delete("client_123"); Path parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
id | string | Can be the contact's ID or their phone number in E.164 format without + | ✓ |
Response
{
"status": "success",
"message": "Client deleted successfully"
} Errors
| Status | details.code | When it happens |
|---|---|---|
400 | INVALID_REQUEST | The identifier is not a valid contact identifier |
400 | INVALID_REQUEST | The credential covers several workspaces and ?workspace= is missing, or the supplied workspace is not authorized. details.available lists the available ones and details.requested shows the one you sent |
401 | UNAUTHENTICATED | The credential is missing or invalid |
403 | FORBIDDEN | The credential does not have the Contacts module (Missing contacts permission), or the user's role is read-only |
403 | INSUFFICIENT_SCOPE | An OAuth token without the platica:write scope tried to write. details.requiredScope says which one is missing |
404 | CLIENT_NOT_FOUND | No contact in that workspace has that identifier, it was deleted, or it is outside the reach of the user's role |
404 | WORKSPACE_NOT_FOUND | The credential does not carry any workspace |
409 | MULTIPLE_CONTACTS_MATCH | Two contacts have that email: use the ID. details.clientIds lists them |
502 | UPSTREAM_ERROR | Platica did not confirm the deletion. Retry with the same identifier |
The general error format is in Errors.
Notes
What gets deleted
- The contact's name, personal data, tags and custom fields are erased. It stops showing up in List contacts and Get a contact answers
404. - Channel identifiers (phone number, WhatsApp, Instagram, Telegram and Facebook IDs) and the creation date are kept to preserve conversation history.
- The contact's internal notes and the files attached to those notes are permanently deleted.
Warning
If the same number writes to you again, the contact is reused and its earlier conversations are still there, but its profile data and notes are not recovered.