Creates tags for the contact for the specified channel. TICKET-type tags are only assigned when the contact has an active ticket. The response reports counts for created, assigned, and not-assigned tags, plus details explaining why some could not be assigned.
| Parameter | Type | Required | Description |
|---|---|---|---|
channelType | string | Yes | Channel type: “whatsapp”, “web-whatsapp”, “instagram”, “playground” |
platformIdentifier | string | Yes | Phone number (with country code) or username |
| Field | Type | Required | Description |
|---|---|---|---|
tags | string[] | Yes | Array of tag names (strings) to create/assign |
| Field | Type | Description |
|---|---|---|
status | string | Status of the operation (always “success”) |
createdCount | number | Number of new tags created |
assignedCount | number | Number of tags successfully assigned to the contact |
notAssignedCount | number | Number of tags that couldn’t be assigned |
notAssignedTags | string[] | Names of tags that weren’t assigned |
details | string | Explanation of why some tags weren’t assigned (if any) |
| Channel Type | Platform Identifier Format | Example |
|---|---|---|
whatsapp | Phone with country code | +56912345678 |
web-whatsapp | Phone with country code | +56912345678 |
instagram | Username (no @) | customer_username |
playground | Phone or identifier | +56912345678 |
+ symbols+5691234567856912345678+569 1234 5678{ "tags": ["new-tag-2024"] }
createdCount: 1["customer", "vip", "urgent-ticket"]| Status Code | Description |
|---|---|
| 400 | Bad Request - Invalid channel type or missing tags |
| 401 | Unauthorized - Invalid or missing API key |
| 404 | Not Found - Contact not found for the specified channel/identifier |
| 500 | Internal Server Error - Something went wrong |
| Feature | POST (This Endpoint) | PATCH (Update Tags) |
|---|---|---|
| Lookup Method | Phone/username | Contact ID (UUID) |
| Tag Format | Tag names (strings) | Tag IDs (numbers) |
| Behavior | Adds tags (additive) | Replaces all tags |
| Tag Creation | Auto-creates missing tags | Requires existing tag IDs |
| Response Detail | Created/assigned/not-assigned counts | Simple success + count |
API key for request authorization
The type of channel to create a tag for
whatsapp, playground, web-whatsapp, instagram The platform identifier for the contact, e.g. phone number (with country code) or username
Tags processed successfully