HtmlWidgetCallToolHandler Delegate
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Delegate for handling htmlwidget/calltool invoke activities.
Sent when a widget calls a tool on the bot via the MCP Apps protocol.
public delegate System.Threading.Tasks.Task<Microsoft.Teams.Apps.InvokeResponse> HtmlWidgetCallToolHandler(Context<InvokeActivity<CallToolRequest>> context, CancellationToken cancellationToken = default);
type HtmlWidgetCallToolHandler = delegate of Context<InvokeActivity<CallToolRequest>> * CancellationToken -> Task<InvokeResponse>
Public Delegate Function HtmlWidgetCallToolHandler(context As Context(Of InvokeActivity(Of CallToolRequest)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of InvokeResponse)
Parameters
- context
- Context<InvokeActivity<CallToolRequest>>
The context for the invoke activity with a strongly-typed CallToolRequest value.
- cancellationToken
- CancellationToken
A cancellation token that can be used to cancel the operation.
Return Value
A task that represents the asynchronous operation. The task result contains the invoke response.