Language

IActivity.AddMention(ChannelAccount, String, Boolean) Method

Definition

Adds a Mention entity for the given account and, optionally, prepends the mention markup to Text.

public Microsoft.Agents.Core.Models.IActivity AddMention(Microsoft.Agents.Core.Models.ChannelAccount account, string text = default, bool addText = true);
abstract member AddMention : Microsoft.Agents.Core.Models.ChannelAccount * string * bool -> Microsoft.Agents.Core.Models.IActivity
Public Function AddMention (account As ChannelAccount, Optional text As String = Nothing, Optional addText As Boolean = true) As IActivity

Parameters

account
ChannelAccount

The account being mentioned.

text
String

Optional display text for the mention. Defaults to Name.

addText
Boolean

When true (default), the <at> mention markup is prepended to the activity text.

Returns

This activity.

Applies to