Send Template Message
Sends template messages to your contacts
Sends a template message to a specified contact number. Requires a pre-approved template name and its associated variables.
The secret key provided by iSlash for accessing the iSlash API platform.
The session key generated by your admin to control which channel can send messages via the API.
The name of the approved WhatsApp template to send.
The target contact number (e.g., 85256872847).
Template variable 1. The number of required variables depends on the template.
Button URL variable 1. Optional, depends on the template.
Catalog identifier for product carousel, single product, and catalog templates. Product catalog template sending is supported for iSlash channels only. Accepts the CMS catalog ID, or the Facebook catalog ID if no matching CMS ID exists.
Selected CMS product ID for single product templates.
Selected product IDs for product carousel templates. For single product templates, product_id is preferred. Accepts repeated multipart fields, a JSON array string, or comma-separated values.
Facebook catalog ID for product carousel, single product, and catalog templates. Use this when sending with product_retailer_ids, product_retailer_id, or thumbnail_product_retailer_id.
Required CMS product ID to use as the thumbnail product for catalog templates.
Required Facebook product retailer ID to use as the thumbnail product for catalog templates when not using thumbnail_product_id.
Selected Facebook product retailer ID for single product templates.
Selected product retailer IDs for product carousel templates. For single product templates, product_retailer_id is preferred. Accepts repeated multipart fields, a JSON array string, or comma-separated values.
Product carousel card URL variable 1. Optional, only required when the carousel template uses a URL button with a variable.
A media file to include with the template (for templates with IMAGE, VIDEO, or DOCUMENT header).
Success
POST /api/public/send-message HTTP/1.1
Host: {ISLASH_API_ENDPOINT}
X-USER-TOKEN: text
Content-Type: multipart/form-data
Accept: */*
Content-Length: 427
{
"session": "text",
"template_name": "text",
"identity": "text",
"variable_1": "text",
"button_url_variable_1": "text",
"catalog_id": "text",
"product_id": "text",
"product_ids": [
"text"
],
"catalog_fb_id": "text",
"thumbnail_product_id": "text",
"thumbnail_product_retailer_id": "text",
"product_retailer_id": "text",
"product_retailer_ids": [
"text"
],
"card_url_variable_1": "text",
"card_url_parameters": [
{
"card_index": 1,
"text": "text"
}
],
"media": "binary"
}Success
{
"meta": {
"code": "text",
"message": "text"
},
"data": {
"message": {},
"contact": {
"id": 1,
"identity": "text",
"type": "text",
"last_name": "text",
"first_name": "text"
}
}
}Last updated