The com.innovaphone.discussion published in the model an URL, which can be used to include a messages iframe. This way a messages discussion can be added to any item in an app. The link to an item in the App is done with tags assigned to the discussion window.
The client consumeApi function is used to access the Api:
var dis = start.consumeApi("com.innovaphone.discussion")
The URL to open the iframe is fond in info of the provider model
var model = dis.model[dis.providers[0]];
if (model) {
if (model.url && model.info && model.info.url) {
var url = model.url.slice(0, model.url.lastIndexOf("/") + 1) + model.info.url + "?name=" + dis.providers[0] + "&topic=" + <appname> + "&scheme=dark&tag=" + <appitem>
}
}
The following information is includeded in the URL
The following URL arguments shall be used for the discussion