BotFrameworkAdapter.CreateConversationAsync Method

Definition

Overloads

CreateConversationAsync(String, String, MicrosoftAppCredentials, ConversationParameters, BotCallbackHandler, ConversationReference, CancellationToken)
Obsolete.

Creates a conversation on the specified channel. Overload receives a ConversationReference including the tenant.

CreateConversationAsync(String, String, AppCredentials, ConversationParameters, BotCallbackHandler, ConversationReference, CancellationToken)
Obsolete.

Creates a conversation on the specified channel. Overload receives a ConversationReference including the tenant.

CreateConversationAsync(String, String, MicrosoftAppCredentials, ConversationParameters, BotCallbackHandler, CancellationToken)

Creates a conversation on the specified channel.

CreateConversationAsync(String, String, AppCredentials, ConversationParameters, BotCallbackHandler, CancellationToken)

Creates a conversation on the specified channel.

CreateConversationAsync(String, String, MicrosoftAppCredentials, ConversationParameters, BotCallbackHandler, ConversationReference, CancellationToken)

Caution

This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.

Creates a conversation on the specified channel. Overload receives a ConversationReference including the tenant.

[System.Obsolete("This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.")]
public virtual System.Threading.Tasks.Task CreateConversationAsync (string channelId, string serviceUrl, Microsoft.Bot.Connector.Authentication.MicrosoftAppCredentials credentials, Microsoft.Bot.Schema.ConversationParameters conversationParameters, Microsoft.Bot.Builder.BotCallbackHandler callback, Microsoft.Bot.Schema.ConversationReference reference, System.Threading.CancellationToken cancellationToken);
[<System.Obsolete("This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.")>]
override this.CreateConversationAsync : string * string * Microsoft.Bot.Connector.Authentication.MicrosoftAppCredentials * Microsoft.Bot.Schema.ConversationParameters * Microsoft.Bot.Builder.BotCallbackHandler * Microsoft.Bot.Schema.ConversationReference * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function CreateConversationAsync (channelId As String, serviceUrl As String, credentials As MicrosoftAppCredentials, conversationParameters As ConversationParameters, callback As BotCallbackHandler, reference As ConversationReference, cancellationToken As CancellationToken) As Task

Parameters

channelId
String

The ID for the channel.

serviceUrl
String

The channel's service URL endpoint.

credentials
MicrosoftAppCredentials

The application credentials for the bot.

conversationParameters
ConversationParameters

The conversation information to use to create the conversation.

callback
BotCallbackHandler

The method to call for the resulting bot turn.

reference
ConversationReference

A conversation reference that contains the tenant.

cancellationToken
CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

A task that represents the work queued to execute.

Attributes

Remarks

To start a conversation, your bot must know its account information and the user's account information on that channel. Most _channels only support initiating a direct message (non-group) conversation.

The adapter attempts to create a new conversation on the channel, and then sends a conversationUpdate activity through its middleware pipeline to the callback method.

If the conversation is established with the specified users, the ID of the activity's Conversation will contain the ID of the new conversation.

Applies to

CreateConversationAsync(String, String, AppCredentials, ConversationParameters, BotCallbackHandler, ConversationReference, CancellationToken)

Caution

This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.

Creates a conversation on the specified channel. Overload receives a ConversationReference including the tenant.

[System.Obsolete("This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.")]
public virtual System.Threading.Tasks.Task CreateConversationAsync (string channelId, string serviceUrl, Microsoft.Bot.Connector.Authentication.AppCredentials credentials, Microsoft.Bot.Schema.ConversationParameters conversationParameters, Microsoft.Bot.Builder.BotCallbackHandler callback, Microsoft.Bot.Schema.ConversationReference reference, System.Threading.CancellationToken cancellationToken);
[<System.Obsolete("This method is now obsolete because the ConversationReference argument is now redundant. Use the overload without this argument.")>]
override this.CreateConversationAsync : string * string * Microsoft.Bot.Connector.Authentication.AppCredentials * Microsoft.Bot.Schema.ConversationParameters * Microsoft.Bot.Builder.BotCallbackHandler * Microsoft.Bot.Schema.ConversationReference * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function CreateConversationAsync (channelId As String, serviceUrl As String, credentials As AppCredentials, conversationParameters As ConversationParameters, callback As BotCallbackHandler, reference As ConversationReference, cancellationToken As CancellationToken) As Task

Parameters

channelId
String

The ID for the channel.

serviceUrl
String

The channel's service URL endpoint.

credentials
AppCredentials

The application credentials for the bot.

conversationParameters
ConversationParameters

The conversation information to use to create the conversation.

callback
BotCallbackHandler

The method to call for the resulting bot turn.

reference
ConversationReference

A conversation reference that contains the tenant.

cancellationToken
CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

A task that represents the work queued to execute.

Attributes

Remarks

To start a conversation, your bot must know its account information and the user's account information on that channel. Most _channels only support initiating a direct message (non-group) conversation.

The adapter attempts to create a new conversation on the channel, and then sends a conversationUpdate activity through its middleware pipeline to the callback method.

If the conversation is established with the specified users, the ID of the activity's Conversation will contain the ID of the new conversation.

Applies to

CreateConversationAsync(String, String, MicrosoftAppCredentials, ConversationParameters, BotCallbackHandler, CancellationToken)

Creates a conversation on the specified channel.

public virtual System.Threading.Tasks.Task CreateConversationAsync (string channelId, string serviceUrl, Microsoft.Bot.Connector.Authentication.MicrosoftAppCredentials credentials, Microsoft.Bot.Schema.ConversationParameters conversationParameters, Microsoft.Bot.Builder.BotCallbackHandler callback, System.Threading.CancellationToken cancellationToken);
override this.CreateConversationAsync : string * string * Microsoft.Bot.Connector.Authentication.MicrosoftAppCredentials * Microsoft.Bot.Schema.ConversationParameters * Microsoft.Bot.Builder.BotCallbackHandler * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function CreateConversationAsync (channelId As String, serviceUrl As String, credentials As MicrosoftAppCredentials, conversationParameters As ConversationParameters, callback As BotCallbackHandler, cancellationToken As CancellationToken) As Task

Parameters

channelId
String

The ID for the channel.

serviceUrl
String

The channel's service URL endpoint.

credentials
MicrosoftAppCredentials

The application credentials for the bot.

conversationParameters
ConversationParameters

The conversation information to use to create the conversation.

callback
BotCallbackHandler

The method to call for the resulting bot turn.

cancellationToken
CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

A task that represents the work queued to execute.

Remarks

To start a conversation, your bot must know its account information and the user's account information on that channel. Most _channels only support initiating a direct message (non-group) conversation.

The adapter attempts to create a new conversation on the channel, and then sends a conversationUpdate activity through its middleware pipeline to the callback method.

If the conversation is established with the specified users, the ID of the activity's Conversation will contain the ID of the new conversation.

Applies to

CreateConversationAsync(String, String, AppCredentials, ConversationParameters, BotCallbackHandler, CancellationToken)

Creates a conversation on the specified channel.

public virtual System.Threading.Tasks.Task CreateConversationAsync (string channelId, string serviceUrl, Microsoft.Bot.Connector.Authentication.AppCredentials credentials, Microsoft.Bot.Schema.ConversationParameters conversationParameters, Microsoft.Bot.Builder.BotCallbackHandler callback, System.Threading.CancellationToken cancellationToken);
override this.CreateConversationAsync : string * string * Microsoft.Bot.Connector.Authentication.AppCredentials * Microsoft.Bot.Schema.ConversationParameters * Microsoft.Bot.Builder.BotCallbackHandler * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function CreateConversationAsync (channelId As String, serviceUrl As String, credentials As AppCredentials, conversationParameters As ConversationParameters, callback As BotCallbackHandler, cancellationToken As CancellationToken) As Task

Parameters

channelId
String

The ID for the channel.

serviceUrl
String

The channel's service URL endpoint.

credentials
AppCredentials

The application credentials for the bot.

conversationParameters
ConversationParameters

The conversation information to use to create the conversation.

callback
BotCallbackHandler

The method to call for the resulting bot turn.

cancellationToken
CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Returns

A task that represents the work queued to execute.

Remarks

To start a conversation, your bot must know its account information and the user's account information on that channel. Most _channels only support initiating a direct message (non-group) conversation.

The adapter attempts to create a new conversation on the channel, and then sends a conversationUpdate activity through its middleware pipeline to the callback method.

If the conversation is established with the specified users, the ID of the activity's Conversation will contain the ID of the new conversation.

Applies to