Permissions - Remove Permission

删除对用户或组的安全令牌的指定权限。

DELETE https://dev.azure.com/{organization}/_apis/permissions/{securityNamespaceId}/{permissions}?descriptor={descriptor}&api-version=6.0
DELETE https://dev.azure.com/{organization}/_apis/permissions/{securityNamespaceId}/{permissions}?descriptor={descriptor}&token={token}&api-version=6.0

URI 参数

名称 必需 类型 说明
securityNamespaceId
path True

string (uuid)

安全命名空间标识符。

organization
path

string

Azure DevOps 组织的名称。

permissions
path

integer (int32)

要删除的权限。

api-version
query True

string

要使用的 API 版本。 这应设置为“6.0”才能使用此版本的 API。

descriptor
query True

string

要删除其权限的用户的标识描述符。

token
query

string

用于删除其权限的安全令牌。

响应

名称 类型 说明
200 OK

AccessControlEntry

成功作

安全性

oauth2

类型: oauth2
流向: accessCode
授权 URL: https://app.vssps.visualstudio.com/oauth2/authorize&response_type=Assertion
令牌 URL: https://app.vssps.visualstudio.com/oauth2/token?client_assertion_type=urn:ietf:params:oauth:client-assertion-type:jwt-bearer&grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer

作用域

名称 说明
vso.security_manage 授予读取、写入和管理安全权限的能力。

示例

示例请求

DELETE https://dev.azure.com/fabrikam/_apis/permissions/5a27515b-ccd7-42c9-84f1-54c998f03866?descriptor=Microsoft.TeamFoundation.Identity;S-1-9-1551374245-1204400969-2402986413-2179408616-0-0-0-0-1&token=token1&api-version=6.0

示例响应

{
  "descriptor": "Microsoft.TeamFoundation.Identity;S-1-9-1551374245-1204400969-2402986413-2179408616-0-0-0-0-1",
  "allow": 1,
  "deny": 0
}

定义

名称 说明
AccessControlEntry

用于封装给定 IdentityDescriptor 的允许和拒绝权限的类。

AceExtendedInformation

保存给定 AccessControlEntry 的继承且有效的权限信息。

IdentityDescriptor

标识描述符是标识类型的包装器(Windows SID、Passport),以及唯一标识符,例如 SID 或 PUID。

AccessControlEntry

用于封装给定 IdentityDescriptor 的允许和拒绝权限的类。

名称 类型 说明
allow

integer (int32)

表示允许关联的描述符执行的作的权限位集。

deny

integer (int32)

表示不允许关联的描述符执行的作的权限位集。

descriptor

IdentityDescriptor

此 AccessControlEntry 适用于的用户的描述符。

extendedInfo

AceExtendedInformation

如果设置此值,则报告关联描述符的继承和有效信息。 仅在 QueryAccessControlList(s) 调用返回的 AccessControlEntries 上设置此值,其 includeExtendedInfo 参数设置为 true。

AceExtendedInformation

保存给定 AccessControlEntry 的继承且有效的权限信息。

名称 类型 说明
effectiveAllow

integer (int32)

这是此令牌上此标识的所有显式和继承权限的组合。 这些是确定给定用户是否有权执行作时使用的权限。

effectiveDeny

integer (int32)

这是此令牌上此标识的所有显式和继承权限的组合。 这些是确定给定用户是否有权执行作时使用的权限。

inheritedAllow

integer (int32)

这些是此令牌上此标识继承的权限。 如果令牌未继承权限,则为 0。 请注意,在此标识的此令牌上显式设置的任何权限或此标识所属的任何组都不包括在此处。

inheritedDeny

integer (int32)

这些是此令牌上此标识继承的权限。 如果令牌未继承权限,则为 0。 请注意,在此标识的此令牌上显式设置的任何权限或此标识所属的任何组都不包括在此处。

IdentityDescriptor

标识描述符是标识类型的包装器(Windows SID、Passport),以及唯一标识符,例如 SID 或 PUID。

名称 类型 说明
identifier

string

此标识的唯一标识符,不超过 256 个字符,这将持久保存。

identityType

string

描述符的类型(例如 Windows、Passport 等)。