Compare branches or commits
gitlab_compareCompare two GitLab refs to obtain the commits and file diffs between them.
Instructions
Diff between two refs (branches, tags, or SHAs). Returns commits and file diffs.
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": {
"from": "<from>",
"to": "<to>"
},
"name": "gitlab_compare"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Target ref (branch, tag, or SHA). | |
| from | Yes | Source ref (branch, tag, or SHA). | |
| straight | No | When true, direct comparison without merge-base. | |
| repo_path | No | Absolute local clone path; resolves project and MR from current branch. | |
| project_id | No | Numeric ID or group/repo path on GitLab. |