microsoft/teams.net
Publicmirrored fromhttps://github.com/microsoft/teams.netAvailable
Libraries/Microsoft.Teams.Cards/Actions/InvokeAction.cs
24lines · modecode
| 1 | // Copyright (c) Microsoft Corporation. All rights reserved. |
| 2 | // Licensed under the MIT License. |
| 3 | |
| 4 | using Microsoft.Teams.Common; |
| 5 | |
| 6 | namespace Microsoft.Teams.Cards; |
| 7 | |
| 8 | /// <summary> |
| 9 | /// Defines an invoke action. This action is used to trigger a bot action. |
| 10 | /// </summary> |
| 11 | public class InvokeAction : SubmitAction |
| 12 | { |
| 13 | /// <summary> |
| 14 | /// Initializes a new instance of the <see cref="InvokeAction"/> class. |
| 15 | /// </summary> |
| 16 | /// <param name="value">The value to submit when the action is invoked.</param> |
| 17 | public InvokeAction(object value) |
| 18 | { |
| 19 | Data = new Union<string, SubmitActionData>(new SubmitActionData |
| 20 | { |
| 21 | Msteams = new InvokeSubmitActionData(value) |
| 22 | }); |
| 23 | } |
| 24 | } |