Get PR Diff
bitbucket_get_pull_request_diffRetrieve the unified diff for a specific file in a pull request, showing additions and deletions. Specify project, repository, PR ID, and file path to get the changes.
Instructions
Get the text diff for a specific file in a pull request.
Returns the unified diff showing additions and deletions for the specified file.
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": {
"project_key": "<project_key>",
"repository_slug": "<repository_slug>",
"pull_request_id": "<pull_request_id>",
"path": "<path>"
},
"name": "bitbucket_get_pull_request_diff"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path to get the diff for | |
| diff_type | No | EFFECTIVE (merge result) or RANGE (commit range) | |
| whitespace | No | Whitespace handling: SHOW, IGNORE_ALL, or IGNORE_TRAILING | |
| project_key | Yes | The project key | |
| context_lines | No | Number of context lines around changes (default: 10) | |
| pull_request_id | Yes | The pull request ID number | |
| repository_slug | Yes | The repository slug | |
| response_format | No | Output format: markdown (default) or json | markdown |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |