Check Configurations - Query
按资源类型和 ID 获取多个资源的检查配置。
POST https://dev.azure.com/{organization}/{project}/_apis/pipelines/checks/queryconfigurations?api-version=7.1-preview.1
POST https://dev.azure.com/{organization}/{project}/_apis/pipelines/checks/queryconfigurations?$expand={$expand}&api-version=7.1-preview.1
URI 参数
名称 | 在 | 必需 | 类型 | 说明 |
---|---|---|---|---|
organization
|
path | True |
string |
Azure DevOps 组织的名称。 |
project
|
path | True |
string |
项目 ID 或项目名称 |
api-version
|
query | True |
string |
要使用的 API 版本。 应将其设置为“7.1-preview.1”才能使用此版本的 API。 |
$expand
|
query |
应在检查配置列表中展开的属性。 |
请求正文
名称 | 类型 | 说明 |
---|---|---|
body |
Resource[] |
资源列表。 |
响应
名称 | 类型 | 说明 |
---|---|---|
200 OK |
成功的操作 |
安全性
oauth2
Type:
oauth2
Flow:
accessCode
Authorization URL:
https://app.vssps.visualstudio.com/oauth2/authorize&response_type=Assertion
Token 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
Scopes
名称 | 说明 |
---|---|
vso.build | 授予访问生成项目(包括生成结果、定义和请求)以及通过服务挂钩接收有关生成事件的通知的能力。 |
示例
Sample Request
POST https://dev.azure.com/{organization}/{project}/_apis/pipelines/checks/queryconfigurations?api-version=7.1-preview.1
[
{
"type": "queue",
"id": "1",
"name": "Default"
},
{
"type": "environment",
"id": "1",
"name": "SampleEnv"
}
]
Sample Response
request-Context: appId=cid-v1:a892bfef-0287-4640-9f5e-cffc90fbcf94
access-Control-Expose-Headers: Request-Context
{
"count": 12,
"value": [
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:21:11.1408948Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:21:11.1408948Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/22"
}
},
"id": 22,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/22",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:21:11.312742Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:52:52.3335458Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/23"
}
},
"id": 23,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/23",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:42:31.1912383Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:42:31.1912383Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/24"
}
},
"id": 24,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/24",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:50:29.2550665Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T12:26:25.7610862Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/27"
}
},
"id": 27,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/27",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:52:03.1146399Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:52:03.1146399Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/28"
}
},
"id": 28,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/28",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:53:33.1149141Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:53:33.1149141Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/30"
}
},
"id": 30,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/30",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T11:53:33.2555259Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T11:53:33.2555259Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/31"
}
},
"id": 31,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/31",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T12:26:25.3548409Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T12:26:25.3548409Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/32"
}
},
"id": 32,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/32",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T12:26:25.5267095Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T12:26:25.5267095Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/33"
}
},
"id": 33,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/33",
"resource": {
"type": "queue",
"id": "1",
"name": "Default"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-09-21T07:29:09.749198Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T12:23:28.1356019Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/12"
}
},
"id": 12,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/12",
"resource": {
"type": "environment",
"id": "1",
"name": "SampleEnv"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-09-30T12:46:12.6159149Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T08:12:49.2665218Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/14"
}
},
"id": 14,
"type": {
"id": "8c6f20a7-a545-4486-9777-f762fafe0d4d",
"name": "Approval"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/14",
"resource": {
"type": "environment",
"id": "1",
"name": "SampleEnv"
}
},
{
"createdBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"createdOn": "2020-11-19T10:28:46.4136508Z",
"modifiedBy": {
"displayName": "User Name",
"id": "3b3db741-9d03-4e32-a7c0-6c3dfc2013c1",
"uniqueName": "uniqueName",
"descriptor": "Descriptor"
},
"modifiedOn": "2020-11-19T10:28:46.4136508Z",
"timeout": 43200,
"_links": {
"self": {
"href": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/16"
}
},
"id": 16,
"type": {
"id": "fe1de3ee-a436-41b4-bb20-f6eb4cb879a7",
"name": "Task Check"
},
"url": "https://dev.azure.com/fabrikam/d6b3e0ea-8197-4dec-831b-50e2e06ff95f/_apis/pipelines/checks/configurations/16",
"resource": {
"type": "environment",
"id": "1",
"name": "SampleEnv"
}
}
]
}
定义
名称 | 说明 |
---|---|
Check |
|
Check |
应在检查配置列表中展开的属性。 |
Check |
与检查配置关联的问题 (错误、警告) 。 |
Check |
类型 (错误、警告) 问题。 |
Check |
|
Identity |
|
Reference |
表示 REST 引用链接集合的类。 |
Resource |
CheckConfiguration
名称 | 类型 | 说明 |
---|---|---|
_links |
参考链接。 |
|
createdBy |
配置检查的人员的标识。 |
|
createdOn |
string |
配置检查的时间。 |
id |
integer |
检查配置 ID。 |
isDisabled |
boolean |
是否检查禁用。 |
issue |
连接到检查配置时出现问题。 |
|
modifiedBy |
修改配置的检查的人员的标识。 |
|
modifiedOn |
string |
配置检查修改的时间。 |
resource |
配置检查的资源。 |
|
timeout |
integer |
检查超时(以分钟为单位)。 |
type |
检查配置类型 |
|
url |
string |
可以从中获取配置的检查的 URL。 |
CheckConfigurationExpandParameter
应在检查配置列表中展开的属性。
名称 | 类型 | 说明 |
---|---|---|
none |
string |
|
settings |
string |
CheckIssue
与检查配置关联的问题 (错误、警告) 。
名称 | 类型 | 说明 |
---|---|---|
description |
string |
检查的简短摘要 - 其名称和资源。 |
detailedMessage |
string |
问题的更详细说明。 |
message |
string |
问题的说明。 |
type |
类型 (错误、警告) 问题。 |
CheckIssueType
类型 (错误、警告) 问题。
名称 | 类型 | 说明 |
---|---|---|
error |
string |
|
warning |
string |
CheckType
名称 | 类型 | 说明 |
---|---|---|
id |
string |
获取或设置检查类型 ID。 |
name |
string |
检查类型的名称。 |
IdentityRef
名称 | 类型 | 说明 |
---|---|---|
_links |
此字段包含有关图形主题的零个或多个相关链接。 可以调用这些链接来获取有关此图主题的其他关系或更多详细信息。 |
|
descriptor |
string |
描述符是在系统运行时引用图形主题的主要方式。 此字段将唯一标识帐户和组织中的同一图形主题。 |
directoryAlias |
string |
已弃用 - 可通过查询 IdentityRef“_links”字典的“self”条目中引用的 Graph 用户来检索 |
displayName |
string |
这是图形主题的非唯一显示名称。 若要更改此字段,必须在源提供程序中更改其值。 |
id |
string |
|
imageUrl |
string |
已弃用 - 在 IdentityRef“_links”字典的“头像”条目中可用 |
inactive |
boolean |
已弃用 - 可以通过查询 GraphUser“_links”字典的“membershipState”条目中引用的 Graph 成员身份状态来检索 |
isAadIdentity |
boolean |
已弃用 - 可以从描述符的主题类型推断 (描述符.IsAadUserType/Descriptor.IsAadGroupType) |
isContainer |
boolean |
已弃用 - 可以从描述符的主题类型推断 (描述符.IsGroupType) |
isDeletedInOrigin |
boolean |
|
profileUrl |
string |
已弃用 - 未在 ToIdentityRef 的大多数预先存在的实现中使用 |
uniqueName |
string |
已弃用 - 改用 Domain+PrincipalName |
url |
string |
此 URL 是此图主题的源资源的完整路由。 |
ReferenceLinks
表示 REST 引用链接集合的类。
名称 | 类型 | 说明 |
---|---|---|
links |
object |
链接的只读视图。 由于引用链接是只读的,因此我们只想将其公开为只读。 |
Resource
名称 | 类型 | 说明 |
---|---|---|
id |
string |
资源的 ID。 |
name |
string |
资源的名称。 |
type |
string |
资源的类型。 |