Skip to main content
Glama
bitbucket-mcp

bitbucket-mcp

by nevzatcirak

Post pull request comment

bb_post_pull_request_comment

Post pull request comments at PR level or inline on files and lines; optionally create blocker follow-up tasks or draft comments on Server/DC.

Instructions

Post a comment on a pull request: PR-level, or inline with file+line (and startLine for multiline suggestion blocks). severity=BLOCKER additionally creates a follow-up task (on Cloud it also prefixes the text with '[BLOCKER]'). pending=true drafts the comment on Server/DC (rejected on Cloud — no draft support).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "projectKey": "<projectKey>",
      "repositorySlug": "<repositorySlug>",
      "pullRequestId": "<pullRequestId>",
      "text": "<text>"
    },
    "name": "bb_post_pull_request_comment"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileNoFile path for an inline comment (omit for PR-level).
lineNoLine number for an inline comment (required with file).
textYesComment text (markdown); wrap lines in a ```suggestion block for suggestions.
pendingNotrue = draft the comment (Server/DC only); publish it via bb_submit_pull_request_review.
lineTypeNoWhich side of the diff the anchored line belongs to.ADDED
severityNoBLOCKER additionally creates a follow-up task.NORMAL
taskTextNoCustom task text when severity=BLOCKER.
startLineNoFirst line of a multi-line comment/suggestion block.
projectKeyYesProject key (on Cloud: workspace slug).
pullRequestIdYesPull request id.
repositorySlugYesRepository slug.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does disclose non-obvious side effects: severity=BLOCKER creates a follow-up task and prefixes text with '[BLOCKER]' on Cloud, and pending=true drafts rather than publishes (and is rejected on Cloud). It omits permission/auth requirements and what happens on error, which keeps it below a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single dense sentence that front-loads the core action and then layers the mode, severity, and draft details in order of importance. Every clause earns its place; the nested parentheticals make it slightly heavy to parse but nothing is wasteful.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 11-parameter mutation tool with no annotations and no output schema, the description covers the tricky behavioral divergences (Cloud vs Server/DC draft support, BLOCKER follow-up task) that the schema cannot express. It leaves return-value expectations and permission prerequisites unstated, which are the remaining gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter is already documented in the schema, establishing a baseline of 3. The description reinforces key relationships (file+line pairing, startLine for multiline blocks, severity side effect, pending platform restriction) but adds little semantics not already present in the parameter descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Post a comment on a pull request') and immediately differentiates the two modes: PR-level versus inline anchored with file+line. An agent can tell this apart from bb_update_pull_request_comment or bb_submit_pull_request_review without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear conditional guidance: use file+line (plus startLine) for inline comments, omit for PR-level, and pending=true only on Server/DC since Cloud rejects drafts. It does not explicitly route the agent to the update or submit-review siblings, but the platform-based exclusions for draft mode are real, actionable when-not guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.