Working with Metadata

Learn the types and methods for working with Metadata in Modern Chat

One of the most powerful tools Modern Chat empowers brands with is its support for custom metadata. Within the Response Agent View, agents can see important contextual information about each interaction at a glance.

Metadata empowers agents by providing them a larger scope of the situation that leads the customer to reach out using Modern Chat. It may also provide actionable analytical insight into a brand's audience, enabling them to better understand their customer base.

Types of Metadata

There are two types of metadata Modern Chat supports: Author and Post.

Author metadata provides essential information about the author of a message. This may include their name, address, membership status, balance, etc. All of this data is updated with each message, and are sourced from metadata fields served by the page from which the author writes the message.

Post metadata relates to the specific post. For example, this could be the page URL the author is sending the message from or the browser version the author is using to send the message.

Accepted value types are Number, String, Boolean and, unlike properties, a function that computes one of these accepted types dynamically. Nested objects are not supported at this time. Each object must be a flat key/value pairs object.

For example:

Valid:

{
    "key": "value",
    "key2": "value2"
}

Invalid:

{
    "key": {
        "key2": "value2"
    }
}

📘

In the event that there is a case where it's absolutely critical that nested objects appear here, they should be converted to JSON and passed as an escaped string. For example: "escapedJson": "{ \"key2\": \"value2\" }"


Did this page help you?