Chat
Pin chat
Pins or unpins a chat at the top of the list
POST
Pin chat
Auth:
TokenAccount or TokenInstance • Rate-limit: Global (100/min) • Idempotent: yes
Description
Marks a chat as pinned (pin: true) or removes the pin (pin: false).
Examples
Pin
Withpin: true, the chat moves to the top of the list. Remember WhatsApp allows at most 3 pinned chats at the same time, trying a fourth returns an error.
Unpin
Withpin: false, removes the pin and the chat returns to normal sorting by activity. Frees a slot in the limit of 3 pinned chats.
Success response
The response confirms the operation withchat_jid (JID resolved from number) and pinned reflecting the final state. The message changes depending on the value of pin: "Chat pinned successfully" or "Chat unpinned successfully".
200 OK
Path parameters
Instance name.
Headers
| Name | Required | Example | Description |
|---|---|---|---|
Content-Type | yes | application/json | , |
token | yes (or Authorization) | a1b2c3d4-... | TokenAccount or TokenInstance. |
Request body
Phone number, private JID (
...@s.whatsapp.net or ...@lid), group JID (...@g.us), or newsletter.true pins, false unpins.Error responses
| HTTP | error.message | When it happens |
|---|---|---|
| 400 | Instance name is required | , |
| 400 | Invalid request body: <...> | Malformed JSON. |
| 400 | Number is required | , |
| 401 | Invalid token | , |
| 404 | Instance not found | , |
| 503 | Instance is not connected to WhatsApp | , |
Error 400
Related
Archive chat
POST /api/chat/archive/:instanceFavorite
POST /api/chat/favorite/:instance