create_merge_request
Open a merge request from an existing source branch to a target branch, creating remote review state. Specify title, branches, and project to start the review process.
Instructions
Create a new merge request. Use this to open a new merge request from an existing source branch to a target branch; use update_merge_request after it exists. The operation creates remote review state, requires project access, and returns the new merge request or a validation, permission, branch, or duplicate-related error.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| draft | No | Create as draft merge request | |
| title | Yes | Merge request title | |
| labels | No | Labels for the MR | |
| squash | No | If true, squash all commits into a single commit on merge. | |
| project_id | Yes | Project ID or complete URL-encoded path to project | |
| description | No | Merge request description | |
| assignee_ids | No | The ID of the users to assign the MR to | |
| reviewer_ids | No | The ID of the users to assign as reviewers of the MR | |
| source_branch | Yes | Branch containing changes | |
| target_branch | Yes | Branch to merge into | |
| target_project_id | No | Numeric ID of the target project. | |
| allow_collaboration | No | Allow commits from upstream members | |
| remove_source_branch | No | Flag indicating if a merge request should remove the source branch when merging. |