{"id":34707667,"url":"https://github.com/avivsinai/bitbucket-cli","last_synced_at":"2026-05-29T22:00:35.296Z","repository":{"id":321231552,"uuid":"1083689394","full_name":"avivsinai/bitbucket-cli","owner":"avivsinai","description":"Bitbucket CLI with gh-like ergonomics","archived":false,"fork":false,"pushed_at":"2026-05-27T07:03:32.000Z","size":1243,"stargazers_count":128,"open_issues_count":2,"forks_count":29,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-05-27T09:25:59.693Z","etag":null,"topics":["agent-skills","ai-agents","bitbucket","bitbucket-cloud","bitbucket-datacenter","ci-cd","claude-code","cli","codex","developer-tools","devops","git","golang","pull-requests"],"latest_commit_sha":null,"homepage":"https://github.com/avivsinai/bitbucket-cli","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/avivsinai.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":"SUPPORT.md","governance":"GOVERNANCE.md","roadmap":"docs/ROADMAP.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2025-10-26T14:32:48.000Z","updated_at":"2026-05-27T07:02:17.000Z","dependencies_parsed_at":"2025-10-28T15:35:06.245Z","dependency_job_id":null,"html_url":"https://github.com/avivsinai/bitbucket-cli","commit_stats":null,"previous_names":["avivsinai/bitbucket-cli"],"tags_count":60,"template":false,"template_full_name":null,"purl":"pkg:github/avivsinai/bitbucket-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avivsinai%2Fbitbucket-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avivsinai%2Fbitbucket-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avivsinai%2Fbitbucket-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avivsinai%2Fbitbucket-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/avivsinai","download_url":"https://codeload.github.com/avivsinai/bitbucket-cli/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/avivsinai%2Fbitbucket-cli/sbom","scorecard":{"id":1240342,"data":{"date":"2025-12-10T08:12:01Z","repo":{"name":"github.com/avivsinai/bitbucket-cli","commit":"b40cfad8466a5ee8414bc9f4e8fe36cf7efba08b"},"scorecard":{"version":"v5.3.0","commit":"c22063e786c11f9dd714d777a687ff7c4599b600"},"score":5.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/25 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"project was created within the last 90 days. Please review its contents carefully","details":["Warn: Repository was created within the last 90 days."],"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#maintained"}},{"name":"Dependency-Update-Tool","score":10,"reason":"update tool detected","details":["Info: detected update tool: Dependabot: .github/dependabot.yml:1"],"documentation":{"short":"Determines if the project uses a dependency update tool.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#dependency-update-tool"}},{"name":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: SECURITY.md:1","Info: Found linked content: SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: SECURITY.md:1","Info: Found text in security policy: SECURITY.md:1"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#security-policy"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:57: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:58: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:62: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:96: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:46: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:50: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/scorecard.yml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/scorecard.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/scorecard.yml:37: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/scorecard.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/scorecard.yml:46: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/scorecard.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/scorecard.yml:54: update your workflow using https://app.stepsecurity.io/secureworkflow/avivsinai/bitbucket-cli/scorecard.yml/master?enable=pin","Warn: downloadThenRun not pinned by hash: .github/workflows/release.yml:25","Info:   0 out of  12 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   4 third-party GitHubAction dependencies pinned","Info:   0 out of   1 downloadThenRun dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#pinned-dependencies"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'contents' permission set to 'read': .github/workflows/ci.yml:54","Info: jobLevel 'contents' permission set to 'read': .github/workflows/scorecard.yml:27","Info: jobLevel 'actions' permission set to 'read': .github/workflows/scorecard.yml:28","Info: topLevel 'contents' permission set to 'read': .github/workflows/ci.yml:10","Warn: topLevel 'security-events' permission set to 'write': .github/workflows/ci.yml:11","Warn: topLevel 'contents' permission set to 'write': .github/workflows/release.yml:9","Info: topLevel permissions set to 'read-all': .github/workflows/scorecard.yml:15","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":10,"reason":"SAST tool is run on all commits","details":["Info: all commits (6) are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#sast"}},{"name":"Packaging","score":10,"reason":"packaging workflow detected","details":["Info: Project packages its releases by way of GitHub Actions.: .github/workflows/release.yml:12"],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#packaging"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v0.2.2 not signed: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/269009244","Warn: release artifact v0.2.1 not signed: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/260911997","Warn: release artifact v0.2.0 not signed: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/257739210","Warn: release artifact v0.2.2 does not have provenance: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/269009244","Warn: release artifact v0.2.1 does not have provenance: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/260911997","Warn: release artifact v0.2.0 does not have provenance: https://api.github.com/repos/avivsinai/bitbucket-cli/releases/257739210"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#signed-releases"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#fuzzing"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#branch-protection"}},{"name":"Contributors","score":0,"reason":"project has 0 contributing companies or organizations -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project has a set of contributors from multiple organizations (e.g., companies).","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#contributors"}},{"name":"CI-Tests","score":10,"reason":"6 out of 6 merged PRs checked by a CI test -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project runs tests before pull requests are merged.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#ci-tests"}}]},"last_synced_at":"2025-12-10T09:18:49.164Z","repository_id":321231552,"created_at":"2025-12-10T09:18:49.165Z","updated_at":"2025-12-10T09:18:49.165Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33672125,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-29T02:00:06.066Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent-skills","ai-agents","bitbucket","bitbucket-cloud","bitbucket-datacenter","ci-cd","claude-code","cli","codex","developer-tools","devops","git","golang","pull-requests"],"created_at":"2025-12-24T23:31:49.510Z","updated_at":"2026-05-29T22:00:35.253Z","avatar_url":"https://github.com/avivsinai.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bkt – Bitbucket CLI\n\n\u003cp align=\"center\"\u003e\u003cem\u003eBitbucket Cloud \u0026 Data Center workflows for developers, coding agents, and automation-first teams.\u003c/em\u003e\u003c/p\u003e\n\n[![CI](https://github.com/avivsinai/bitbucket-cli/actions/workflows/ci.yml/badge.svg)](https://github.com/avivsinai/bitbucket-cli/actions/workflows/ci.yml)\n[![codecov](https://codecov.io/gh/avivsinai/bitbucket-cli/graph/badge.svg)](https://codecov.io/gh/avivsinai/bitbucket-cli)\n[![Release](https://img.shields.io/github/v/release/avivsinai/bitbucket-cli?cache=none)](https://github.com/avivsinai/bitbucket-cli/releases)\n[![Go Report Card](https://goreportcard.com/badge/github.com/avivsinai/bitbucket-cli?cache=none)](https://goreportcard.com/report/github.com/avivsinai/bitbucket-cli)\n[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/avivsinai/bitbucket-cli/badge)](https://scorecard.dev/viewer/?uri=github.com/avivsinai/bitbucket-cli)\n[![Go Reference](https://pkg.go.dev/badge/github.com/avivsinai/bitbucket-cli.svg)](https://pkg.go.dev/github.com/avivsinai/bitbucket-cli)\n[![License](https://img.shields.io/github/license/avivsinai/bitbucket-cli?cache=none)](LICENSE)\n\n`bkt` is a stand-alone Bitbucket command-line interface that targets Bitbucket Data Center **and** Bitbucket Cloud. It mirrors the ergonomics of `gh` and delivers a consistent JSON/YAML contract for automation.\n\n**Built for AI \u0026 automation:** Drop `bkt` into Claude Code, Codex and other coding agents, or shell scripts and they inherit structured output, predictable flags, and safe defaults—no glue code required.\n\n## Installation\n\n### Homebrew (macOS/Linux)\n\n```bash\nbrew install avivsinai/tap/bitbucket-cli\n```\n\n### Scoop (Windows)\n\n```powershell\nscoop bucket add avivsinai https://github.com/avivsinai/scoop-bucket\nscoop install bitbucket-cli\n```\n\n### Go Install\n\n```bash\ngo install github.com/avivsinai/bitbucket-cli/cmd/bkt@latest\n```\n\nThis installs `bkt` to `$GOPATH/bin` (or `$HOME/go/bin` by default). Ensure the directory is in your `$PATH`.\n\n### Nix (NixOS / nix-darwin / Linux / macOS)\n\nRun the latest `master` without installing:\n\n```bash\nnix run github:avivsinai/bitbucket-cli -- --version\n```\n\nInstall into your user profile:\n\n```bash\nnix profile install github:avivsinai/bitbucket-cli\n```\n\nPin to a specific tag or commit by appending a ref (e.g. `github:avivsinai/bitbucket-cli/v1.2.3`).\n\nDon't have Nix yet? See [nixos.asia/en/install](https://nixos.asia/en/install) for a quick setup guide (installs Nix with flakes enabled out of the box).\n\n### Binary Downloads\n\nDownload pre-built binaries for your platform from the [releases page](https://github.com/avivsinai/bitbucket-cli/releases/latest).\nThe `.tar.gz` and `.zip` release archives also include `skills/bkt/`, so the CLI and canonical skill files stay in sync when you install from a release artifact.\n\nOfficial binaries support Bitbucket Cloud OAuth (`bkt auth login --kind cloud --web`) out of the box. Source and Nix builds can use the same flow by setting `BKT_OAUTH_CLIENT_ID` and `BKT_OAUTH_CLIENT_SECRET` in the environment. API-token login via `--web-token` works without that extra setup.\n\n### Bitbucket Pipelines\n\n`bkt` supports fully config-free headless use via environment variables. Set `BKT_TOKEN` and `BKT_HOST` as secured [repository variables](https://support.atlassian.com/bitbucket-cloud/docs/variables-and-secrets/) — no prior `bkt auth login` or `bkt context create` step required.\n\n```yaml\npipelines:\n  default:\n    - step:\n        name: Open PR\n        script:\n          - export BKT_VERSION=\"0.26.0\"  # pin to a released version\n          - curl -sL \"https://github.com/avivsinai/bitbucket-cli/releases/download/v${BKT_VERSION}/bkt_${BKT_VERSION}_linux_x86_64.tar.gz\" | tar xz -C /tmp \u0026\u0026 install /tmp/bkt /usr/local/bin/\n          - bkt pr create --title \"Auto PR\" --source \"$BITBUCKET_BRANCH\"\n```\n\n### Environment Variables\n\nAll `bkt` behaviour can be configured via environment variables, which is especially useful in containers and CI/CD pipelines.\n\n| Variable | Description |\n|---|---|\n| `BKT_TOKEN` | Authentication token. Bypasses keyring storage entirely. |\n| `BKT_HOST` | Bitbucket server base URL (e.g. `https://bitbucket.example.com`). Required alongside `BKT_TOKEN` for config-free use. `bitbucket.org` is auto-detected as Cloud. |\n| `BKT_USERNAME` | Username for basic authentication in headless mode. |\n| `BKT_AUTH_METHOD` | Authentication method: `basic` or `bearer`. DC defaults to `bearer` when `BKT_USERNAME` is absent; Cloud always uses `basic`. |\n| `BKT_PROJECT` | Default Data Center project key (headless mode). |\n| `BKT_WORKSPACE` | Default Bitbucket Cloud workspace (headless mode). |\n| `BKT_REPO` | Default repository slug (headless mode). |\n| `BKT_CONFIG_DIR` | Override the config file directory (default: `$XDG_CONFIG_HOME/bkt`). |\n| `BKT_HTTP_DEBUG` | Set to `1` to log HTTP request URLs and response status codes. |\n| `BKT_ALLOW_INSECURE_STORE` | Set to `1` to use encrypted file fallback when no OS keychain is available. |\n\n**Minimal headless example (Data Center):**\n\n```bash\nexport BKT_HOST=https://bitbucket.example.com\nexport BKT_TOKEN=my-personal-access-token\nexport BKT_PROJECT=MYPROJ\nexport BKT_REPO=my-service\n\nbkt pr list\nbkt pr create --title \"Automated PR\" --source feature/my-branch\n```\n\n**Minimal headless example (Bitbucket Cloud):**\n\n```bash\nexport BKT_HOST=https://bitbucket.org\nexport BKT_TOKEN=my-api-token\nexport BKT_USERNAME=me@example.com\nexport BKT_WORKSPACE=my-workspace\nexport BKT_REPO=my-repo\n\nbkt pr list\n```\n\n### From Source\n\n```bash\ngit clone https://github.com/avivsinai/bitbucket-cli.git\ncd bitbucket-cli\nmake build   # produces ./bin/bkt\n./bin/bkt --help\n```\n\n### Claude Code / Codex Skill\n\nInstall the `bkt` skill to give Claude Code or Codex CLI native Bitbucket knowledge:\n\n\u003cdetails open\u003e\n\u003csummary\u003e\u003cb\u003eVia skills (Recommended)\u003c/b\u003e\u003c/summary\u003e\n\nUsing [Vercel's skills CLI](https://github.com/vercel-labs/add-skill):\n\n```bash\nnpx skills add avivsinai/bitbucket-cli -g -y\n```\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cb\u003eVia skild registry\u003c/b\u003e\u003c/summary\u003e\n\n```bash\nnpx skild install @avivsinai/bkt -t claude -y\n```\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cb\u003eVia Skills Marketplace\u003c/b\u003e\u003c/summary\u003e\n\n\u003e **Known Issue**: Claude Code uses SSH to clone marketplace repos, which fails without SSH keys configured. See [issue #14485](https://github.com/anthropics/claude-code/issues/14485). Use the skills or skild methods instead.\n\n```bash\n/plugin marketplace add avivsinai/skills-marketplace\n/plugin install bkt@avivsinai-marketplace\n```\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cb\u003eManual install\u003c/b\u003e\u003c/summary\u003e\n\n```bash\ngit clone https://github.com/avivsinai/bitbucket-cli.git\ncp -r bitbucket-cli/.claude/skills/bkt ~/.claude/skills/\n```\n\n\u003c/details\u003e\n\n## Getting started\n\nAfter installation, verify it works:\n\n```bash\nbkt --help\n```\n\n### 1. Authenticate against Bitbucket Data Center or Cloud\n\n#### Bitbucket Data Center\n\n```bash\n# Guided flow: opens browser to create a Personal Access Token\nbkt auth login https://bitbucket.mycorp.example --web-token\n\n# Or provide credentials directly\nbkt auth login https://bitbucket.mycorp.example --username alice --token \u003cPAT\u003e\n```\n\nCreate a **Personal Access Token (PAT)** in Bitbucket Data Center:\n1. Go to **Profile picture → Manage account → Personal access tokens**\n2. Click **Create a token**\n3. Grant permissions: **Repository Read**, **Repository Write**, **Project Read**\n4. Copy the token (you won't see it again)\n\n#### Bitbucket Cloud\n\n```bash\n# Browser OAuth flow for Bitbucket Cloud\nbkt auth login https://bitbucket.org --kind cloud --web\n\n# Or provide credentials directly\nbkt auth login https://bitbucket.org --kind cloud --username \u003cemail\u003e --token \u003capi-token\u003e\n```\n\nCreate an **API token with scopes** for Bitbucket Cloud:\n1. Go to [Atlassian Account Settings](https://id.atlassian.com/manage-profile/security/api-tokens)\n2. Click **Create and manage API tokens** → **Create API token with scopes**\n3. Name your token and set an expiry date\n4. **Select \"Bitbucket\" as the application** (required!)\n5. Grant scopes:\n   - **Account: Read (`read:user:bitbucket`)** — Required for authentication\n   - **Repositories: Read, Write** — For repo commands\n   - **Pull requests: Read, Write** — For PR commands\n   - **Issues: Read, Write** — For issue commands (optional)\n6. Click **Create** and copy the token immediately\n\n\u003e **Warning:** General Atlassian API tokens won't work. You must select \"Bitbucket\" as the application when creating the token.\n\n\u003e **Note:** Use your **Atlassian account email** as the username (not your Bitbucket username).\n\n\u003cdetails\u003e\n\u003csummary\u003eLegacy: App passwords (deprecated)\u003c/summary\u003e\n\nApp passwords are deprecated. New app passwords cannot be created since September 2025, and existing ones will stop working June 2026. If you have an existing app password:\n\n```bash\nbkt auth login https://bitbucket.org --kind cloud --username \u003cbitbucket-username\u003e --token \u003capp-password\u003e\n```\n\nNote: For app passwords, use your **Bitbucket username** (not email).\n\n\u003c/details\u003e\n\n#### Credential storage\n\nAccess tokens are stored in your OS keychain (Keychain Access on macOS, Windows Credential Manager, or\nSecret Service/KWallet on Linux) while host metadata lives in\n`$XDG_CONFIG_HOME/bkt/config.yml`. Pass `--allow-insecure-store` (or set\n`BKT_ALLOW_INSECURE_STORE=1`) to permit the encrypted file backend on systems\nwithout a native keychain.\n\nIf your keyring requires an interactive unlock prompt, you can increase the keyring timeout via\n`BKT_KEYRING_TIMEOUT` (for example `BKT_KEYRING_TIMEOUT=2m`).\n\n##### macOS note: Keychain prompts after `brew upgrade`\n\nOn macOS, every `brew upgrade bkt` may trigger one Keychain prompt because the\nstored item's ACL is tied to the installed binary. Re-run `bkt auth login` once\nafter the upgrade to refresh the ACL, then subsequent invocations should not\nprompt. Releases pin the Designated Requirement to the bundle identifier, so\nthe refresh is only needed once. Run `bkt auth doctor` to diagnose prompts\nthat persist beyond that; it never reads the stored secret.\n\n### 2. Create and activate a context\n\n#### Bitbucket Data Center\n\n```bash\nbkt context create dc-prod --host bitbucket.mycorp.example --project ABC --set-active\nbkt context list\n```\n\n#### Bitbucket Cloud\n\n```bash\nbkt context create cloud-prod --host api.bitbucket.org --workspace myteam --set-active\nbkt context list\n```\n\n\u003e **Tip:** Run `bkt auth status` to see configured hosts and the exact host value to use with `--host`.\n\nContexts capture the host mapping, default project/workspace, and optional default repository for commands.\n\n### 3. Work with repositories\n\n```bash\nbkt repo list --limit 20\nbkt repo list --workspace myteam --limit 10   # Cloud workspace override\nbkt repo view platform-api\nbkt repo create data-pipeline --description \"Data ingestion\" --project DATA\nbkt repo browse --project DATA --repo platform-api\nbkt repo clone platform-api --project DATA --ssh\n```\n\n`repo list`/`repo view` automatically target the right REST API for your active context: Data Center uses `/rest/api/1.0/projects/{projectKey}/repos`, while Cloud uses `/2.0/repositories/{workspace}`.\n\n### 4. Pull request workflows\n\n```bash\nbkt pr list --state OPEN --limit 10\nbkt pr create --title \"feat: cache\" --source feature/cache --target main --reviewer alice\nbkt pr merge 42 --message \"merge: feature/cache\"\nbkt pr checks 42                              # Show build/CI status\nbkt pr checks 42 --wait                       # Wait for builds to complete\nbkt pr checks 42 --wait --timeout 5m          # Wait with timeout\nbkt pr checks 42 --wait --max-interval 1m     # Custom backoff cap\n```\n\nThe CLI wraps Bitbucket pull-request endpoints for creation, listing, review, and merge operations. The `checks` command displays build status with color-coded output (green for success, red for failure, yellow for in-progress) and supports polling until all builds complete. Polling uses exponential backoff with jitter to avoid overwhelming the API during long builds.\n\n### 5. Issue tracking (Bitbucket Cloud only)\n\n```bash\nbkt issue list --state open --kind bug           # List open bugs\nbkt issue view 42 --comments                     # View issue with comments\nbkt issue create -t \"Login broken\" -k bug -p major\nbkt issue edit 42 --assignee \"{abc-123}\" --priority critical\nbkt issue close 42                               # Close an issue\nbkt issue reopen 42                              # Reopen a closed issue\nbkt issue comment 42 -b \"Fixed in v1.2.0\"        # Add a comment\nbkt issue status                                 # Show your assigned/created issues\n\n# Attachments\nbkt issue attachment list 42                     # List attachments\nbkt issue attachment upload 42 screenshot.png    # Upload file(s)\nbkt issue attachment download 42 --all           # Download all attachments\nbkt issue attachment delete 42 old-file.txt      # Delete an attachment\n```\n\nNote: The issue tracker is only available for Bitbucket Cloud. Bitbucket Data Center uses Jira for issue tracking.\n\n### 6. Branch, permission, webhook, pipeline, and extension management\n\n```bash\nbkt branch list --workspace myteam           # Cloud branch listing\nbkt branch create release/1.9 --from main    # Data Center branch utils\nbkt perms repo list --project DATA --repo platform-api\nbkt webhook create --name \"CI\" --url https://ci.example.com/hook --event repo:refs_changed\nbkt pipeline run --workspace myteam --repo api --ref main --var ENV=staging\nbkt extension install https://github.com/example/bkt-hello.git\nbkt extension exec hello -- --flag=1\nbkt status pipeline {pipeline-uuid}\nbkt status rate-limit\n```\n\nBranch utilities use Bitbucket's Branch Utils REST API for listing, creation, deletion, and default updates. Permission and webhook commands map to their respective REST endpoints for consistent automation.\n\nExtensions are cloned into `$XDG_CONFIG_HOME/bkt/extensions` (or the directory configured via `BKT_CONFIG_DIR`) and executed in-place. Binaries should follow the `bkt-\u003cname\u003e` naming convention so the CLI can discover them automatically.\n\n### Structured output \u0026 raw API access\n\nEvery command supports the global `--json` and `--yaml` flags for automation-ready output.\n\nFor endpoints that are not yet wrapped, reach directly for the API escape hatch:\n\n```bash\nbkt api /rest/api/1.0/projects --param limit=100 --json\nbkt api /repositories --param workspace=myteam --field pagelen=50\n```\n\n## Security\n\nThis project uses automated secret scanning ([gitleaks](https://github.com/gitleaks/gitleaks)), dependency updates ([Dependabot](https://github.com/dependabot)), and security posture tracking ([OSSF Scorecard](https://github.com/ossf/scorecard)).\n\nFound a security issue? See our [security policy](SECURITY.md) for responsible disclosure.\n\n## Development\n\n### Project Layout\n\n```\ncmd/bkt/             # CLI entry point\ninternal/bktcmd/     # Main() wiring (factory + root command)\ninternal/build/      # Version metadata (overridden via ldflags)\ninternal/config/     # Context and host configuration\ninternal/remote/     # Git remote parsing utilities\npkg/cmd/             # Cobra command implementations (auth, repo, pr, ...)\npkg/cmdutil/         # Shared command helpers and factory wiring\npkg/iostreams/       # IO stream abstractions\npkg/bbdc/            # Bitbucket Data Center client implementation\npkg/bbcloud/         # Bitbucket Cloud client implementation\npkg/format/          # Output rendering helpers\npkg/httpx/           # Shared HTTP client and retry logic\n```\n\n### Building \u0026 Testing\n\n```bash\nmake build      # Build the binary to ./bin/bkt\nmake test       # Run unit tests\nmake fmt        # Format code\nmake lint       # Run linters\nmake tidy       # Tidy go modules\n```\n\n`go test ./...` runs fast smoke coverage that wires the CLI against an in-memory Bitbucket mock (see `pkg/cmd/smoke/cli_smoke_test.go`).\n\n## Troubleshooting\n\n### Debug HTTP Requests\n\nTo see API request URLs and response status codes, set the `BKT_HTTP_DEBUG` environment variable:\n\n```bash\nBKT_HTTP_DEBUG=1 bkt pipeline view 10\n```\n\nThis outputs request method/URL and response status, useful for diagnosing API errors.\n\n## Support\n\n- **Questions / Ideas**: File an [issue](https://github.com/avivsinai/bitbucket-cli/issues/new?template=feature_request.md)\n- **Bug Reports**: File an [issue](https://github.com/avivsinai/bitbucket-cli/issues/new?template=bug_report.md)\n\n## License\n\n`bkt` is available under the [MIT License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Favivsinai%2Fbitbucket-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Favivsinai%2Fbitbucket-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Favivsinai%2Fbitbucket-cli/lists"}