Role Assignments - Delete

Rol atamalarını kapsama ve ada göre silin.

DELETE https://management.azure.com/{scope}/providers/Microsoft.Authorization/roleAssignments/{roleAssignmentName}?api-version=2022-04-01
DELETE https://management.azure.com/{scope}/providers/Microsoft.Authorization/roleAssignments/{roleAssignmentName}?api-version=2022-04-01&tenantId={tenantId}

URI Parametreleri

Name İçinde Gerekli Tür Description
roleAssignmentName
path True

string

Rol atamasının adı. Herhangi bir geçerli GUID olabilir.

scope
path True

string

İşlemin veya kaynağın kapsamı. Geçerli kapsamlar şunlardır: abonelik (biçim: '/subscriptions/{subscriptionId}'), kaynak grubu (biçim: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', veya kaynak (biçim: '/subscriptions/{subscriptionId}/resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}'

api-version
query True

string

Bu işlem için kullanılacak API sürümü.

tenantId
query

string

Kiracılar arası istek için kiracı kimliği

Yanıtlar

Name Tür Description
200 OK

RoleAssignment

Silinen rol atamasını döndürür.

204 No Content

Rol ataması zaten silinmiş veya yok.

Other Status Codes

ErrorResponse

İşlemin neden başarısız olduğunu açıklayan hata yanıtı.

İzinler

Bu API’yi çağırmak için aşağıdaki izinlere sahip bir rol atanması gerekir. Daha fazla bilgi için bkz. Azure yerleşik rolleri.

Microsoft.Authorization/roleAssignments/delete

Güvenlik

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation kullanıcı hesabınızın kimliğine bürünme

Örnekler

Delete role assignment

Sample Request

DELETE https://management.azure.com/subscriptions/a925f2f7-5c63-4b7b-8799-25a5f97bc3b2/providers/Microsoft.Authorization/roleAssignments/b0f43c54-e787-4862-89b1-a653fa9cf747?api-version=2022-04-01

Sample Response

{
  "properties": {
    "roleDefinitionId": "/providers/Microsoft.Authorization/roleDefinitions/0b5fe924-9a61-425c-96af-cfe6e287ca2d",
    "principalId": "ce2ce14e-85d7-4629-bdbc-454d0519d987",
    "principalType": "User",
    "scope": "/subscriptions/a925f2f7-5c63-4b7b-8799-25a5f97bc3b2"
  },
  "id": "/subscriptions/a925f2f7-5c63-4b7b-8799-25a5f97bc3b2/providers/Microsoft.Authorization/roleAssignments/b0f43c54-e787-4862-89b1-a653fa9cf747",
  "type": "Microsoft.Authorization/roleAssignments",
  "name": "b0f43c54-e787-4862-89b1-a653fa9cf747"
}

Tanımlar

Name Description
ErrorAdditionalInfo

Kaynak yönetimi hatası ek bilgileri.

ErrorDetail

Hata ayrıntısı.

ErrorResponse

Hata yanıtı

PrincipalType

Atanan asıl kimliğin asıl türü.

RoleAssignment

Rol Atamaları

ErrorAdditionalInfo

Kaynak yönetimi hatası ek bilgileri.

Name Tür Description
info

object

Ek bilgiler.

type

string

Ek bilgi türü.

ErrorDetail

Hata ayrıntısı.

Name Tür Description
additionalInfo

ErrorAdditionalInfo[]

Hata ek bilgileri.

code

string

Hata kodu.

details

ErrorDetail[]

Hata ayrıntıları.

message

string

Hata iletisi.

target

string

Hata hedefi.

ErrorResponse

Hata yanıtı

Name Tür Description
error

ErrorDetail

Hata nesnesi.

PrincipalType

Atanan asıl kimliğin asıl türü.

Name Tür Description
Device

string

ForeignGroup

string

Group

string

ServicePrincipal

string

User

string

RoleAssignment

Rol Atamaları

Name Tür Varsayılan değer Description
id

string

Rol atama kimliği.

name

string

Rol ataması adı.

properties.condition

string

Rol ataması koşulları. Bu, atanabileceği kaynakları sınırlar. Örneğin: @Resource[Microsoft.Storage/storageAccounts/blobServices/containers:ContainerName] StringEqualsIgnoreCase 'foo_storage_container'

properties.conditionVersion

string

Koşulun sürümü. Şu anda kabul edilen tek değer '2.0'

properties.createdBy

string

Atamayı oluşturan kullanıcının kimliği

properties.createdOn

string

Oluşturulduğu zaman

properties.delegatedManagedIdentityResourceId

string

Temsilci olarak atanan yönetilen kimlik kaynağının kimliği

properties.description

string

Rol atamasının açıklaması

properties.principalId

string

Asıl kimlik.

properties.principalType

PrincipalType

User

Atanan asıl kimliğin asıl türü.

properties.roleDefinitionId

string

Rol tanımı kimliği.

properties.scope

string

Rol atama kapsamı.

properties.updatedBy

string

Atamayı güncelleştiren kullanıcının kimliği

properties.updatedOn

string

Güncelleştirme zamanı

type

string

Rol atama türü.