post_pr_comments
Batch-post comments to a pull request with optional file and line anchoring, enabling targeted feedback on specific code changes.
Instructions
Batch-post comments to a PR with optional file/line positioning.
Each comment dict has keys: content: str (required) file_path: str | None (optional — anchors to file) line_number: int | None (optional — anchors to line, requires file_path) status: str (optional — default "active")
Iteration context is auto-resolved. Comments are positioned on the latest iteration.
dry_run=True validates and returns what would be posted.
Args: pr_url_or_id: A full PR URL or numeric PR ID. comments: List of comment dicts to post. dry_run: If True, validate without posting. working_directory: Optional path for context resolution.
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": {
"pr_url_or_id": "<pr_url_or_id>",
"comments": "<comments>",
"dry_run": "<dry_run>",
"working_directory": "<working_directory>"
},
"name": "post_pr_comments"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pr_url_or_id | Yes | ||
| comments | Yes | ||
| dry_run | Yes | ||
| working_directory | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |