Contacts

Contacts are the people who interact with your agents. The API calls them clients (/v1/clients). Store their profiles, custom fields and tags to organize them.

Example

await platic.clients.create({ phoneNumber: "5215512345678", name: "Ana" });

What you need to know

  • Every error under /v1/clients uses the standard format, with a details.code. See Errors.
  • GET and PATCH /v1/clients/{id} accept the contact's ID, phone number or email.
  • A blocked contact stops receiving automatic replies.

Endpoints

MethodEndpointDescription
GET/v1/clientsList all contacts
POST/v1/clients/searchSearch contacts by text and filters
POST/v1/clients/tagsAdd or remove tags on many contacts
GET/v1/clients/{id}Get a contact by ID, phone number or email
POST/v1/clientsCreate a contact
PATCH/v1/clients/{id}Update a contact by ID, phone number or email
DELETE/v1/clients/{id}Delete a contact by ID or phone number
GET/v1/clients/{clientId}/conversationsList all the conversations of a contact
PATCH/v1/clients/{id}/moderationBlock, unblock or reset strikes

Status and moderation

Each contact has a status (active or blocked) and a moderation object with its history. A blocked contact stops receiving automatic replies: its new conversations are born marked as spam and agents skip them.

Violations of the agent's safety rules add strikes to the contact. Exceeding the agent's limit blocks them automatically. Use Moderate a contact to change their status manually.