Share via


NotificationBot Class

Definition

Provide utilities to send notification to varies targets (e.g., member, group, channel).

public class NotificationBot
type NotificationBot = class
Public Class NotificationBot
Inheritance
NotificationBot

Constructors

NotificationBot(BotAdapter, NotificationOptions)

Create new instance of the NotificationBot.

Methods

BuildTeamsBotInstallation(ConversationReference)

Create a TeamsBotInstallation instance with conversation reference.

FindAllChannelsAsync(Func<Channel,TeamDetails,Task<Boolean>>, CancellationToken)

Returns all Channel where predicate is true, and empty array otherwise. (Ensure the bot app is installed into the General channel, otherwise empty array will be returned.)

FindAllMembersAsync(Func<Member,Task<Boolean>>, SearchScope, CancellationToken)

Returns all Member where predicate is true, and empty array otherwise.

FindChannelAsync(Func<Channel,TeamDetails,Task<Boolean>>, CancellationToken)

Returns the first Channel where predicate is true, and null otherwise. (Ensure the bot app is installed into the General channel, otherwise null will be returned.)

FindMemberAsync(Func<Member,Task<Boolean>>, SearchScope, CancellationToken)

Returns the first Member where predicate is true, and null otherwise.

GetInstallationsAsync(CancellationToken)
Obsolete.

Get all targets where the bot is installed.

GetPagedInstallationsAsync(Nullable<Int32>, String, CancellationToken, Boolean)

Get a pagined list of targets where the bot is installed.

ValidateInstallationAsync(ConversationReference, CancellationToken)

Validate the installation by getting paged memebers.

Applies to