Skip to main content

Channel-wide Metadata

Channel-wide Metadata is a JSON object which can be applied to all the trees in a Channel. This metadata can be a data source ID, API path for an advanced function or even a basic greeting response. You can edit the metadata in the "Tree Settings" of a "Channel".

You can make use of channel-wide metadata to improve the re-usability and reduce the channel deployment time of a tree build. For example, in the scenario where you are deploying a FAQ tree build to a new channel, you can keep the exact same tree build and simply change the data source ID in the new channel's metadata setting.

Expected Outcome

In the following example, the user applied different data source IDs in the Channel-wide Metadata for Facebook Messenger & WhatsApp. You can clearly spot out that the content are slightly different but the conversation flow is the same.

Facebook Level 5 FAQ Chatbot
Facebook Level 5 FAQ Chatbot
WhatsApp Level 5 FAQ Chatbot
The same FAQ chatbot build deploys on Facebook & WhatsApp
Datasource with Facebook
Datasource with Facebook
Datasource with WhatsApp
The Data Sources are different for Facebook & WhatsApp

Getting Hands-On

  1. You should decide which part of your chatbot build will be changed in different channels.

  2. Locate that part of the chatbot build and apply accordingly. For example, if you want to use a different data source for a different channel, you can locate and replace all the original data source ID with in the collectionName.

Example Pre-action

return new Promise(async (resolve, reject) => {
console.log("in Save Category 1 answers")
let result = await this.fetchDataFromDataSource({
filter: {}
console.log("result", result)
result = this.lodash.uniqBy(result, "Category 1")
console.log("result", result)
result = this.lodash.reject(result, { "Category 1": "" })
console.log("result", result)

result = this.lodash.sortBy(result, "Category 1 Priority")

this.member.botMeta.tempData.currentAnswers = => obj["Category 1"])
this.member.botMeta.tempData.listLength = result.length

member: this.member,
  1. Head to the specific channel and add the metadata JSON object to "Channel-wide Metadata" under "Tree Settings".
Channel-wide Metadata
Channel-wide Metadata

Below is a sample metadata object for FAQ data source:

"": "5ea26a9d54dasd3dasd2_faq_level_5",
  • For the text after metadata. you may designate any names to fit your use case.
  • For the string after "", you may input the actual data (e.g. data source ID or API path) to be applied in a specific channel.