Skip to main content
Glama

Edit comment

edit_comment
DestructiveIdempotent

Edits a comment's text (max 32768 characters) and optionally its attachments. Only the comment's own author can edit it - check canManage in list_issue_comments before calling.

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": {
      "commentId": "<commentId>",
      "text": "<text>"
    },
    "name": "edit_comment"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesThe comment's new text, replacing what's there now, max 32768 characters.
filesNoFiles to attach, base64-encoded - each becomes a new attachment, in addition to the comment's existing ones. Same format as create_issue.
commentIdYesThe comment's id, from list_issue_comments.
removeAttachmentIdsNoIds of the comment's attachments to remove, from list_issue_comments. Can be combined with files to replace one attachment with another.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / text / description
      Previous value: -"The comment's new text, replacing what's there now, max 4096 characters."New value: +"The comment's new text, replacing what's there now, max 32768 characters."
    • changedInput schema / properties / text / maxLength
      Previous value: -4096New value: +32768
  2. Changed2 schema fields changed
    • addedInput schema / properties / files
      Added value: +{
      +  "default": null,
      +  "description": "Files to attach, base64-encoded - each becomes a new attachment, in addition to the comment's existing ones. Same format as create_issue.",
      +  "items": {
      +    "properties": {
      +      "base64Content": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "contentType": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "fileName": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "fileName",
      +      "contentType",
      +      "base64Content"
      +    ],
      +    "type": [
      +      "object",
      +      "null"
      +    ]
      +  },
      +  "type": [
      +    "array",
      +    "null"
      +  ]
      +}
    • addedInput schema / properties / removeAttachmentIds
      Added value: +{
      +  "default": null,
      +  "description": "Ids of the comment's attachments to remove, from list_issue_comments. Can be combined with files to replace one attachment with another.",
      +  "items": {
      +    "format": "uuid",
      +    "type": "string"
      +  },
      +  "type": [
      +    "array",
      +    "null"
      +  ]
      +}
  3. Changed2 schema fields changed
    • changedInput schema / properties / text / description
      Previous value: -"The comment's new text, replacing what's there now."New value: +"The comment's new text, replacing what's there now, max 4096 characters."
    • addedInput schema / properties / text / maxLength
      Added value: +4096
  4. Changed1 schema field changed
    • changedInput schema / properties / commentId / description
      Previous value: -"The comment's id, from get_issue's comment list."New value: +"The comment's id, from list_issue_comments."
  5. Changed1 schema field changed
    • changedInput schema / properties / commentId / description
      Previous value: -"The id of the comment to edit, from get_issue's comment list."New value: +"The comment's id, from get_issue's comment list."
  6. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true and idempotentHint=true, and the description adds genuinely useful context beyond them: text replaces existing content, attached files are added in addition to existing attachments, and there is an author-only permission gate. It stops short of describing failure modes or what happens to attachments on error, so it is strong but not exhaustive.

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

Conciseness5/5

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

Two sentences, zero filler, with the core action and its constraint front-loaded ahead of the precondition. Every clause carries information the agent needs.

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 a four-parameter destructive mutation with no output schema, the description covers the essential concerns: permission requirement, replacement semantics, size limit, and attachment behavior. Only minor gaps remain, such as failure behavior or whether the returned comment reflects the edit.

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 the parameters (text, files, commentId, removeAttachmentIds) are already well documented, including the additive-attachment semantics and where ids come from. The description only restates the text limit and the optionality of attachments, adding little beyond the schema.

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 ('Edits a comment's text ... and optionally its attachments') with scope details (max 32768 characters, attachments). This is clearly distinguishable from siblings like edit_issue, create_comment, or delete_comment 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 an explicit precondition and a concrete routing instruction: only the comment's author can edit, and the caller should check canManage in list_issue_comments first. It does not spell out when to prefer related tools such as create_comment or removeAttachmentIds in delete_comment, but the context is clear enough to act on.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.