MetricsAdvisorAdministrationClient.CreateAlertConfigurationAsync Method

Definition

Creates an AnomalyAlertConfiguration and assigns it a unique ID.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration>> CreateAlertConfigurationAsync (Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration alertConfiguration, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateAlertConfigurationAsync : Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration>>
override this.CreateAlertConfigurationAsync : Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.AI.MetricsAdvisor.Models.AnomalyAlertConfiguration>>
Public Overridable Function CreateAlertConfigurationAsync (alertConfiguration As AnomalyAlertConfiguration, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of AnomalyAlertConfiguration))

Parameters

alertConfiguration
AnomalyAlertConfiguration

Specifies how the created AnomalyAlertConfiguration should be configured.

cancellationToken
CancellationToken

A CancellationToken controlling the request lifetime.

Returns

A Response<T> containing the result of the operation. The result is an AnomalyAlertConfiguration instance containing information about the created configuration.

Exceptions

alertConfiguration or alertConfiguration.Name is null.

alertConfiguration.Name is empty.

Applies to