Work with Bitbucket from chat — browse repositories, inspect files, manage branches, review pull requests, and coordinate repository workflows via the Bitbucket Cloud API with OAuth authentication.
This skill uses ClawLink for hosted connection flows and credentials so you do not need to configure Bitbucket API access yourself.
| Step 1: Install | Step 2: Pair Account | Step 3: Connect Bitbucket |
|---|---|---|
| :---: | :---: | :---: |
| !Install | !Pair | App-specific connection GIF coming soon |
| Run the install command in OpenClaw | Sign in and approve the device | Open the dashboard and connect Bitbucket |
┌─────────────────┐ ┌──────────────┐ ┌──────────────────────┐
│ OpenClaw │────▶│ ClawLink │────▶│ Bitbucket Cloud API │
│ (User Chat) │ │ (OAuth) │ │ (Repos/PRs/Branches)│
└─────────────────┘ └──────────────┘ └──────────────────────┘
│ │ │
│ 1. Install Plugin │ │
│ 2. Pair Device │ │
│ 3. Connect Bitbucket │ │
│ │ 4. Secure Token │
│ │ 5. Proxy Requests │
│ │ │
▼ ▼ ▼
┌──────────┐ ┌──────────┐ ┌──────────┐
│ SKILL │ │ Dashboard│ │ Bitbucket│
│ File │ │ Auth │ │ Cloud │
└──────────┘ └──────────┘ └──────────┘
Install the verified ClawLink plugin from ClawHub. After the user confirms, complete the full setup so ClawLink tools are visible in the next OpenClaw chat.
openclaw plugins install clawhub:clawlink-plugin
openclaw config set tools.alsoAllow '["clawlink-plugin"]' --strict-json
openclaw gateway restart
Then tell the user: "OpenClaw has been restarted. Send /new as a standalone message to start a fresh chat, then ask for Bitbucket again."
# List repositories in a workspace
clawlink_call_tool --tool "bitbucket_list_repositories_in_workspace" --params '{"workspace": "your-workspace"}'
# List branches in a repository
clawlink_call_tool --tool "bitbucket_list_branches" --params '{"workspace": "your-workspace", "repo_slug": "your-repo"}'
# Get a pull request
clawlink_call_tool --tool "bitbucket_get_pull_request" --params '{"workspace": "your-workspace", "repo_slug": "your-repo", "pull_request_id": 1}'
All Bitbucket tool calls are authenticated automatically by ClawLink using the user's connected Bitbucket account.
No API key is required in chat. ClawLink stores the OAuth token securely and injects it into every Bitbucket API request on the user's behalf.
clawlink_begin_pairing if it is not configured yet.clawlink_list_integrations to verify the connection is active.clawlink_list_integrations
Response: Returns all connected integrations. Look for bitbucket in the list.
clawlink_list_tools --integration bitbucket
Response: Returns the live tool catalog for Bitbucket.
If Bitbucket tools are missing or the connection shows an error:
clawlink_list_integrations to verifyclawlink_list_tools --integration bitbucket| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_repositories_in_workspace | List repositories in a workspace | Read |
bitbucket_list_repositories | List public repositories | Read |
bitbucket_get_repository | Get repository metadata | Read |
bitbucket_create_repository | Create a new repository in a workspace | Write |
bitbucket_delete_repository | Permanently delete a repository | Write |
bitbucket_browse_repository_path | Get file content or list directory at a revision | Read |
bitbucket_get_file_from_repository | Get a specific file's content at a commit | Read |
bitbucket_list_repository_paths | List files and directories under a path | Read |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_branches | List branches with optional name filtering | Read |
bitbucket_get_branch | Get branch metadata and target commit | Read |
bitbucket_create_branch | Create a new branch from a target commit | Write |
bitbucket_get_repositories_branching_model | Get the repository's branch workflow configuration | Read |
bitbucket_get_repositories_effective_branching_model | Get effective branching model (including inheritance) | Read |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_commits | List commits with optional branch/path filters | Read |
bitbucket_get_repositories_commit | Get detailed commit information | Read |
bitbucket_get_commit_diff | Get the unified diff for a commit or range | Read |
bitbucket_get_commit_changes | Get changed files in a commit | Read |
bitbucket_get_commit_build_status | Get build status for a commit | Read |
bitbucket_get_commit_diffstat | Get diffstat (files changed, lines added/removed) | Read |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_pull_requests | List pull requests by state (OPEN/MERGED/DECLINED) | Read |
bitbucket_get_pull_request | Get a single pull request with full details | Read |
bitbucket_get_pull_request_commits | Get commits included in a PR | Read |
bitbucket_get_pull_request_diff | Get the unified diff for a PR | Read |
bitbucket_get_pull_request_diffstat | Get diffstat for a PR | Read |
bitbucket_create_pull_request | Create a new pull request | Write |
bitbucket_update_pull_request | Update PR title, description, or reviewers | Write |
bitbucket_merge_pull_request | Merge a pull request | Write |
bitbucket_approve_pull_request | Approve a pull request | Write |
bitbucket_request_pull_request_changes | Request changes on a PR | Write |
bitbucket_create_pull_request_comment | Add a top-level or threaded comment to a PR | Write |
bitbucket_delete_pull_request_comment | Delete a PR comment | Write |
bitbucket_resolve_pull_request_comment | Resolve or reopen a PR comment thread | Write |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_issues | List issues with optional state/priority filters | Read |
bitbucket_create_issue | Create a new issue | Write |
bitbucket_update_issue | Update issue attributes | Write |
bitbucket_delete_issue | Permanently delete an issue | Write |
bitbucket_create_issue_comment | Add a comment to an issue | Write |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_get_current_user | Get the authenticated user's profile | Read |
bitbucket_list_workspaces | List workspaces accessible to the user | Read |
bitbucket_get_workspace | Get workspace metadata | Read |
bitbucket_list_workspace_members | List members of a workspace | Read |
bitbucket_list_workspace_projects | List projects in a workspace | Read |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_list_pipelines | List pipeline runs for a repository | Read |
bitbucket_get_repositories_pipelines2 | Get a specific pipeline's details | Read |
bitbucket_list_repositories_environments | List deployment environments | Read |
bitbucket_list_deployments | List deployment history | Read |
| Tool | Description | Mode |
|---|---|---|
| ------ | ------------- | ------ |
bitbucket_get_workspaces_search_code | Search code across all repos in a workspace | Read |
bitbucket_search_user_repositories_code | Search code in a specific user's repos | Read |
clawlink_call_tool --tool "bitbucket_list_branches" \
--params '{
"workspace": "your-workspace",
"repo_slug": "your-repo",
"q": "name~\"feature\""
}'
clawlink_call_tool --tool "bitbucket_create_pull_request" \
--params '{
"workspace": "your-workspace",
"repo_slug": "your-repo",
"title": "Add new feature",
"source_branch": "feature/new-feature",
"destination_branch": "main",
"description": "This PR adds the new feature as described in issue #123"
}'
clawlink_call_tool --tool "bitbucket_approve_pull_request" \
--params '{
"workspace": "your-workspace",
"repo_slug": "your-repo",
"pull_request_id": 42
}'
clawlink_call_tool --tool "bitbucket_get_file_from_repository" \
--params '{
"workspace": "your-workspace",
"repo_slug": "your-repo",
"path": "README.md",
"commit_revision": "main"
}'
clawlink_list_integrations to confirm Bitbucket is connected.clawlink_list_tools --integration bitbucket to see the live catalog.clawlink_search_tools with a short query and integration bitbucket.┌─────────────────────────────────────────────────────────────┐
│ READ OPERATIONS (Safe) │
│ list → get → search → describe → call │
│ │
│ Example: List repos → List branches → Show results │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ WRITE OPERATIONS (Require Confirmation) │
│ list → get → describe → preview → confirm → call │
│ │
│ Example: Describe tool → Preview changes → User approves │
│ → Execute update │
└─────────────────────────────────────────────────────────────┘
clawlink_describe_tool first.whenToUse, askBefore, safeDefaults, examples, and followups to shape the call.clawlink_preview_tool first.clawlink_call_tool. Pass confirmation only after the preview matches the user's intent.refs/heads/ prefix.bitbucket_list_pull_requests to find PR IDs.next field in responses to iterate through large result sets.| Status / Error | Meaning |
|---|---|
| ---------------- | --------- |
| Tool not found | The tool name does not exist in the current catalog. Verify with clawlink_list_tools --integration bitbucket. |
| Missing connection | Bitbucket is not connected. Direct the user to https://claw-link.dev/dashboard?add=bitbucket. |
BranchNotFound | Branch does not exist. Check the branch name. |
PullRequestNotFound | Pull request does not exist. Check the PR ID. |
RepositoryNotFound | Repository does not exist or is not accessible. |
InvalidArgument | Invalid parameter or missing required field. Review the tool schema with clawlink_describe_tool. |
| Write rejected | User did not confirm a write action. Always confirm before executing writes. |
```bash
openclaw plugins list
```
/new as a standalone message to reload the catalog.```bash
openclaw config set tools.alsoAllow '["clawlink-plugin"]' --strict-json
openclaw gateway restart
```
/new again and retry.bitbucket.clawlink_describe_tool to verify parameter names and types before calling.clawlink_preview_tool first.Powered by ClawLink — an integration hub for OpenClaw
共 2 个版本