DenyAssignmentCollection.CreateOrUpdate Method

Definition

Create or update a deny assignment by scope and name.

  • Request Path. : /{scope}/providers/Microsoft.Authorization/denyAssignments/{denyAssignmentId}.
  • Operation Id. : DenyAssignments_CreateOrUpdate.
  • Default Api Version. : 2024-07-01-preview.
public virtual Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Authorization.DenyAssignmentResource> CreateOrUpdate(Azure.WaitUntil waitUntil, string denyAssignmentId, Azure.ResourceManager.Authorization.DenyAssignmentData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.Authorization.DenyAssignmentData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Authorization.DenyAssignmentResource>
override this.CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.Authorization.DenyAssignmentData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Authorization.DenyAssignmentResource>
Public Overridable Function CreateOrUpdate (waitUntil As WaitUntil, denyAssignmentId As String, data As DenyAssignmentData, Optional cancellationToken As CancellationToken = Nothing) As ArmOperation(Of DenyAssignmentResource)

Parameters

waitUntil
WaitUntil

Completed if the method should wait to return until the long-running operation has completed on the service; Started if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples.

denyAssignmentId
String

The ID of the deny assignment to get.

data
DenyAssignmentData

Parameters for the deny assignment.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

denyAssignmentId or data is null.

denyAssignmentId is an empty string, and was expected to be non-empty.

Applies to