Creating a Broadcast
Engati makes it super easy for you to create a Broadcast. Simply go to the Broadcast workflow which is accessible from the left Navigation as Broadcast.
Once in the Broadcast Section, you would be able to view earlier created Broadcasts, that may be in Drafts. You will also have the option to create a new Broadcast
Broadcast comprises of 3 major sections,
1. Drafts: All pending broadcasts, which were not either triggered, scheduled or deleted
2. Scheduled: Broadcasts scheduled to be sent out once or periodically
3. Published: Already published broadcasts, that have been sent out
While creating a new Broadcast you will have to provide the following details,
- Give the broadcast a name
- Select target channels to which you want to send the broadcast
- Select type of broadcast – Send Message, Send Message with options and Trigger a path
- Input your Broadcast message, options or select a path to be triggered
- Select target segments or all users
- Send the broadcast message or schedule it
Engati provides you a mechanism to trigger a few different types of broadcasts. These include,
2.1 Send a Message: This type of broadcast is non-interactive. The receiver will see a Message
2.2 Send Message with options: This type of broadcast allows the sender to receive input from the receiver
2.3 Path This option takes the receiver through all the flows defined in a path. While creating a new Broadcast, think of it as a way of re-engaging your users and get them to start interacting with your chatbot again. This means that avoid triggering paths to just deliver a lot of content to users.
As the title suggests, this option allows you to define a set schedule for when you want the broadcast to be initiated/published. You could publish a broadcast as a one time or recurring occurrence. If recurring you can opt to select the frequency and the time period during which the broadcast will continue to be active.
This feature is available if you have an active WhatsApp setup with – 360Dialog, Kaleyra. Navigate to ‘Configure’ and ‘WhatsApp’ to set up your WhatsApp account. Visit the detailed documentation here, to know how to send whatsapp template messages to the new and existing users
Note: Template messages are charged on per message basis. Please contact your WhatsApp provider or Engati support team (firstname.lastname@example.org) for more information on the same
4.1 Segment Basic Usage
Click here to learn more about segments
HTTP Method : Post Request URL : https://api.engati.com/bot-api/v1.0/customer/<customerId>/bot/<botkey>/broadcast
(Customer ID, Bot key and Authorization token are available in the Integrations -> Engati API) Headers:
Content-Type : Application/json Authorization : Basic <Auth token>
“broadcastTitle” : Identifier name for the broadcast “channels” : Channels such as Web users, whatsapp users, mobile app. “segmentName” : Broadcast will published to users satisfying the attribute condition under this segment. “payload” : The message type to be sent, ‘Send message’, ‘Send message with options’ …
Sample Curl Request
4.2 Usage Rules
While defining the Broadcast Segment using an API, the below rules have to be kept in mind – Specifying Channels is mandatory If we are sending a DIRECT message on whatsApp , LastActiveAfter is 24hrs. For web LastActiveAfter is 48hrs.
4.3 Direct Message
See an example below of a Broadcast API request for a Direct Message to be sent to users
Direct Message with Options See an example below of a Broadcast API request for a Message with options sent to users
4.4 Set an attribute and send a message (optional) See an example below of a Broadcast API request to set an attribute and send a message
4.5 Trigger a Path and send a message (optional) See an example below of a Broadcast API request to trigger a path and send a message
4.6 Template Message on Whatsapp Whatsapp typically supports in session messages that are messages, sent to a user who was active with the chatbot in the last 24 hours. For initiating a conversation or notification beyond that time window, you need to send what’s called a message with a defined template. Engati supports sending template messages for Whatsapp using the below API structure. The below API is for Nexmo.
4.7 Template Message on 360dialog
URL: https://api.engati.com/bot-api/v2.0/customer/<customerId>/bot/<botkey>/broadcast HTTP Method: POST
Header – Authorization: Basic <API Key>
Note: Navigate to Engati APIs to find customer id, bot key and generate API Key
Below is the explanation of the attributes used above,
For broadcast creation
- broadcastTitle – Broadcast will be created using this name
- publishedOn – Time stamp when broadcast is to be scheduled. Provided time here in UTC, this will be taken as a scheduling time.
For a new user creation
- phoneNumber – Whatsapp number with + and country code – ‘+91979093071’. This is a mandatory field
- email – Email of the user will be set. This is an optional field
- organization – Organization of the user will be set. This is an optional field
- title – Title of the user will be set. This is an optional field
- lastName – Last name of the user will be set. This is an optional field
- firstName – First name of the user will be set. This is an optional field
- userName – Username of the user will be set. This is an optional field
Parameters used will also have to be provided under TEXT.
For media templates you can provide URLs for images, documents and flow keys (5.5 Trigger a path) for buttons, if applicable, like the below script,
As part of the Broadcasts, users will be able to download the target user list by clicking on the target user count as highlighted in the image. The downloaded file will be available as a csv and will have the following information,
- User id
- User name
- Contact number
- Platform/channel (on which the broadcast was sent)
- Reason for failure (available only for WhatsApp – 360dialog)
The downloaded file will also be available on the export history tab for user’s reference as shown in the image.
As part of the enhancement, users will be able to download the failed users details from the view broadcast screen, and will also have an option to retry it for the same users.