Actions3
- SMS Message Actions
- OTT Message Actions
Overview
This n8n custom node allows you to send Zalo ZNS (Zalo Notification Service) messages via the EsmsVN API. The "Gửi tin nhắn ZNS" operation under the "OTT Message" resource is designed for automated workflows where you need to deliver notifications or transactional messages to users on the Zalo platform. Typical use cases include sending appointment reminders, order confirmations, or promotional messages directly to customers' Zalo accounts.
Practical examples:
- Sending a birthday greeting to a customer via Zalo.
- Notifying a user about their order status update.
- Delivering service alerts or marketing campaigns through Zalo's official channels.
Properties
Name | Type | Meaning |
---|---|---|
SmsType | options | Type of Zalo message to send. Options: "Zalo Ưu Tiên" (priority), "Zalo Bình Thường" (normal). |
PhoneNumber | string | Recipient's phone number. Required for delivering the message. |
Content | string | The content/body of the Zalo message to be sent. |
Options | collection | Additional settings: - IsUnicode (boolean): Send as Unicode message. - Sandbox (boolean): Send in sandbox mode for testing. - PartnerSource (number): Optional partner source identifier. |
Output
The node outputs a JSON object for each processed item. The structure includes:
{
"executionId": "<string>",
"resource": "ott_message",
"operation": "sendZnsMessage",
"status": "completed",
"timestamp": "<ISO8601 datetime>",
// ...additional fields returned by the EsmsVN API, such as message ID, delivery status, etc.
}
- If an error occurs and "Continue On Fail" is enabled, the output will also include an
error
field with details about the failure.
Dependencies
- External Service: Requires access to the EsmsVN API.
- Credentials: You must configure EsmsVN credentials in n8n (as required by the node).
- n8n Configuration: No special environment variables are needed beyond standard credential setup.
Troubleshooting
Common Issues:
- Invalid Credentials: If your EsmsVN API key or secret is incorrect, authentication will fail.
- Missing Required Fields: Omitting required properties like "PhoneNumber" or "Content" will result in errors.
- Unsupported Resource/Operation: Using an unknown resource or operation will throw an error indicating the resource is not known.
Error Messages:
"The resource \"<name>\" is not known!"
Resolution: Check that you have selected the correct resource and operation.- Errors from the EsmsVN API (e.g., invalid phone number format, insufficient balance) will be included in the output if "Continue On Fail" is enabled, otherwise they will stop execution.