AGENT SKILL

provider-bitbucket

How to perform the tracker skill's code-host operations on Bitbucket Cloud — pull requests, diffs, PR comments, Pipelines runs and step logs — through the Bitbucket REST API. Bitbucket is a code host here; pair it with Jira (or another tracker) for issues. Load it when QA_CODE_HOST is bitbucket.

License 许可
MIT
最近更新
2026-11-06
Stars
★ 5
Forks
4

01 前言 Front Matter

name
provider-bitbucket
description
How to perform the tracker skill's code-host operations on Bitbucket Cloud — pull requests, diffs, PR comments, Pipelines runs and step logs — through the Bitbucket REST API. Bitbucket is a code host here; pair it with Jira (or another tracker) for issues. Load it when QA_CODE_HOST is bitbucket.

03 SKILL.md 正文

provider-bitbucket

Bitbucket is used as a code host only: PRs, diffs and Pipelines. File issues in Jira (QA_TRACKER=jira), which is how most Bitbucket teams work.

Settings: BITBUCKET_WORKSPACE, BITBUCKET_REPO, and secrets BITBUCKET_EMAIL + BITBUCKET_API_TOKEN (an Atlassian API token with repository and pull-request scopes). Load them only inside the command. The base URL is https://api.bitbucket.org/2.0/repositories/$BITBUCKET_WORKSPACE/$BITBUCKET_REPO, called $BB below:

set -a; . ./.env; set +a
BB="https://api.bitbucket.org/2.0/repositories/$BITBUCKET_WORKSPACE/$BITBUCKET_REPO"
curl -s -u "$BITBUCKET_EMAIL:$BITBUCKET_API_TOKEN" "$BB/pullrequests/87"

Operations

Operation Request
change.get GET $BB/pullrequests/<id> (title, description, source.branch.name, links), plus GET $BB/pullrequests/<id>/diffstat for changed files
change.diff GET $BB/pullrequests/<id>/diff (unified diff). Filter it to the files you need
change.comment POST $BB/pullrequests/<id>/comments with {"content":{"raw":"<markdown>"}}
find the PR for a branch GET $BB/pullrequests?q=source.branch.name="<branch>"&state=OPEN (the query must be URL-encoded)
ci.get_run GET $BB/pipelines/<uuid-or-build-number>, then GET $BB/pipelines/<uuid>/steps for each step's state
ci.job_log GET $BB/pipelines/<uuid>/steps/<step-uuid>/log. Keep the tail
ci.latest_run GET $BB/pipelines?target.branch=<branch>&sort=-created_on&pagelen=1
ci.lint no API. Check bitbucket-pipelines.yml parses and uses only known top-level keys (image, definitions, pipelines, options, clone)
project.check GET $BB
issue operations not supported here. Use QA_TRACKER=jira (provider-jira)
file.attach for PR comments, link the Pipelines artifacts of the run, or keep the local path

Notes

  • UUIDs come wrapped in braces ({1a2b…}). URL-encode them (%7B…%7D) in paths
  • Refs: report pull requests as #87 and pipelines by build number
  • Markdown: PR comments render it natively
  • Bitbucket Data Center uses a different API (/rest/api/1.0/projects/<key>/repos/<slug>/pull-requests/<id>). Say it isn't covered yet rather than guessing

04 同仓库更多 Skills

GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

write-tests

WAY 4 — write test cases only, no execution. Use when the user says "write it", "write tests", "generate test cases" — an approved test plan (`Plan:`), or requirements (text or a tracker issue) planned and approved first, optional App/Spec/MR or PR → exactly the planned test files.

★ 5
GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

verify-fix

WAY 9 — verify that a bug is fixed by running its regression test. Use when the user says "verify it", "verify fix", "is #142 fixed", "check the fix" with one or more bug refs (#142, SHOP-142), or "verify all" for every open bug that has a regression test.

★ 5
GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

user-story-format

Reference only — the single definition of this project's user-story body (story, Gherkin ACs, Missing Information, DoD) and its AC/scenario rules. Read by user-story-enhancer (WAY 6) and benchmark-gap-story-writer (WAY 8) so stories they write stay identical in shape and WAY 6 can re-score WAY 8's output. Not a workflow on its own.

★ 5
GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

tracker

Provider-neutral contract for every issue-tracker and code-host action (create/update/comment/close issues, attach files, comment on MRs/PRs, read CI runs and logs) plus label conventions and failure handling. Every WAY calls these operations; the matching provider-* skill says how to perform them on GitLab, GitHub, Jira, Azure DevOps, or Bitbucket.

★ 5
GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

traceability

WAY 14 — requirements traceability matrix for a user story (each acceptance criterion) or a test folder written from plain text (each R-NN requirement) → the tests covering it → their latest result → open bugs. Use when the user says "trace it", "traceability", "is #148 covered", "coverage of SHOP-148", "trace it <folder>".

★ 5
GhassenAZZOUZ
GhassenAZZOUZ/claude-qa-agent

test-plan

WAY 19 — design a test plan before any test code. Use when the user says "plan it", "plan tests", "test plan", "design tests" with requirements (text or a tracker issue), optional App/Spec/MR or PR. Output is the test plan (scope, levels, one row per Test#<nn> with category, tags, covers, priority, coverage, entry/exit criteria, risks), reviewed by `review-plan` (WAY 20), filed for approval; `write it Plan:` / `e2e it Plan:` then write exactly that plan. Also holds the plan format every other WAY reads.

★ 5