Rich Messaging Native Message Support

Overview

Quiq supports many Universal Rich Message formats that allow you to define a message using Quiq’s UI or API language, and it is automatically translated for all messaging platforms Quiq supports. However, if you are needing to make use of a platform specific feature you can also use that platform's Native Message format. This article describes these “Native Messages” (aka Proxy Interactions).

Native Messages Snippet (In the UI)

When adding a snippet in the UI in the Message Catalog, an Admin can add a platform specific version format by:

1. Clicking the Add Platform Specific Version button and selecting the platform
2. Click the Plus button in the Text field and select Proxy Interaction
3. Add the JSON in the platform’s native JSON format
4. Add transcript hints to use when displaying this message to the agent. This include: Selecting an icon, setting a Description, Primary Heading, and Secondary Heading.

You will want to test this message with a real conversation on the given platform to verify you have everything defined correctly.

Example Apple Messages for Business Native Message Payloads

Apple Messages for Business is a rich platform that supports many different rich message types.

One thing to note is that in Apple’s native format you base64 encode your images into the payload. Quiq instead supports specifying an attribute labeled xQuiqPublicUrl. When you use this attribute Quiq will automatically download the image specified in the URL, base64 encode it, and place it in the ABC payload.

Here is an example of creating an advanced list picker that describes winter sales, this is the JSON payload you would place for the message in the Message Catalog editor:

{
  "interaction": {
    "payload": {
      "receivedMessage": {
        "style": "large",
        "title": "CHECK OUT OUR WINTER SALES ⛄",
        "subtitle": "👆Tap to see the great deals!",
        "imageIdentifier": "I_MAIN"
      },
      "replyMessage": {
        "title": "Give me more info on:"
      },
      "data": {
        "version": "1.0",
        "requestIdentifier": "fb291c92-a596-4150-8938-5cba6b8dcbd1",
        "images": [
          {
            "identifier": "I_MAIN",
            "xQuiqPublicUrl": "https://i.imgur.com/rXHCbKp.jpg"
          },
          {
            "identifier": "I_1",
            "xQuiqPublicUrl": "https://i.imgur.com/0caz8EW.jpg"
          },
          {
            "identifier": "I_2",
            "xQuiqPublicUrl": "https://i.imgur.com/udawcmQ.jpg"
          },
          {
            "identifier": "I_3",
            "xQuiqPublicUrl": "https://i.imgur.com/iHungtD.jpg"
          },
          {
            "identifier": "I_4",
            "xQuiqPublicUrl": "https://i.imgur.com/rCBeSwo.jpg"
          }
        ],
        "listPicker": {
          "sections": [
            {
              "items": [
                {
                  "subtitle": "$39.99",
                  "imageIdentifier": "I_1",
                  "identifier": "0",
                  "style": "default",
                  "order": 0,
                  "title": "Tinted Goggles"
                },
                {
                  "subtitle": "$69.99",
                  "imageIdentifier": "I_2",
                  "identifier": "1",
                  "style": "default",
                  "order": 1,
                  "title": "White Ski Boots"
                },
                {
                  "subtitle": "$79.99",
                  "imageIdentifier": "I_3",
                  "identifier": "2",
                  "style": "default",
                  "order": 2,
                  "title": "Snow Board Bindings"
                },
                {
                  "subtitle": "$49.99",
                  "imageIdentifier": "I_4",
                  "identifier": "3",
                  "style": "default",
                  "order": 3,
                  "title": "Orange Ski Helmet"
                }
              ],
              "title": "Select all items you would like more info on",
              "multipleSelection": true,
              "order": 0
            }
          ]
        }
      },
      "useLiveLayout": true,
      "bid": "com.apple.messages.MSMessageExtensionBalloonPlugin:0000000000:com.apple.icloud.apps.messages.business.extension"
    }
  }
}

For this example message we also set the following Transcript Hints:

  • Icon: The list icon
  • Description: Snow sales picker (4 items)
  • Primary Heading: CHECK OUT OUR WINTER SALES ⛄

Other Native Message Types

These same principals above can be applied to other Apple Messages native message types, as well as other platforms such as RCS Business Messaging , Facebook Messenger, etc.

Native Messages In API calls

All of Quiq’s message related API’s support sending Native Messages through the proxyInteraction property as well as the transcriptHints property. The same values as above can be used in these properties. For more details check out the Proxy Interaction section of the Messaging Guide.