Skip to content

Mosend WhatsApp Activities

Version: 1.0.4  ·  ID: zoan-packages-mosend  ·  Author: Zoan Software

The Mosend package lets a robot send WhatsApp messages through your organization’s Mosend account (a WhatsApp Business messaging service): order updates, payment reminders, PDF invoices, confirmations. It can also look up the approved templates of the account and find contacts before writing to them.

The Mosend account is connected once in Zoan Cloud and the activities use it by name:

  1. In Zoan Cloud, open the environment’s Centro › Recursos › Integraciones (Center › Resources › Integrations) and, in the Mensajería (Messaging) section, connect the Mosend account (with an API key or by authorizing with OAuth). The name you give it (for example mosend) is the one you put in the integration parameter of each activity.
  2. When the robot runs an activity, it asks Zoan Cloud for that integration’s session using the execution’s identity. Zoan Cloud hands over a valid session (with OAuth, a token it renews for you) and records in the audit log which execution used the integration.
  3. The robot talks to Mosend directly: the message content does not go through Zoan Cloud. The session is reused for the whole execution and secrets are masked in the logs.
  • The 24-hour window. WhatsApp only delivers free-form messages (Send WhatsApp Text and Send WhatsApp File) if the contact wrote to you in the last 24 hours. To write to someone for the first time, or outside that window, use a Meta-approved template with Send WhatsApp Template.
  • Sender number (from). The WhatsApp number of your account that sends the message, as shown in Mosend (+57 300 000 0000), or its Mosend id.
  • Recipient number (to). In international format, with or without +. Spaces and dashes are ignored; at least 8 digits are required.
ActivityTypeOutputWhat it does
Send WhatsApp Textmosend-send-textobjectSends a text message (inside the 24-hour window)
Send WhatsApp Templatemosend-send-templateobjectSends an approved template, also outside the 24-hour window
Send WhatsApp Filemosend-send-fileobjectSends an image, PDF, document, video or audio from the robot’s disk
List WhatsApp Templatesmosend-list-templatesList<object>Lists the account’s templates with their language and status
Find WhatsApp Contactmosend-find-contactList<object>Finds contacts by phone or name

Tell a customer their order has shipped and send them the invoice:

Send WhatsApp Template integration = "mosend" from = "+57 300 000 0000"
to = "+57 300 000 0001" template = "pedido_enviado"
variables = ["Test Customer", "#0001"] → output: notice
Send WhatsApp File integration = "mosend" from = "+57 300 000 0000"
to = "+57 300 000 0001" filePath = "C:/invoices/F-0001.pdf"
caption = "Your invoice for order #0001"