Get pull request diff
bb_get_pull_request_diffFetches a pull request diff, optionally limited to one file, with compact previews, added/removed line counts, and omission stats to keep review context within limits.
Instructions
Fetch the diff of a pull request (optionally for one file). Each file is compacted with smart truncation: head 60% + tail 40% of the preview budget, plus added/removed line counts and omission statistics.
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>"
},
"name": "bb_get_pull_request_diff"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Limit the diff to this file path. | |
| projectKey | Yes | Project key (on Cloud: workspace slug). | |
| pullRequestId | Yes | Pull request id, e.g. 101. | |
| repositorySlug | Yes | Repository slug, e.g. 'service-api'. | |
| maxCharsPerFile | No | Preview budget per file (head 60% / tail 40% on truncation). |