重要前提
安装AI Skills的关键前提是:必须科学上网,且开启TUN模式,这一点至关重要,直接决定安装能否顺利完成,在此郑重提醒三遍:科学上网,科学上网,科学上网。查看完整安装教程 →
azure-devops by sanjay3290/ai-skills
npx skills add https://github.com/sanjay3290/ai-skills --skill azure-devops使用 OAuth 或 PAT 身份验证以及 REST API v7.1 实现完整的 Azure DevOps 集成。
使用 OAuth 设备代码流登录(显示 "Visual Studio Code" 提示):
python scripts/auth.py login --org MyOrganization
按照 URL 提示输入设备代码进行授权。令牌会自动刷新。
使用个人访问令牌登录:
python scripts/auth.py login --org MyOrganization --pat YOUR_PAT
在 https://dev.azure.com/{org}/_usersSettings/tokens 创建具有以下范围的 PAT:
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
检查身份验证状态:
python scripts/auth.py status
注销:
python scripts/auth.py logout
# 列出所有项目
python scripts/core.py list-projects
python scripts/core.py list-projects --top 10
# 列出项目中的团队
python scripts/core.py list-teams --project MyProject
# 搜索用户标识
python scripts/core.py get-identity --search "john@example.com"
# 获取工作项
python scripts/work_items.py get --project MyProject --id 123
python scripts/work_items.py get --project MyProject --id 123 --expand relations
# 创建工作项
python scripts/work_items.py create --project MyProject --type "User Story" --title "New feature"
python scripts/work_items.py create --project MyProject --type Bug --title "Fix login" \
--field System.Description "Login fails on timeout" \
--field System.AssignedTo "user@example.com"
# 更新工作项
python scripts/work_items.py update --project MyProject --id 123 \
--field System.State "Active" \
--field System.AssignedTo "user@example.com"
# 批量获取多个工作项
python scripts/work_items.py batch-get --project MyProject --ids 1,2,3
# 为父项添加子项
python scripts/work_items.py add-children --project MyProject --parent-id 100 --child-ids 101,102
# 链接工作项
python scripts/work_items.py link --project MyProject --source-id 100 --target-id 200
python scripts/work_items.py link --project MyProject --source-id 100 --target-id 200 \
--link-type "System.LinkTypes.Dependency-Forward"
# 移除链接
python scripts/work_items.py unlink --project MyProject --source-id 100 --relation-index 0
# 评论
python scripts/work_items.py add-comment --project MyProject --id 123 --text "Working on this"
python scripts/work_items.py list-comments --project MyProject --id 123
# 历史记录
python scripts/work_items.py get-revisions --project MyProject --id 123
# 列出工作项类型
python scripts/work_items.py list-types --project MyProject
# 分配给我的项
python scripts/work_items.py my-items --project MyProject
# 迭代中的项
python scripts/work_items.py iteration-items --project MyProject --iteration-path "MyProject\\Sprint 1"
# 积压工作
python scripts/work_items.py list-backlogs --project MyProject --team "MyProject Team"
# 保存的查询
python scripts/work_items.py list-queries --project MyProject
python scripts/work_items.py get-query --project MyProject --path "Shared Queries/Active Bugs"
python scripts/work_items.py run-query --project MyProject --query-id "guid-here"
# WIQL 查询
python scripts/work_items.py run-wiql --project MyProject \
--query "SELECT [System.Id], [System.Title] FROM WorkItems WHERE [System.State] = 'Active'"
# 删除 / 回收站
python scripts/work_items.py delete --project MyProject --id 999
python scripts/work_items.py recycle-bin --project MyProject
# 列出仓库
python scripts/repos.py list --project MyProject
# 获取仓库详情
python scripts/repos.py get --project MyProject --repo my-repo
# 分支
python scripts/repos.py list-branches --project MyProject --repo my-repo
python scripts/repos.py create-branch --project MyProject --repo my-repo --name feature/new --source main
# 提交
python scripts/repos.py search-commits --project MyProject --repo my-repo --path /src --author "john" --top 10
# 拉取请求
python scripts/repos.py list-prs --project MyProject --repo my-repo
python scripts/repos.py list-prs --project MyProject --status completed --top 5
python scripts/repos.py create-pr --project MyProject --repo my-repo \
--source feature/new --target main --title "Add new feature" --description "Details here"
python scripts/repos.py get-pr --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py update-pr --project MyProject --repo my-repo --pr-id 42 --title "Updated title"
# 审阅者
python scripts/repos.py list-reviewers --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py add-reviewer --project MyProject --repo my-repo --pr-id 42 \
--reviewer-id "guid" --vote 10
# PR 评论
python scripts/repos.py list-threads --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py create-thread --project MyProject --repo my-repo --pr-id 42 \
--content "Looks good!" --file-path "/src/main.py" --line 25
python scripts/repos.py add-thread-comment --project MyProject --repo my-repo --pr-id 42 \
--thread-id 1 --content "Fixed"
# 完成或放弃 PR
python scripts/repos.py complete-pr --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py complete-pr --project MyProject --repo my-repo --pr-id 42 \
--merge-strategy rebase --keep-source
python scripts/repos.py abandon-pr --project MyProject --repo my-repo --pr-id 42
# 差异比较
python scripts/repos.py get-diff --project MyProject --repo my-repo --base main --target feature/new
# 浏览文件
python scripts/repos.py list-files --project MyProject --repo my-repo --path /src --branch main
# 列出迭代
python scripts/work.py list-iterations --project MyProject
# 创建迭代
python scripts/work.py create-iteration --project MyProject --name "Sprint 5" \
--start-date 2026-03-01 --finish-date 2026-03-14
# 获取迭代详情
python scripts/work.py get-iteration --project MyProject --iteration-id "guid"
# 团队迭代
python scripts/work.py team-iterations --project MyProject --team "MyTeam" --timeframe current
# 为团队分配迭代
python scripts/work.py assign-iteration --project MyProject --team "MyTeam" --iteration-id "guid"
# 容量
python scripts/work.py get-capacities --project MyProject --team "MyTeam" --iteration-id "guid"
python scripts/work.py set-capacity --project MyProject --team "MyTeam" --iteration-id "guid" \
--member-id "user-guid" --activity Development --capacity-per-day 6
# 创建管道
python scripts/pipelines.py create --project MyProject --name "CI" \
--repo-id "repo-guid" --yaml-path "/azure-pipelines.yml"
# 列出生成
python scripts/pipelines.py list-builds --project MyProject --top 5
python scripts/pipelines.py list-builds --project MyProject --status completed --branch main
# 获取生成详情和日志
python scripts/pipelines.py get-build --project MyProject --build-id 100
python scripts/pipelines.py build-logs --project MyProject --build-id 100
python scripts/pipelines.py build-logs --project MyProject --build-id 100 --log-id 3
python scripts/pipelines.py build-changes --project MyProject --build-id 100
# 管道定义
python scripts/pipelines.py list-definitions --project MyProject
python scripts/pipelines.py list-definitions --project MyProject --name "CI"
# 运行管道
python scripts/pipelines.py run --project MyProject --pipeline-id 5 --branch develop
python scripts/pipelines.py run --project MyProject --pipeline-id 5 \
--variable ENV production --variable DEPLOY true
# 管道运行
python scripts/pipelines.py get-run --project MyProject --pipeline-id 5 --run-id 200
python scripts/pipelines.py list-runs --project MyProject --pipeline-id 5 --top 10
# 阶段管理
python scripts/pipelines.py update-stage --project MyProject --build-id 100 --stage Deploy --state retry
# 制品
python scripts/pipelines.py get-artifacts --project MyProject --build-id 100
# 排队和取消生成
python scripts/pipelines.py queue-build --project MyProject --definition-id 10 --branch main
python scripts/pipelines.py cancel-build --project MyProject --build-id 100
# 最新生成状态
python scripts/pipelines.py build-status --project MyProject --definition-id 10
# 搜索代码
python scripts/search.py code --project MyProject --query "TODO"
python scripts/search.py code --project MyProject --query "connectionString" --top 10
# 搜索 wiki
python scripts/search.py wiki --project MyProject --query "deployment guide"
# 搜索工作项
python scripts/search.py work-items --project MyProject --query "login bug"
# 列出 wiki
python scripts/wiki.py list --project MyProject
# 获取 wiki 详情
python scripts/wiki.py get --project MyProject --wiki-id MyProject.wiki
# 列出页面
python scripts/wiki.py list-pages --project MyProject --wiki-id MyProject.wiki
python scripts/wiki.py list-pages --project MyProject --wiki-id MyProject.wiki --path /Architecture
# 获取页面内容
python scripts/wiki.py get-page --project MyProject --wiki-id MyProject.wiki --path /Home
python scripts/wiki.py get-page-content --project MyProject --wiki-id MyProject.wiki --path /Home
# 创建或更新页面
python scripts/wiki.py create-or-update-page --project MyProject --wiki-id MyProject.wiki \
--path /NewPage --content "# New Page\n\nContent here"
# 测试计划
python scripts/test_plans.py list-plans --project MyProject
python scripts/test_plans.py get-plan --project MyProject --plan-id 1
python scripts/test_plans.py create-plan --project MyProject --name "Release 2.0 Tests"
# 测试套件
python scripts/test_plans.py list-suites --project MyProject --plan-id 1
python scripts/test_plans.py get-suite --project MyProject --plan-id 1 --suite-id 2
# 测试用例
python scripts/test_plans.py list-test-cases --project MyProject --plan-id 1 --suite-id 2
python scripts/test_plans.py add-test-cases --project MyProject --plan-id 1 --suite-id 2 --ids 100,101
# 测试结果
python scripts/test_plans.py list-results --project MyProject --run-id 50
python scripts/test_plans.py get-result --project MyProject --run-id 50 --result-id 1
# 列出安全警报
python scripts/security.py list-alerts --project MyProject --repo my-repo
python scripts/security.py list-alerts --project MyProject --repo my-repo \
--state active --severity high --type dependency
# 获取警报详情
python scripts/security.py get-alert --project MyProject --repo my-repo --alert-id 42
# 列出变量组
python scripts/variable_groups.py list --project MyProject
# 获取变量组
python scripts/variable_groups.py get --project MyProject --id 1
# 创建变量组
python scripts/variable_groups.py create --project MyProject --name "Deploy Vars" \
--variable ENV production --variable REGION eastus --description "Deploy config"
# 更新变量组
python scripts/variable_groups.py update --project MyProject --id 1 --name "New Name" \
--variable ENV staging
# 添加/更新单个变量(支持 --secret 用于敏感值)
python scripts/variable_groups.py add-variable --project MyProject --id 1 \
--key API_KEY --value "secret123" --secret
# 移除变量
python scripts/variable_groups.py remove-variable --project MyProject --id 1 --key OLD_VAR
# 删除变量组
python scripts/variable_groups.py delete --project MyProject --id 1
# 列出环境
python scripts/environments.py list --project MyProject
# 创建环境
python scripts/environments.py create --project MyProject --name "Production" \
--description "Production environment"
# 获取环境详情
python scripts/environments.py get --project MyProject --id 1
# 列出环境中配置的检查/审批
python scripts/environments.py list-checks --project MyProject --id 1
# 列出待处理的审批
python scripts/environments.py list-approvals --project MyProject
python scripts/environments.py list-approvals --project MyProject --state all
# 批准/拒绝
python scripts/environments.py approve --project MyProject --approval-id "guid" \
--comment "Looks good"
python scripts/environments.py reject --project MyProject --approval-id "guid" \
--comment "Needs fixes"
# 删除环境
python scripts/environments.py delete --project MyProject --id 1
# 列出所有策略
python scripts/policies.py list --project MyProject
python scripts/policies.py list --project MyProject --branch main --repo my-repo-id
# 获取策略
python scripts/policies.py get --project MyProject --id 1
# 列出可用的策略类型
python scripts/policies.py list-types --project MyProject
# 创建最少审阅者策略
python scripts/policies.py create-min-reviewers --project MyProject \
--repo-id "repo-guid" --branch main --min-reviewers 2 --reset-on-push
# 创建生成验证策略
python scripts/policies.py create-build-policy --project MyProject \
--repo-id "repo-guid" --branch main --build-definition-id 10
# 更新策略(启用/禁用/阻塞)
python scripts/policies.py update --project MyProject --id 1 --enabled false
python scripts/policies.py update --project MyProject --id 1 --blocking true
# 列出 PR 的策略评估
python scripts/policies.py list-evaluations --project MyProject --pr-id 42
# 删除策略
python scripts/policies.py delete --project MyProject --id 1
# 上传文件
python scripts/attachments.py upload --project MyProject --file ./report.pdf
# 将上传的文件附加到工作项
python scripts/attachments.py attach --project MyProject --id 123 \
--url "https://dev.azure.com/org/project/_apis/wit/attachments/guid" \
--comment "Test report"
# 一步完成上传和附加
python scripts/attachments.py upload-and-attach --project MyProject --id 123 \
--file ./screenshot.png --comment "Bug screenshot"
# 列出工作项上的附件
python scripts/attachments.py list --project MyProject --id 123
# 下载附件
python scripts/attachments.py download --project MyProject \
--url "https://dev.azure.com/org/project/_apis/wit/attachments/guid" \
--output ./downloaded.pdf
# 按关系索引移除附件
python scripts/attachments.py remove --project MyProject --id 123 --index 0
| 字段 | 引用名称 |
|---|---|
| 标题 | System.Title |
| 状态 | System.State |
| 分配给 | System.AssignedTo |
| 描述 | System.Description |
| 区域路径 | System.AreaPath |
| 迭代路径 | System.IterationPath |
| 优先级 | Microsoft.VSTS.Common.Priority |
| 故事点 | Microsoft.VSTS.Scheduling.StoryPoints |
| 标记 | System.Tags |
| 重现步骤 | Microsoft.VSTS.TCM.ReproSteps |
| 验收条件 | Microsoft.VSTS.Common.AcceptanceCriteria |
| 链接类型 | 引用名称 |
|---|---|
| 相关 | System.LinkTypes.Related |
| 父项 → 子项 | System.LinkTypes.Hierarchy-Forward |
| 子项 → 父项 | System.LinkTypes.Hierarchy-Reverse |
| 前置任务 | System.LinkTypes.Dependency-Forward |
| 后续任务 | System.LinkTypes.Dependency-Reverse |
凭据使用系统密钥环安全存储:
服务名称:azure-devops-skill
每周安装次数
55
仓库
GitHub 星标数
172
首次出现
2026年2月18日
安全审计
安装于
codex52
gemini-cli52
opencode51
github-copilot50
amp49
kimi-cli49
Full Azure DevOps integration using OAuth or PAT authentication and REST API v7.1.
Login with OAuth device code flow (shows "Visual Studio Code" prompt):
python scripts/auth.py login --org MyOrganization
Follow the URL and enter the device code to authorize. Tokens auto-refresh.
Login with a Personal Access Token:
python scripts/auth.py login --org MyOrganization --pat YOUR_PAT
Create a PAT at https://dev.azure.com/{org}/_usersSettings/tokens with these scopes:
Check authentication status:
python scripts/auth.py status
Logout:
python scripts/auth.py logout
# List all projects
python scripts/core.py list-projects
python scripts/core.py list-projects --top 10
# List teams in a project
python scripts/core.py list-teams --project MyProject
# Search for a user identity
python scripts/core.py get-identity --search "john@example.com"
# Get a work item
python scripts/work_items.py get --project MyProject --id 123
python scripts/work_items.py get --project MyProject --id 123 --expand relations
# Create a work item
python scripts/work_items.py create --project MyProject --type "User Story" --title "New feature"
python scripts/work_items.py create --project MyProject --type Bug --title "Fix login" \
--field System.Description "Login fails on timeout" \
--field System.AssignedTo "user@example.com"
# Update a work item
python scripts/work_items.py update --project MyProject --id 123 \
--field System.State "Active" \
--field System.AssignedTo "user@example.com"
# Batch get multiple work items
python scripts/work_items.py batch-get --project MyProject --ids 1,2,3
# Add children to a parent
python scripts/work_items.py add-children --project MyProject --parent-id 100 --child-ids 101,102
# Link work items
python scripts/work_items.py link --project MyProject --source-id 100 --target-id 200
python scripts/work_items.py link --project MyProject --source-id 100 --target-id 200 \
--link-type "System.LinkTypes.Dependency-Forward"
# Remove a link
python scripts/work_items.py unlink --project MyProject --source-id 100 --relation-index 0
# Comments
python scripts/work_items.py add-comment --project MyProject --id 123 --text "Working on this"
python scripts/work_items.py list-comments --project MyProject --id 123
# History
python scripts/work_items.py get-revisions --project MyProject --id 123
# List work item types
python scripts/work_items.py list-types --project MyProject
# My assigned items
python scripts/work_items.py my-items --project MyProject
# Items in an iteration
python scripts/work_items.py iteration-items --project MyProject --iteration-path "MyProject\\Sprint 1"
# Backlogs
python scripts/work_items.py list-backlogs --project MyProject --team "MyProject Team"
# Saved queries
python scripts/work_items.py list-queries --project MyProject
python scripts/work_items.py get-query --project MyProject --path "Shared Queries/Active Bugs"
python scripts/work_items.py run-query --project MyProject --query-id "guid-here"
# WIQL query
python scripts/work_items.py run-wiql --project MyProject \
--query "SELECT [System.Id], [System.Title] FROM WorkItems WHERE [System.State] = 'Active'"
# Delete / recycle bin
python scripts/work_items.py delete --project MyProject --id 999
python scripts/work_items.py recycle-bin --project MyProject
# List repositories
python scripts/repos.py list --project MyProject
# Get repo details
python scripts/repos.py get --project MyProject --repo my-repo
# Branches
python scripts/repos.py list-branches --project MyProject --repo my-repo
python scripts/repos.py create-branch --project MyProject --repo my-repo --name feature/new --source main
# Commits
python scripts/repos.py search-commits --project MyProject --repo my-repo --path /src --author "john" --top 10
# Pull requests
python scripts/repos.py list-prs --project MyProject --repo my-repo
python scripts/repos.py list-prs --project MyProject --status completed --top 5
python scripts/repos.py create-pr --project MyProject --repo my-repo \
--source feature/new --target main --title "Add new feature" --description "Details here"
python scripts/repos.py get-pr --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py update-pr --project MyProject --repo my-repo --pr-id 42 --title "Updated title"
# Reviewers
python scripts/repos.py list-reviewers --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py add-reviewer --project MyProject --repo my-repo --pr-id 42 \
--reviewer-id "guid" --vote 10
# PR comments
python scripts/repos.py list-threads --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py create-thread --project MyProject --repo my-repo --pr-id 42 \
--content "Looks good!" --file-path "/src/main.py" --line 25
python scripts/repos.py add-thread-comment --project MyProject --repo my-repo --pr-id 42 \
--thread-id 1 --content "Fixed"
# Complete or abandon PR
python scripts/repos.py complete-pr --project MyProject --repo my-repo --pr-id 42
python scripts/repos.py complete-pr --project MyProject --repo my-repo --pr-id 42 \
--merge-strategy rebase --keep-source
python scripts/repos.py abandon-pr --project MyProject --repo my-repo --pr-id 42
# Diff
python scripts/repos.py get-diff --project MyProject --repo my-repo --base main --target feature/new
# Browse files
python scripts/repos.py list-files --project MyProject --repo my-repo --path /src --branch main
# List iterations
python scripts/work.py list-iterations --project MyProject
# Create iteration
python scripts/work.py create-iteration --project MyProject --name "Sprint 5" \
--start-date 2026-03-01 --finish-date 2026-03-14
# Get iteration details
python scripts/work.py get-iteration --project MyProject --iteration-id "guid"
# Team iterations
python scripts/work.py team-iterations --project MyProject --team "MyTeam" --timeframe current
# Assign iteration to team
python scripts/work.py assign-iteration --project MyProject --team "MyTeam" --iteration-id "guid"
# Capacities
python scripts/work.py get-capacities --project MyProject --team "MyTeam" --iteration-id "guid"
python scripts/work.py set-capacity --project MyProject --team "MyTeam" --iteration-id "guid" \
--member-id "user-guid" --activity Development --capacity-per-day 6
# Create pipeline
python scripts/pipelines.py create --project MyProject --name "CI" \
--repo-id "repo-guid" --yaml-path "/azure-pipelines.yml"
# List builds
python scripts/pipelines.py list-builds --project MyProject --top 5
python scripts/pipelines.py list-builds --project MyProject --status completed --branch main
# Get build details and logs
python scripts/pipelines.py get-build --project MyProject --build-id 100
python scripts/pipelines.py build-logs --project MyProject --build-id 100
python scripts/pipelines.py build-logs --project MyProject --build-id 100 --log-id 3
python scripts/pipelines.py build-changes --project MyProject --build-id 100
# Pipeline definitions
python scripts/pipelines.py list-definitions --project MyProject
python scripts/pipelines.py list-definitions --project MyProject --name "CI"
# Run a pipeline
python scripts/pipelines.py run --project MyProject --pipeline-id 5 --branch develop
python scripts/pipelines.py run --project MyProject --pipeline-id 5 \
--variable ENV production --variable DEPLOY true
# Pipeline runs
python scripts/pipelines.py get-run --project MyProject --pipeline-id 5 --run-id 200
python scripts/pipelines.py list-runs --project MyProject --pipeline-id 5 --top 10
# Stage management
python scripts/pipelines.py update-stage --project MyProject --build-id 100 --stage Deploy --state retry
# Artifacts
python scripts/pipelines.py get-artifacts --project MyProject --build-id 100
# Queue and cancel builds
python scripts/pipelines.py queue-build --project MyProject --definition-id 10 --branch main
python scripts/pipelines.py cancel-build --project MyProject --build-id 100
# Latest build status
python scripts/pipelines.py build-status --project MyProject --definition-id 10
# Search code
python scripts/search.py code --project MyProject --query "TODO"
python scripts/search.py code --project MyProject --query "connectionString" --top 10
# Search wiki
python scripts/search.py wiki --project MyProject --query "deployment guide"
# Search work items
python scripts/search.py work-items --project MyProject --query "login bug"
# List wikis
python scripts/wiki.py list --project MyProject
# Get wiki details
python scripts/wiki.py get --project MyProject --wiki-id MyProject.wiki
# List pages
python scripts/wiki.py list-pages --project MyProject --wiki-id MyProject.wiki
python scripts/wiki.py list-pages --project MyProject --wiki-id MyProject.wiki --path /Architecture
# Get page content
python scripts/wiki.py get-page --project MyProject --wiki-id MyProject.wiki --path /Home
python scripts/wiki.py get-page-content --project MyProject --wiki-id MyProject.wiki --path /Home
# Create or update a page
python scripts/wiki.py create-or-update-page --project MyProject --wiki-id MyProject.wiki \
--path /NewPage --content "# New Page\n\nContent here"
# Test plans
python scripts/test_plans.py list-plans --project MyProject
python scripts/test_plans.py get-plan --project MyProject --plan-id 1
python scripts/test_plans.py create-plan --project MyProject --name "Release 2.0 Tests"
# Test suites
python scripts/test_plans.py list-suites --project MyProject --plan-id 1
python scripts/test_plans.py get-suite --project MyProject --plan-id 1 --suite-id 2
# Test cases
python scripts/test_plans.py list-test-cases --project MyProject --plan-id 1 --suite-id 2
python scripts/test_plans.py add-test-cases --project MyProject --plan-id 1 --suite-id 2 --ids 100,101
# Test results
python scripts/test_plans.py list-results --project MyProject --run-id 50
python scripts/test_plans.py get-result --project MyProject --run-id 50 --result-id 1
# List security alerts
python scripts/security.py list-alerts --project MyProject --repo my-repo
python scripts/security.py list-alerts --project MyProject --repo my-repo \
--state active --severity high --type dependency
# Get alert details
python scripts/security.py get-alert --project MyProject --repo my-repo --alert-id 42
# List variable groups
python scripts/variable_groups.py list --project MyProject
# Get a variable group
python scripts/variable_groups.py get --project MyProject --id 1
# Create a variable group
python scripts/variable_groups.py create --project MyProject --name "Deploy Vars" \
--variable ENV production --variable REGION eastus --description "Deploy config"
# Update a variable group
python scripts/variable_groups.py update --project MyProject --id 1 --name "New Name" \
--variable ENV staging
# Add/update a single variable (supports --secret for sensitive values)
python scripts/variable_groups.py add-variable --project MyProject --id 1 \
--key API_KEY --value "secret123" --secret
# Remove a variable
python scripts/variable_groups.py remove-variable --project MyProject --id 1 --key OLD_VAR
# Delete a variable group
python scripts/variable_groups.py delete --project MyProject --id 1
# List environments
python scripts/environments.py list --project MyProject
# Create an environment
python scripts/environments.py create --project MyProject --name "Production" \
--description "Production environment"
# Get environment details
python scripts/environments.py get --project MyProject --id 1
# List checks/approvals configured on an environment
python scripts/environments.py list-checks --project MyProject --id 1
# List pending approvals
python scripts/environments.py list-approvals --project MyProject
python scripts/environments.py list-approvals --project MyProject --state all
# Approve/reject
python scripts/environments.py approve --project MyProject --approval-id "guid" \
--comment "Looks good"
python scripts/environments.py reject --project MyProject --approval-id "guid" \
--comment "Needs fixes"
# Delete an environment
python scripts/environments.py delete --project MyProject --id 1
# List all policies
python scripts/policies.py list --project MyProject
python scripts/policies.py list --project MyProject --branch main --repo my-repo-id
# Get a policy
python scripts/policies.py get --project MyProject --id 1
# List available policy types
python scripts/policies.py list-types --project MyProject
# Create minimum reviewers policy
python scripts/policies.py create-min-reviewers --project MyProject \
--repo-id "repo-guid" --branch main --min-reviewers 2 --reset-on-push
# Create build validation policy
python scripts/policies.py create-build-policy --project MyProject \
--repo-id "repo-guid" --branch main --build-definition-id 10
# Update a policy (enable/disable/blocking)
python scripts/policies.py update --project MyProject --id 1 --enabled false
python scripts/policies.py update --project MyProject --id 1 --blocking true
# List policy evaluations for a PR
python scripts/policies.py list-evaluations --project MyProject --pr-id 42
# Delete a policy
python scripts/policies.py delete --project MyProject --id 1
# Upload a file
python scripts/attachments.py upload --project MyProject --file ./report.pdf
# Attach an uploaded file to a work item
python scripts/attachments.py attach --project MyProject --id 123 \
--url "https://dev.azure.com/org/project/_apis/wit/attachments/guid" \
--comment "Test report"
# Upload and attach in one step
python scripts/attachments.py upload-and-attach --project MyProject --id 123 \
--file ./screenshot.png --comment "Bug screenshot"
# List attachments on a work item
python scripts/attachments.py list --project MyProject --id 123
# Download an attachment
python scripts/attachments.py download --project MyProject \
--url "https://dev.azure.com/org/project/_apis/wit/attachments/guid" \
--output ./downloaded.pdf
# Remove an attachment by relation index
python scripts/attachments.py remove --project MyProject --id 123 --index 0
| Field | Reference Name |
|---|---|
| Title | System.Title |
| State | System.State |
| Assigned To | System.AssignedTo |
| Description | System.Description |
| Area Path | System.AreaPath |
| Iteration Path | System.IterationPath |
| Link Type | Reference Name |
|---|---|
| Related | System.LinkTypes.Related |
| Parent → Child | System.LinkTypes.Hierarchy-Forward |
| Child → Parent | System.LinkTypes.Hierarchy-Reverse |
| Predecessor | System.LinkTypes.Dependency-Forward |
| Successor | System.LinkTypes.Dependency-Reverse |
Credentials stored securely using the system keyring:
Service name: azure-devops-skill
Weekly Installs
55
Repository
GitHub Stars
172
First Seen
Feb 18, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykFail
Installed on
codex52
gemini-cli52
opencode51
github-copilot50
amp49
kimi-cli49
开源项目教练指南 - 诊断问题、制定行动计划、优化开源项目运营
50,600 周安装
| Priority |
Microsoft.VSTS.Common.Priority |
| Story Points | Microsoft.VSTS.Scheduling.StoryPoints |
| Tags | System.Tags |
| Repro Steps | Microsoft.VSTS.TCM.ReproSteps |
| Acceptance Criteria | Microsoft.VSTS.Common.AcceptanceCriteria |