NotificationHubClient.SendNotificationAsync Method

Definition

Overloads

SendNotificationAsync(Notification)

Sends a notification to a non-empty set of tags (max 20). This is equivalent to a tag expression with boolean ORs ("||").

SendNotificationAsync(Notification, IEnumerable<String>)

Asynchronously sends a notification to a non-empty set of tags (max 20). This is equivalent to a tag expression with boolean ORs ("||").

SendNotificationAsync(Notification, String)

Sends a notification to a tag expression (a single tag "tag" is a valid tag expression).

SendNotificationAsync(Notification)

Sends a notification to a non-empty set of tags (max 20). This is equivalent to a tag expression with boolean ORs ("||").

public System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome> SendNotificationAsync (Microsoft.Azure.NotificationHubs.Notification notification);
member this.SendNotificationAsync : Microsoft.Azure.NotificationHubs.Notification -> System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome>

Parameters

notification
Notification

The notification to send.

Returns

NotificationOutcome which describes the result of the Send operation.

Exceptions

notification

SendNotificationAsync(Notification, IEnumerable<String>)

Asynchronously sends a notification to a non-empty set of tags (max 20). This is equivalent to a tag expression with boolean ORs ("||").

public System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome> SendNotificationAsync (Microsoft.Azure.NotificationHubs.Notification notification, System.Collections.Generic.IEnumerable<string> tags);
member this.SendNotificationAsync : Microsoft.Azure.NotificationHubs.Notification * seq<string> -> System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome>

Parameters

notification
Notification

The notification to send.

tags
IEnumerable<String>

A non-empty set of tags (max 20 tags). Each string in the set can contain a single tag.

Returns

NotificationOutcome which describes the result of the Send operation.

Exceptions

Thrown when notification or tag object is null

notification.Tag property should not be null or tags argument should contain at least one tag

SendNotificationAsync(Notification, String)

Sends a notification to a tag expression (a single tag "tag" is a valid tag expression).

public System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome> SendNotificationAsync (Microsoft.Azure.NotificationHubs.Notification notification, string tagExpression);
member this.SendNotificationAsync : Microsoft.Azure.NotificationHubs.Notification * string -> System.Threading.Tasks.Task<Microsoft.Azure.NotificationHubs.NotificationOutcome>

Parameters

notification
Notification

The notification to send.

tagExpression
String

A tag expression is any boolean expression constructed using the logical operators AND (&&), OR (||), NOT (!), and round parentheses. For example: (A || B) && !C. If an expression uses only ORs, it can contain at most 20 tags. Other expressions are limited to 6 tags. Note that a single tag "A" is a valid expression.

Returns

NotificationOutcome which describes the result of the Send operation.

Exceptions

notification

notification.Tag property should be null

Applies to