MessageFactory.Text(String, String, String) Method

Definition

Returns a simple text message.

public static Microsoft.Bot.Schema.Activity Text (string text, string ssml = default, string inputHint = default);
static member Text : string * string * string -> Microsoft.Bot.Schema.Activity
Public Shared Function Text (text As String, Optional ssml As String = Nothing, Optional inputHint As String = Nothing) As Activity

Parameters

text
String

The text of the message to send.

ssml
String

Optional, text to be spoken by your bot on a speech-enabled channel.

inputHint
String

Optional, indicates whether your bot is accepting, expecting, or ignoring user input after the message is delivered to the client. One of: "acceptingInput", "ignoringInput", or "expectingInput". Default is "acceptingInput".

Returns

A message activity containing the text.

Examples

// Create and send a message.
var message = MessageFactory.Text("Hello World");
await context.SendActivity(message);

Applies to