Views: 6355
Last Modified: 29.11.2017

You find details about what is context application here.


To work with context, you need to complete several actions:

  1. Creating an Application. You can register a hidden application, then it will not be displayed on the text input panel.
  2. Send (or update) any message with attached keyboard or from menu.
  3. You must input application identifier in the parameters of keyboard button or menu item.

Method call:
restCommand('imbot.message.add', Array(
   "DIALOG_ID" => 2,
   "BOT_ID" => 17,
   "MESSAGE" => "Hello! My name is ChatBot :)",
   "KEYBOARD" => [{"TEXT":"Open App","APP_ID":11}],
   "MENU" => [{"TEXT":"Open App","APP_ID":11}]

), $_REQUEST["auth"]);

aside from APP_ID, you can input ant line into parameter APP_PARAMS; when your IFRAME will open, the data will be transferred to parameter BUTTON_PARAMS.

You can find IFRAME-processor development rules and limitations in this documentation. When creating a message, you can use one of two options – KEYBOARD or MENU.





Courses developed by Bitrix24