Skip to content

Comments

Manage pull request comments.

Global options available on all PR commands: --json [fields], --jq <expression>, --no-color, -w, --workspace, -r, --repo.

Every bb pr comments subcommand accepts those globals. They work the same everywhere, so the per-command examples below leave them out:

Terminal window
# Target a repository other than the one you are standing in
bb pr comments list 42 -w myworkspace -r myrepo
# Machine-readable output
bb pr comments list 42 --json

view, edit, reply, resolve, and unresolve have no options of their own — only the globals.

Subcommand Description
list <id> List comments on a pull request
add <id> <message> Add a comment to a pull request
view <pr-id> <comment-id> View a single comment on a pull request
edit <pr-id> <comment-id> <message> Edit a comment on a pull request
reply <pr-id> <comment-id> <message> Reply to a comment on a pull request
resolve <pr-id> <comment-id> Resolve a comment thread on a pull request
unresolve <pr-id> <comment-id> Reopen a resolved comment thread on a pull request
delete <pr-id> <comment-id> Delete a comment on a pull request

List comments on a pull request.

Terminal window
bb pr comments list <id> [options]
Argument Description
id Pull request ID
Option Description Default
--limit <number> Maximum number of comments 25
--all List all comments (overrides --limit)
--resolved Only show resolved comments
--unresolved Only show unresolved comments
--no-truncate Global flag. Show full comment content without truncation
Terminal window
# List comments on PR #42
bb pr comments list 42
# Only comments that still need attention
bb pr comments list 42 --unresolved
# List more comments
bb pr comments list 42 --limit 50
# List every comment
bb pr comments list 42 --all
# Show full comment content (not truncated)
bb pr comments list 42 --no-truncate

Output:

ID Author Content Status Date
--------- -------- ------------------------------- -------- ------------------------
486512301 Jane Doe Consider renaming this variable resolved Jul 28, 2026 at 11:14 AM
486512477 Sam Ali Good catch, fixed. open Jul 28, 2026 at 12:02 PM
486513002 Jane Doe Why was this removed? open Jul 29, 2026 at 10:41 AM
  • Comment content is truncated to 60 characters in the table view. Use --no-truncate for the full text
  • The Status column shows resolved, pending, or open. Bitbucket records resolution on the comment that was resolved, so a reply inside a resolved thread shows open (or pending if it is an unpublished draft)
  • --resolved and --unresolved filter on the same resolution state and cannot be combined
  • With --resolved/--unresolved the filter is applied client-side after each page is fetched, so --limit counts comments that survive the filter — --unresolved --limit 25 keeps fetching pages until 25 unresolved comments are found or the list is exhausted
  • When the result is capped by --limit, a hint shows how many were listed; use a higher --limit or --all to see the rest (suppressed with --json)

Add a general comment, or an inline comment anchored to a file line.

Terminal window
bb pr comments add <id> <message> [options]
Argument Description
id Pull request ID
message Comment message
Option Description
--file <path> File path for an inline comment (requires --line-to and/or --line-from)
--line-to <number> Line number in the new version of the file (requires --file)
--line-from <number> Line number in the old version of the file (requires --file)
Terminal window
# Add a general comment to PR #42
bb pr comments add 42 "LGTM! This looks great."
# Inline comment on a line in the new file
bb pr comments add 42 "Consider renaming this variable" --file src/index.ts --line-to 15
# Inline comment on a line in the old (removed) version of the file
bb pr comments add 42 "Why was this removed?" --file src/utils.ts --line-from 10
# Inline comment spanning old and new lines
bb pr comments add 42 "This logic changed" --file src/app.ts --line-from 5 --line-to 8
  • --file is required when using --line-to or --line-from
  • At least one of --line-to or --line-from is required when using --file
  • Line numbers must be positive integers

View a single comment, including whether it is resolved.

Terminal window
bb pr comments view <pr-id> <comment-id>
Argument Description
pr-id Pull request ID
comment-id Comment ID
Terminal window
# View comment #486512301 on PR #42
bb pr comments view 42 486512301
  • The header shows [resolved] or [unresolved] for that specific comment. Bitbucket records the resolution on the comment that was resolved, so a reply inside a resolved thread still shows [unresolved]
  • Unpublished draft review comments show [pending] instead
  • Deleted comments render their content as [deleted]
  • --json prints the raw comment object returned by the API

Edit a comment on a pull request.

Terminal window
bb pr comments edit <pr-id> <comment-id> <message>
Argument Description
pr-id Pull request ID
comment-id Comment ID
message New comment message
Terminal window
# Replace the body of comment #486512301 on PR #42
bb pr comments edit 42 486512301 "Updated: I noticed something else..."

Reply to an existing comment. The reply is attached to the parent comment, so it lands in the same thread.

Terminal window
bb pr comments reply <pr-id> <comment-id> <message>
Argument Description
pr-id Pull request ID
comment-id ID of the comment to reply to
message Reply message
Terminal window
# Reply to comment #486512301 on PR #42
bb pr comments reply 42 486512301 "Good catch, fixed."
  • Use bb pr comments list <id> to find the comment ID to reply to
  • How Bitbucket anchors a reply to an inline comment is decided server-side

Resolve a comment thread on a pull request.

Terminal window
bb pr comments resolve <pr-id> <comment-id>
Argument Description
pr-id Pull request ID
comment-id Comment ID
Terminal window
# Resolve comment thread #486512301 on PR #42
bb pr comments resolve 42 486512301
  • Resolving is reversible with bb pr comments unresolve
  • --json returns { success, pullRequestId, commentId, resolution }; the API returns the resolution record, not the full comment — use bb pr comments view to read the comment back

Reopen a resolved comment thread on a pull request.

Terminal window
bb pr comments unresolve <pr-id> <comment-id>
Argument Description
pr-id Pull request ID
comment-id Comment ID
Terminal window
# Reopen comment thread #486512301 on PR #42
bb pr comments unresolve 42 486512301
  • The API returns no body, so --json reports only { success, pullRequestId, commentId }

Delete a comment from a pull request. --yes is required.

Terminal window
bb pr comments delete <pr-id> <comment-id> [options]
Argument Description
pr-id Pull request ID
comment-id Comment ID
Option Description
-y, --yes Confirm deletion (required)
Terminal window
# Delete comment #486512301 from PR #42
bb pr comments delete 42 486512301 --yes
  • bb pr comments delete never prompts. Without --yes it exits with a validation error ending in Use --yes to confirm.
  • Deleting a comment is permanent and cannot be undone