AlertRules interface

Interface representing a AlertRules.

Methods

createOrUpdate(string, string, AlertRuleResource, AlertRulesCreateOrUpdateOptionalParams)

Creates or updates a classic metric alert rule.

delete(string, string, AlertRulesDeleteOptionalParams)

Deletes a classic metric alert rule

get(string, string, AlertRulesGetOptionalParams)

Gets a classic metric alert rule

listByResourceGroup(string, AlertRulesListByResourceGroupOptionalParams)

List the classic metric alert rules within a resource group.

listBySubscription(AlertRulesListBySubscriptionOptionalParams)

List the classic metric alert rules within a subscription.

update(string, string, AlertRuleResourcePatch, AlertRulesUpdateOptionalParams)

Updates an existing classic metric AlertRuleResource. To update other fields use the CreateOrUpdate method.

Method Details

createOrUpdate(string, string, AlertRuleResource, AlertRulesCreateOrUpdateOptionalParams)

Creates or updates a classic metric alert rule.

function createOrUpdate(resourceGroupName: string, ruleName: string, parameters: AlertRuleResource, options?: AlertRulesCreateOrUpdateOptionalParams): Promise<AlertRuleResource>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

ruleName

string

The name of the rule.

parameters
AlertRuleResource

The parameters of the rule to create or update.

options
AlertRulesCreateOrUpdateOptionalParams

The options parameters.

Returns

delete(string, string, AlertRulesDeleteOptionalParams)

Deletes a classic metric alert rule

function delete(resourceGroupName: string, ruleName: string, options?: AlertRulesDeleteOptionalParams): Promise<void>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

ruleName

string

The name of the rule.

options
AlertRulesDeleteOptionalParams

The options parameters.

Returns

Promise<void>

get(string, string, AlertRulesGetOptionalParams)

Gets a classic metric alert rule

function get(resourceGroupName: string, ruleName: string, options?: AlertRulesGetOptionalParams): Promise<AlertRuleResource>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

ruleName

string

The name of the rule.

options
AlertRulesGetOptionalParams

The options parameters.

Returns

listByResourceGroup(string, AlertRulesListByResourceGroupOptionalParams)

List the classic metric alert rules within a resource group.

function listByResourceGroup(resourceGroupName: string, options?: AlertRulesListByResourceGroupOptionalParams): PagedAsyncIterableIterator<AlertRuleResource, AlertRuleResource[], PageSettings>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

options
AlertRulesListByResourceGroupOptionalParams

The options parameters.

Returns

listBySubscription(AlertRulesListBySubscriptionOptionalParams)

List the classic metric alert rules within a subscription.

function listBySubscription(options?: AlertRulesListBySubscriptionOptionalParams): PagedAsyncIterableIterator<AlertRuleResource, AlertRuleResource[], PageSettings>

Parameters

options
AlertRulesListBySubscriptionOptionalParams

The options parameters.

Returns

update(string, string, AlertRuleResourcePatch, AlertRulesUpdateOptionalParams)

Updates an existing classic metric AlertRuleResource. To update other fields use the CreateOrUpdate method.

function update(resourceGroupName: string, ruleName: string, alertRulesResource: AlertRuleResourcePatch, options?: AlertRulesUpdateOptionalParams): Promise<AlertRuleResource>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

ruleName

string

The name of the rule.

alertRulesResource
AlertRuleResourcePatch

Parameters supplied to the operation.

options
AlertRulesUpdateOptionalParams

The options parameters.

Returns