CostManagementAlertCollection.GetIfExistsAsync Method

Definition

Tries to get details for this resource from the service.

  • Request Path: /{scope}/providers/Microsoft.CostManagement/alerts/{alertId}
  • Operation Id: Alerts_Get
public virtual System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.CostManagement.CostManagementAlertResource>> GetIfExistsAsync (string alertId, System.Threading.CancellationToken cancellationToken = default);
abstract member GetIfExistsAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.CostManagement.CostManagementAlertResource>>
override this.GetIfExistsAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.CostManagement.CostManagementAlertResource>>
Public Overridable Function GetIfExistsAsync (alertId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of NullableResponse(Of CostManagementAlertResource))

Parameters

alertId
String

Alert ID.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

alertId is null.

Applies to