我们可以将 Azure DevOps 工作项文件导出到 Excel 中吗
我们在 Azure DevOps Board 中有不同类型的工作项。我们需要将工作项中所有字段的列表导出到 Excel 或任何类似的格式。有没有办法使用 API 来提取系统中所有字段的列表以及任何可用的相关元数据?有人可以帮助我们完成这项任务吗?
We have different types of work items in Azure DevOps Boards. We need to export list of all fields in work items to excel or any similar format. Is there a way to use the APIs to pull a list of all fields in the system and whatever associated metadata is available? Can someone please help us on this task.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您可以使用适用于 Excel 的 Azure DevOps Office® Integration 2019 连接器来批量提取数据。调用 API 有一个限制,我认为可能是 10,000 个工作项。当您使用条件运行查询时,您可以通过划分查询来绕过此速率限制。
You can use the Azure DevOps Office® Integration 2019 connector for Excel to extract data in volume. There is a limit for calling the API I think it might be 10,000 work items. you can get around this rate limit by dividing your query up when you run it with a criteria.
如果您有 Visual Studio,则可以运行开发人员命令提示符并使用
witadmin
命令行。Witadmin 语法:https: //learn.microsoft.com/en-us/azure/devops/reference/witadmin/manage-work-item-fields?view=azure-devops#syntax
If you have Visual Studio, you can run Developer Command Prompt and use
witadmin
command line.Witadmin syntax: https://learn.microsoft.com/en-us/azure/devops/reference/witadmin/manage-work-item-fields?view=azure-devops#syntax
您可以使用 Rest Api 获取表单流程模板的所有字段: https://learn.microsoft.com/en-us/rest/api/azure/devops/processes/fields/list?view=azure-devops-rest-7.1
Powershell 示例:
进程会引导您可以通过rest API: https://dev.azure.com//_apis/work/processes?api-version=7.1-preview.2
查看流程模板时可以从 URL 获取工作项类型名称:
更新:
要获取有关每个字段的信息,您需要使用 字段获取 带有
$expand=all
选项的 REST API。例子:

You can use Rest Api to get all fields form process template: https://learn.microsoft.com/en-us/rest/api/azure/devops/processes/fields/list?view=azure-devops-rest-7.1
Powershell example:
Process guild you can get through rest API: https://dev.azure.com/<you_org_name>/_apis/work/processes?api-version=7.1-preview.2
Work Item Type Name you can get from URL while viewing your process template:
UPDATE:
To get information about each field, you need to use FIELD GET rest API with
$expand=all
option.Example:
