Share via


DeploymentsOperationsExtensions.DeleteAtManagementGroupScopeAsync Method

Definition

Deletes a deployment from the deployment history.

public static System.Threading.Tasks.Task DeleteAtManagementGroupScopeAsync (this Microsoft.Azure.Management.ResourceManager.Fluent.IDeploymentsOperations operations, string groupId, string deploymentName, System.Threading.CancellationToken cancellationToken = default);
static member DeleteAtManagementGroupScopeAsync : Microsoft.Azure.Management.ResourceManager.Fluent.IDeploymentsOperations * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
<Extension()>
Public Function DeleteAtManagementGroupScopeAsync (operations As IDeploymentsOperations, groupId As String, deploymentName As String, Optional cancellationToken As CancellationToken = Nothing) As Task

Parameters

operations
IDeploymentsOperations

The operations group for this extension method.

groupId
String

The management group ID.

deploymentName
String

The name of the deployment.

cancellationToken
CancellationToken

The cancellation token.

Returns

Remarks

A template deployment that is currently running cannot be deleted. Deleting a template deployment removes the associated deployment operations. This is an asynchronous operation that returns a status of 202 until the template deployment is successfully deleted. The Location response header contains the URI that is used to obtain the status of the process. While the process is running, a call to the URI in the Location header returns a status of 202. When the process finishes, the URI in the Location header returns a status of 204 on success. If the asynchronous request failed, the URI in the Location header returns an error-level status code.

Applies to