Skip to main content
Glama
Azure DevOps MCP Server
by billg118

add_pull_request_comment

Adds a comment to an Azure DevOps pull request, optionally targeting a file, line, or existing thread for code review feedback.

Instructions

Add a comment to a pull request (repositoryId optional; derived from pullRequestId when omitted)

Input Schema

NameRequiredDescriptionDefault
statusNoThe status to set for a new thread
contentYesThe content of the comment in markdown
filePathNoThe path of the file to comment on (for new thread on file)
threadIdNoThe ID of the thread to add the comment to
projectIdNoThe ID or name of the project (Default: no default project)
lineNumberNoThe line number to comment on (for new thread on file)
repositoryIdNoThe ID or name of the repository (optional; derived from pullRequestId when omitted)
pullRequestIdYesThe ID of the pull request
organizationIdNoThe ID or name of the organization (Default: example-org)
parentCommentIdNoID of the parent comment when replying to an existing comment

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.54

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden for a write operation. It says nothing about required permissions, whether adding a comment creates a new thread, whether the optional status enum only applies to newly created threads, or whether the operation is reversible or notifiable to reviewers.

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?

It is a single front-loaded sentence with the core action first and the caveat in parentheses; there is no filler. The sizing is efficient, though arguably too terse for a ten-parameter mutation tool.

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

Completeness2/5

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

With ten parameters, two distinct comment topologies, a status enum, no annotations, and no output schema, the definition is far too thin. An agent cannot tell from the description which parameter combination produces a thread-anchored comment versus a reply, or what the call returns, and nothing else in the structured data compensates.

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 by the input schema, which sets the baseline at 3. The description's only added semantic, repositoryId being derived from pullRequestId when omitted, is already present verbatim in that parameter's schema description, so no genuine meaning is added.

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

Purpose4/5

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

The description states a specific verb and resource ("Add a comment to a pull request"), which lets an agent distinguish it from read-side siblings like get_pull_request_comments and from update_pull_request_thread_status. It stops short of explicitly naming an alternative, so it is clear but not fully differentiated.

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

Usage Guidelines2/5

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

The only guidance is a note that repositoryId is optional and derived from pullRequestId. There is no statement of when to use this versus get_pull_request_comments, and nothing explains when to reply into an existing thread (threadId/parentCommentId) versus open a new file thread (filePath/lineNumber) versus a general PR comment.

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