IPolicyAssignmentsOperations.GetByIdWithHttpMessagesAsync Método

Definição

Recupera a atribuição de política com a ID fornecida.

public System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.Management.ResourceManager.Fluent.Models.PolicyAssignmentInner>> GetByIdWithHttpMessagesAsync (string policyAssignmentId, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetByIdWithHttpMessagesAsync : string * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.Management.ResourceManager.Fluent.Models.PolicyAssignmentInner>>
Public Function GetByIdWithHttpMessagesAsync (policyAssignmentId As String, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of AzureOperationResponse(Of PolicyAssignmentInner))

Parâmetros

policyAssignmentId
String

A ID da atribuição de política a ser obtido. Use o formato '{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}'.

customHeaders
Dictionary<String,List<String>>

Os cabeçalhos que serão adicionados à solicitação.

cancellationToken
CancellationToken

O token de cancelamento.

Retornos

Exceções

Gerado quando a operação retornou um código de status inválido

Gerado quando não é possível desserializar a resposta

Gerado quando um parâmetro necessário é nulo

Comentários

A operação recupera a atribuição de política com a ID fornecida. As IDs de atribuição de política têm esse formato: '{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}'. Os escopos válidos são: grupo de gerenciamento (formato: '/providers/Microsoft.Management/managementGroups/{managementGroup}'), assinatura (formato: '/subscriptions/{subscriptionId}'), grupo de recursos (formato: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', ou recurso (formato: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}'.

Aplica-se a