Skip to main content
Glama

phabricator_revision_inline_comment

Create draft inline comments or threaded replies on Phabricator Differential diffs, with optional highlighted ranges and suggested edits; publish drafts separately.

Instructions

Create a draft inline comment on a Differential diff, optionally highlighting a character range and attaching a suggested edit, or a draft reply to a published inline comment (replyToInlineID). Drafts are visible only to you until you call phabricator_revision_inline_publish; a plain comment via phabricator_revision_edit does NOT publish them. Ranges, suggestions and replies need the differential.inline.* Conduit extension; without it, plain line comments fall back to differential.createinline.

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": {
      "revisionID": "<revisionID>",
      "content": "<content>"
    },
    "name": "phabricator_revision_inline_comment"
  }
}

Input Schema

NameRequiredDescriptionDefault
diffIDNoDiff ID to comment on. Defaults to the revision's active diff.
contentYesComment text (supports Remarkup)
filePathNoPath to the file being commented on. Required unless replying.
endOffsetNoExclusive column on the last line where the highlighted range ends. Requires startOffset.
isNewFileNoWhether the line number refers to the new file (true) or old file (false). Default: true
lineLengthNoHow many more lines the comment spans after lineNumber (default: 0, a single line)
lineNumberNoFirst line of the comment. Required unless replying.
revisionIDYesRevision ID (e.g., 123 or "D123")
startOffsetNo0-based column on the first line where the highlighted range starts, counted as the web UI shows it (each tab is up to 2 columns). Requires endOffset.
suggestionTextNoSuggested replacement for the commented lines on the new side. "" suggests deleting them. Needs a diff uploaded with full context, as arc diff does.
replyToInlineIDNoReply to this published inline comment (its "id" from phabricator_revision_inline_search), as "Reply" does in the web UI. The reply goes on the same diff, side and lines as that comment and is threaded under it, so leave out diffID, filePath, lineNumber, lineLength and isNewFile (any given must match the comment). A reply cannot have startOffset, endOffset or suggestionText. You cannot reply to a draft, including your own: edit it instead.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv2.4.0
    • changedInput schema / properties / filePath / description
      Previous value: -"Path to the file being commented on"New value: +"Path to the file being commented on. Required unless replying."
    • changedInput schema / properties / lineNumber / description
      Previous value: -"First line of the comment"New value: +"First line of the comment. Required unless replying."
    • addedInput schema / properties / replyToInlineID
      Added value: +{
      +  "description": "Reply to this published inline comment (its \"id\" from phabricator_revision_inline_search), as \"Reply\" does in the web UI. The reply goes on the same diff, side and lines as that comment and is threaded under it, so leave out diffID, filePath, lineNumber, lineLength and isNewFile (any given must match the comment). A reply cannot have startOffset, endOffset or suggestionText. You cannot reply to a draft, including your own: edit it instead.",
      +  "type": "number"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "revisionID",
      -  "filePath",
      -  "lineNumber",
      -  "content"
      -]New value: +[
      +  "revisionID",
      +  "content"
      +]
  2. Changed8 schema fields changedv2.1.0
    • changedInput schema / properties / diffID / description
      Previous value: -"Diff ID to comment on. Use phabricator_diff_search to find this."New value: +"Diff ID to comment on. Defaults to the revision's active diff."
    • addedInput schema / properties / endOffset
      Added value: +{
      +  "description": "Exclusive column on the last line where the highlighted range ends. Requires startOffset.",
      +  "type": "number"
      +}
    • changedInput schema / properties / lineLength / description
      Previous value: -"Number of lines the comment spans (default: 0 for single line)"New value: +"How many more lines the comment spans after lineNumber (default: 0, a single line)"
    • changedInput schema / properties / lineNumber / description
      Previous value: -"Line number in the file"New value: +"First line of the comment"
    • changedInput schema / properties / revisionID / description
      Previous value: -"Numeric revision ID (e.g., 123). Do not include the \"D\" prefix."New value: +"Revision ID (e.g., 123 or \"D123\")"
    • addedInput schema / properties / startOffset
      Added value: +{
      +  "description": "0-based column on the first line where the highlighted range starts, counted as the web UI shows it (each tab is up to 2 columns). Requires endOffset.",
      +  "type": "number"
      +}
    • addedInput schema / properties / suggestionText
      Added value: +{
      +  "description": "Suggested replacement for the commented lines on the new side. \"\" suggests deleting them. Needs a diff uploaded with full context, as arc diff does.",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "revisionID",
      -  "diffID",
      -  "filePath",
      -  "lineNumber",
      -  "content"
      -]New value: +[
      +  "revisionID",
      +  "filePath",
      +  "lineNumber",
      +  "content"
      +]
  3. First observedv2.0.19

TDQS

A4.6/5.0
Behavior4/5

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

Annotations establish a non-read-only, non-destructive action, but the description adds important behavior: drafts are private until published, the publish tool is required, reply threading constraints apply, and the differential.inline.* extension controls feature availability. This is substantial context beyond the annotations, though it does not cover permissions or error behavior.

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?

The description is dense but front-loaded and every sentence carries operational information. The first sentence is long due to enumerating optional modes and could be split, but there is no filler.

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

Completeness5/5

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

Given 11 parameters, no output schema, and a draft workflow involving publish semantics and extension fallback, the description covers what an agent needs to invoke the tool correctly. Return values are not needed because no output schema exists.

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

Parameters4/5

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

Schema coverage is 100%, so the schema already carries parameter descriptions. The description still adds meaning for replyToInlineID, including that it targets a published comment, threads under it, and disallows certain fields, and it explains the extension dependency for ranges, suggestions and replies.

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?

The description states a specific verb and resource: creating a draft inline comment on a Differential diff, with optional range/suggestion or reply behavior. It distinguishes this from publishing and from ordinary revision comments, so an agent can identify the tool without opening the schema.

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

Usage Guidelines5/5

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

It explicitly says drafts require phabricator_revision_inline_publish to become visible and that a plain comment via phabricator_revision_edit does NOT publish them. It also explains replyToInlineID as the alternative path for replying and notes the Conduit extension dependency plus fallback.

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

Deploy Server

Other Tools