Send ZBS Message by UID
This API lets you send a ZBS message to a user by their Zalo UID (instead of a phone number), using a ZBS template that has already been published and approved by Zalo.
info
shopId is resolved automatically from your API key — you do not need to pass it manually.
Endpoint
🔗Endpoint Staging
POST https://staging-manage.api.miniai.vn/api/external/zalo/zbs-uid/send-message
🔗Endpoint Production
POST https://manage-api.miniap.vn/api/external/zalo/zbs-uid/send-message
Prerequisites
templateIdis the_idof the ZBS template in the system, and the template must already be published to Zalo.- The template must be linked to an OA and have a UID sending price (
priceUID). - The shop wallet must have enough balance to cover the sending fee, otherwise the request returns a
400error.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
userUID | string | Yes | The recipient's Zalo UID. |
templateId | string | Yes | The _id of the published ZBS template in the system. |
templateData | object | Yes | key-value (string) pairs matching the template parameters. |
- Request
{
"userUID": "3812763771849273645",
"templateId": "68c8ee675f8f83fc813e7830",
"templateData": {
"customer_fullname": "Lê Quốc An",
"order_code": "M0WHXJVU9L",
"order_status": "Delivered"
}
}
Response
- Response
{
"error": 0,
"message": "Success",
"data": {
"message_id": "cfcd208495d565ef66e7dff9f98764da"
}
}