A chat message sent between a User and a Bot. Messages from the bot to the user come in two flavors:
- reactive messages are messages sent from the Bot to the User as a reply to an incoming message from the user.
- proactive messages are messages sent from the Bot to the User in response to some external event like an alarm triggering.
In the reactive case the you should copy the address field from the incoming message to the outgoing message (if you use the Message builder class and initialize it with the session this will happen automatically) and then set the text or attachments. For proactive messages you’ll need save the address from the incoming message to an external storage somewhere. You can then later pass this in to UniversalBot.beginDialog() or copy it to an outgoing message passed to UniversalBot.send().
Composing a message to the user using the incoming address object will by default send a reply to the user in the context of the current conversation. Some channels allow for the starting of new conversations with the user. To start a new proactive conversation with the user simply delete the conversation field from the address object before composing the outgoing message.
Address routing information for the event. Save this field to external storage somewhere to later compose a proactive message to the user.
SDK thats processing the event. Will always be 'botbuilder'.
Hint for how clients should layout multiple attachments. The default value is 'list'.
For incoming messages contains attachments like images sent from the user. For outgoing messages contains objects like cards or images to send to the user.
Structured objects passed to the bot or user.
Hint for clients letting them know if the bot is expecting further input or not. The built-in prompts will automatically populate this value for outgoing messages.
Local time when message was sent (set by client or bot, Ex: 2016-09-23T13:07:49.4714686-07:00.)
The original source of the event (i.e. 'facebook', 'skype', 'slack', etc.)
The original event in the sources native schema. For outgoing messages can be used to pass source specific event data like custom attachments.
Spoken message as Speech Synthesis Markup Language.aspx).
Text to be displayed by as fall-back and as short description of the message content in e.g. list of recent conversations.
Format of text fields. The default value is 'markdown'.
Identified language of the message text if known.
UTC Time when message was sent (set by service.)
Defines type of event. Should be 'message' for an IMessage.