Stella Platform Documentation

Stella Platform Documentation

  • Docs
  • Procedures
  • Reference
  • FAQ
  • Bot API
  • API
  • Languages iconEnglish
    • 中文

›WhatsApp

Overview

  • Documentation Guide

Get Started

  • Introduction
  • Recent Updates
  • Best Practices
  • Chatbot Template

Bot Builder

  • Workspace
  • Node
  • Attachment ID

Node Inspector

  • Tree ID & Composite ID
  • Basic Information
  • Triggers
  • Responses
  • Actions
  • Redirect
  • Member Tagging
  • Analytics
  • NLP
  • Advance

Facebook

  • Message Types
  • Button Types
  • Persistent Menu
  • Access Token
  • One-Time Notification
  • N-Time Notification (Beta)

Instagram

  • Message Types

WhatsApp

  • Overview
  • Setup Procedure
  • Message Types

Web Chat

  • Overview
  • Message Types
  • Button Types

WeChat

  • Message Types

Slack

  • Message Types

Telegram

  • Message Types

Integrations

  • Dialogflow
  • Stripe
  • LUIS
  • Custom Inbox Integration

Data Source

  • Data Source

Media Library

  • Media Library

Channels

  • Overview
  • Webhooks
  • Channel-wide Metadata
  • Business Availability
  • Facebook
  • Instagram
  • Web Chat
  • WhatsApp
  • WeChat
  • Slack (Public App)
  • Slack (Custom App)
  • Teamwork
  • Zendesk
  • Custom Platform

Analytics

  • Members
  • Dashboard
  • PSID

Settings

  • Overview
  • Locale
  • Pairing Channels
  • Role-based Access Control
  • Access Token
  • Audit Trail

Push Panel

  • Push Content
  • Audience
  • Analytics

Log

  • Log

WhatsApp Message Types

There are various types of message content that can be sent to your users:

  • Text
  • Image
  • Audio
  • Video
  • File
  • Location
  • Contact
  • Interactive Message
  • WhatsApp Message Template

Text

{
  type: "TEXT",
  text: "Hello World!",
}
PropertyDescriptionRequired
typeTEXTY
textString; Limited to 2000 charactersY

Image

{
  type: "IMAGE",
  text: "I am Sanuker!",
  url: "http://image.png",
}
PropertyDescriptionRequired
typeIMAGEY
textString; caption for WhatsAppN
urlURL of the image fileY

Tips:

  • Image must be a valid image file format, including .jpeg and .png
  • Maximum file size is 16MB

Audio

{
  type: "AUDIO",
  url: "http://audio.aac",
}
PropertyDescriptionRequired
typeAUDIOY
urlURL of the audio fileY

Tips:

  • Audio must be a valid audio file format, including .aac

Video

{
  type: "VIDEO",
  url: "http://video.mp4",
}
PropertyDescriptionRequired
typeVIDEOY
urlURL of the video fileY

Tips:

  • Video must be a valid video file format, including .mp4
  • Maximum file size is 16MB

File

{
  "type": "FILE",
  "filename": "Test",
  "url": "http://file.pdf",
  "text": "test122344"
}
PropertyDescriptionRequired
typeFILEY
urlURL of the file attachmentY

Tips:

  • File must be a valid file format, including .pdf
  • Maximum file size is 16MB

Location

{
  "type": "LOCATION",
  "text": "ABC Company",
  "address": "Room C, 1/F, DFG Building, 101 Rainbow Road",
  "lat": 22.31586918460027,
  "long": 114.20883121469535
}
PropertyDescriptionRequired
typeLOCATIONY
textString; Name of locationN
addressString; Addresso of LocationN
latLatitudeY
longLongitudeY

Contact

{
  "type": "CONTACTS",
  "contacts": [
    {
      "id": "YXpJfusT",
      "name": {
        "formatted_name": "John Lee",
        "first_name": "John",
        "last_name": "Lee",
        "prefix": "Mr"
      },
      "addresses": [
        {
          "type": "work",
          "city": "Hong Kong",
          "street": "Rainbow Road 131, ABC Building"
        }
      ],
      "emails": [
        {
          "type": "work",
          "email": "workmail123@gmail.com"
        }
      ],
      "phones": [
        {
          "type": "cell",
          "phone": "+852 1234 5678"
        }
      ],
      "urls": [
        {
          "type": "work",
          "url": "www.sanuker.com"
        }
      ],
      "org": {
        "company": " Sanuker"
      }
    }
  ]
}
PropertyDescriptionRequired
nameString; name of contactY
addressString; contact addressN
birthdayString; dateN
emailsString; email addressN
orgString; company nameN
phonesString; phone numberN
urlsString; urlN

Each object in Contact contains one or multiple optional parameters, you can refer to here for details.


Interactive Messages

Interactive Messages allow the users to response quickly by providing buttons to click on. Users cannot select more than one option at the same time from a list or button message, but they can go back and re-open a previous message.

List Messages

{
  "type": "WHATSAPP_LIST",
  "header": {
    "type": "text",
    "text": "Hello 👋🏻"
  },
  "body": {
    "text": "Sanuker provides chatbot solutions."
  },
  "footer": {
    "text": "Facebook and WhatsApp Official Business Partner"
  },
  "action": {
    "button": "Menu",
    "sections": [
      {
        "title": "section title",
        "rows": [
          {
            "payload": "GREETINGS",
            "title": "Main Menu",
            "description": "Hello!"
          },
          {
            "payload": "ABOUT_SANUKER",
            "title": "About Sanuker",
            "description": "Who are you?"
          }
        ]
      }
    ]
  }
}
PropertyDescriptionRequired?
HeaderThe header of your list message; It can be a text or media: "Image", "Video", "Document"N
BodyThe body content of the message (Maximum of 1024 characters)Y
FooterThe footer content (Maximum of 60 characters)N
ActionInside action, you must nest:
- a button field with your button’s content, and
- at least one section object (maximum of 10)

Inside section, you must add at least one rows object
Y

action Object

PropertyDescriptionRequired?
buttonButton content. It cannot be an empty string and must be unique within the message (Maximum of 20 characters)Y
sectionsArray of section objects. There is a minimum of 1 and maximum of 10Y

section Object

PropertyDescriptionRequired?
titleTitle of the sectionY (if the message has more than one section.)
rowsContains a list of rows. Each row must have a title and an ID. You can add a description, but it is optionalY

Reply Buttons

{
  "type": "WHATSAPP_REPLY_BUTTONS",
  "header": {
    "type": "image",
    "image": {
      "id": "2e5a7aad-e8c7-43ba-ad5e-b298bb32f8af"
    }
  },
  "body": {
    "text": "Sanuker provides chatbot solutions."
  },
  "footer": {
    "text": "Facebook and WhatsApp Official Business Partner"
  },
  "action": {
    "buttons": [
      {
        "type": "reply",
        "reply": {
          "payload": "GREETINGS",
          "title": "Main Menu"
        }
      },
      {
        "type": "reply",
        "reply": {
          "payload": "ABOUT_SANUKER",
          "title": "About Sanuker"
        }
      }
    ]
  }
}
PropertyDescriptionRequired
HeaderThe header of your list message; It can be a text or media: "Image", "Video", "Document"N
BodyThe body content of the message (Maximum of 1024 characters)Y
FooterThe footer content (Maximum of 60 characters)N
ActionYou must add at least one button, and include type and title.You cannot add more than 3 buttonsY

action Object

PropertyDescriptionRequired?
buttonsA button can contain the following parameters:
type: only supported type is reply (for Reply Button Messages)
title: Button title. It cannot be an empty string and must be unique within the message (Maximum of 20 characters)
Y

Single Product Message

"type": "WHATSAPP_PRODUCT",
  "body": {
    "text": "Check out our Bag of the Day"
  },
  "action": {
    "catalogId": "4928452840550143",
    "productId": "03-Pack"
  }
PropertyDescriptionRequired
bodyThe body content of the message (Maximum of 1024 characters)N
footerThe footer content (Maximum of 60 characters)N
actionMust contain
- catalogId: an ID for the catalog you want to use for this message. Retrieve this ID via Commerce Manager.
- productId: a product’s unique identifier (Content ID).
Y

Multi Product Message

Multi-Product Message can only contain a selection of up to 30 products from the inventory.
{
  "type": "WHATSAPP_PRODUCT_LIST",
  "header": {
    "type": "text",
    "text": "Fall Collection"
  },
  "body": {
    "text": "Click view items to see our Fall Collection"
  },
  "action": {
    "catalogId": "4928452840550143",
    "sections": [
      {
        "title": "Urban Essentials",
        "productIds": [
          "01-Pack",
          "02-Bag"
        ]
      },
      {
        "title": "Hiking Essentials",
        "productIds": [
          "03-Pack"
        ]
      }
    ]
  }
}
PropertyDescriptionRequired
headertype must be text. Contain a text object with the desired contentY
bodyThe footer content (Maximum of 1024 characters)Y
footerThe footer content (Maximum of 60 characters)N
actionMust contain
- catalogId: an ID for the catalog you want to use for this message. Retrieve this ID via Commerce Manager
- sections: Array of section objects. You must include at least one section
Y

sections field

PropertyDescriptionRequired
titlea title for each sectionY
productIdsproduct’s unique identifier (Content ID)Y

WhatsApp Message Template

{
  "type": "TEMPLATE",
  "components": [
    {
      "parameters": [
        {
          "image": {
            "id": "57ec1287-6915-4a44-8dc9-9caa620385e1"
          },
          "type": "image"
        }
      ],
      "type": "header"
    },
    {
      "type": "button",
      "sub_type": "quick_reply",
      "index": "0",
      "parameters": [
        {
          "type": "payload",
          "payload": "Contact Sanuker"
        }
      ]
    },
    {
      "type": "button",
      "sub_type": "quick_reply",
      "index": "1",
      "parameters": [
        {
          "type": "payload",
          "payload": "GREETINGS"
        }
      ]
    },
    {
      "type": "button",
      "sub_type": "quick_reply",
      "index": "2",
      "parameters": [
        {
          "type": "payload",
          "payload": "ABOUT_SANUKER"
        }
      ]
    }
  ],
  "languagePolicy": "deterministic",
  "languageCode": "en",
  "namespace": "bc3ac5dd_6dfd_2345_d5f7_123456789bf",
  "elementName": "multiple_button_test_1",
  "accountId": "1234567890"
}

Please note that the components field is required, otherwise, the response cannot be sent out while using sendResponses of Bot API

Template Details

PropertyDescriptionRequired?
NameCan only contain lowercase alphanumeric characters and underscores ( _ ); No other characters or white space are allowedY
CategorySelect the correct category of your template; See list of supported categoriesY
LanguageSelect the correct language of your template; The template name will be the same for all translations; You will specify the language field when sending out the template; See list of supported languagesY
ContentThe content of your message template; Support parameter placeholders in the format of {{1}}Y
HeaderThe header of your message template; It can be a text or media: "Image", "Video", "Document"N
BodyThe body of your message template (Character Limit: 1024)Y
FooterThe text footer of your message templateN
ButtonsThe button(s) of your message template; Call-to-action or Quick Reply; 3 buttons max.N

Maximum Character Limit

PropertyCharacter Limit
Body (Without Header/Footer)Up to 1024 characters
Body (With Header/Footer)Up to 1024 characters
Header60 characters
Footer60 characters

Please note that, within a WhatsApp Message Template, the character limit does not apply to the varaiable.

Setup Procedure

  1. Open "Response Builder" and choose the response type "WhatsApp Message Template".

Create a WhatsApp Message Template Response
  1. Choose any existing "Message Template". Please make sure your have completed the Message Template Submission process in order to view your existing message templates.

  2. Set the Language Policy as Deterministic.

  3. Choose the Language of your Message Template.

  1. Please see the optional settings below:
  • Add payload if your Message Template has a Quick Reply button.

Add Payload Buttons to WhatsApp Message Template
  • Add Media ID or url if your Header has multimedia files like image or video.

Add Media to WhatsApp Message Template
← Setup ProcedureOverview →
  • Text
  • Image
  • Audio
  • Video
  • File
  • Location
  • Contact
  • Interactive Messages
    • List Messages
    • Reply Buttons
    • Single Product Message
    • Multi Product Message
  • WhatsApp Message Template
    • Template Details
    • Maximum Character Limit
    • Setup Procedure
Stella Platform Documentation
Docs
Get StartedBot API ReferenceAPI ReferenceStandard Procedures
Community
FAQUser ShowcaseChat with Us
Copyright © 2023 Sanuker Inc. Limited