ar.*_*dll 6 azure-devops azure-devops-rest-api
来源提供商 - 列出分支机构:
谁能告诉我“providerName”字符串的用途是什么?
这是源提供者的名称。如果使用 TFVC 或 Azure Devops-native Git,则不需要使用此 API - 有 TFVC 和 Git 特定的 API。
如果您使用外部 Git 提供商(例如 GitHub 或 BitBucket),那么这里就是正确的地方。您需要告诉 API您正在尝试查询哪个外部提供商。
这就是为什么在“List”API 的“List Branches”条目上方直接列出了一个页面——它列出了您帐户的可用源提供商。
GET https://dev.azure.com/{organization}/{project}/_apis/sourceproviders?api-version=5.0-preview.1
调用该 API 应返回类似以下内容的内容:
{
"count": 7,
"value": [
{
"name": "GitHubEnterprise",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "pullRequest",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "unsupported",
"buildForks": "supported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": true,
"discoverExistingYamlDefinitions": false,
"queryBranches": true,
"queryFileContents": true,
"queryPathContents": true,
"queryPullRequest": false,
"queryRelatedWorkItems": false,
"queryRepositories": true,
"queryTopRepositories": false,
"queryWebhooks": true,
"sourceLinks": true,
"yamlDefinition": true
}
},
{
"name": "Svn",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "polling",
"defaultPollingInterval": 180,
"supportedCapabilities": {
"branchFilters": "unsupported",
"pathFilters": "required",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "unsupported",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": false,
"discoverExistingYamlDefinitions": false,
"queryBranches": false,
"queryFileContents": false,
"queryPathContents": false,
"queryPullRequest": false,
"queryRelatedWorkItems": false,
"queryRepositories": false,
"queryTopRepositories": false,
"queryWebhooks": false,
"sourceLinks": false,
"yamlDefinition": false
}
},
{
"name": "GitHub",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "pullRequest",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "unsupported",
"buildForks": "supported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": true,
"discoverExistingYamlDefinitions": false,
"queryBranches": true,
"queryFileContents": true,
"queryPathContents": true,
"queryPullRequest": true,
"queryRelatedWorkItems": true,
"queryRepositories": true,
"queryTopRepositories": true,
"queryWebhooks": true,
"sourceLinks": true,
"yamlDefinition": true
}
},
{
"name": "Bitbucket",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "pullRequest",
"notificationType": "webhook",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": false,
"discoverExistingYamlDefinitions": false,
"queryBranches": true,
"queryFileContents": false,
"queryPathContents": false,
"queryRelatedWorkItems": false,
"queryPullRequest": false,
"queryRepositories": true,
"queryTopRepositories": false,
"queryWebhooks": false,
"sourceLinks": true,
"yamlDefinition": false
}
},
{
"name": "Git",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "polling",
"defaultPollingInterval": 180,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": false,
"discoverExistingYamlDefinitions": false,
"queryBranches": false,
"queryFileContents": false,
"queryPathContents": false,
"queryPullRequest": false,
"queryRelatedWorkItems": false,
"queryRepositories": false,
"queryTopRepositories": false,
"queryWebhooks": false,
"sourceLinks": false,
"yamlDefinition": false
}
},
{
"name": "TfsGit",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "required",
"pathFilters": "supported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": true,
"discoverExistingYamlDefinitions": false,
"queryBranches": false,
"queryFileContents": true,
"queryPathContents": true,
"queryPullRequest": true,
"queryRelatedWorkItems": true,
"queryRepositories": false,
"queryTopRepositories": false,
"queryWebhooks": false,
"sourceLinks": true,
"yamlDefinition": true
}
},
{
"name": "TfsVersionControl",
"supportedTriggers": [
{
"type": "continuousIntegration",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "unsupported",
"pathFilters": "required",
"batchChanges": "supported",
"buildForks": "unsupported"
}
},
{
"type": "gatedCheckIn",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "unsupported",
"pathFilters": "required",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
},
{
"type": "schedule",
"notificationType": "none",
"defaultPollingInterval": 0,
"supportedCapabilities": {
"branchFilters": "unsupported",
"pathFilters": "unsupported",
"batchChanges": "unsupported",
"buildForks": "unsupported"
}
}
],
"supportedCapabilities": {
"createLabel": true,
"discoverExistingYamlDefinitions": false,
"queryBranches": false,
"queryFileContents": true,
"queryPathContents": true,
"queryPullRequest": false,
"queryRelatedWorkItems": true,
"queryRepositories": false,
"queryTopRepositories": false,
"queryWebhooks": false,
"sourceLinks": false,
"yamlDefinition": false
}
}
]
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
3319 次 |
| 最近记录: |