Skip to main content
Glama

Create merge request

gitlab_create_merge_request

Create a new GitLab merge request by specifying the project, source and target branches, and title; add reviewers, labels, and descriptions to start code review.

Instructions

Create a new merge request.

Args: **kwargs: Additional parameters for the request (e.g., project_id, source_branch, target_branch, title).

Returns: Response: A wrapper containing the original response and a MergeRequest model.

Raises: MissingParameterError: If the project_id, source_branch, target_branch, or title is missing. ParameterError: If invalid parameters are provided.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "gitlab_create_merge_request"
  }
}

Input Schema

NameRequiredDescriptionDefault
wipNo
dataNo
pageNo
sortNo
viewNo
scopeNo
stateNo
titleNo
labelsNo
searchNo
squashNo
order_byNo
per_pageNo
author_idNo
max_pagesNo
milestoneNo
search_inNo
project_idNo
assignee_idNo
descriptionNo
environmentNo
reviewer_idNo
approver_idsNo
assignee_idsNo
milestone_idNo
reviewer_idsNo
created_afterNo
source_branchNo
target_branchNo
updated_afterNo
created_beforeNo
deployed_afterNo
search_excludeNo
updated_beforeNo
approved_by_idsNo
author_usernameNo
deployed_beforeNo
my_reaction_emojiNo
reviewer_usernameNo
target_project_idNo
allow_collaborationNo
with_labels_detailsNo
remove_source_branchNo
approvals_before_mergeNo
allow_maintainer_to_pushNo
with_merge_status_recheckNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv27.3.20
    • removedInput schema / properties / api_parameters
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "additionalProperties": true,
      -      "type": "object"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • changedInput schema / properties / max_pages / default
      Previous value: -0New value: +null
    • changedInput schema / properties / page / default
      Previous value: -1New value: +null
    • changedInput schema / properties / per_page / default
      Previous value: -100New value: +null
  2. Changed2 schema fields changedv27.3.18
    • addedInput schema / properties / title / default
      Added value: +null
    • removedInput schema / required
      Removed value: -[
      -  "title"
      -]
  3. First observedv27.3.13

TDQS

C2.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already state readOnlyHint=false, openWorldHint=true, idempotentHint=false, and destructiveHint=false, so the safety profile is largely covered. The description adds useful error behavior and return shape, including a MergeRequest wrapper, but it does not disclose permissions, duplicate-request behavior, or the odd mismatch between the described required fields and a schema that marks all 46 parameters as optional.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is short and uses a clear Args/Returns/Raises structure with the main purpose front-loaded. The generic **kwargs framing is slightly misleading because the schema exposes many explicit parameters, but the text itself is not bloated.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

This is a complex mutation with 46 parameters, 0% schema description coverage, and no output schema. The description covers only the four core parameters, return wrapper, and two error types, which is insufficient for an agent to understand most of the available options or authentication and duplicate-handling behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description only names four example parameters: project_id, source_branch, target_branch, and title. It clarifies that those four are effectively required, but it leaves the meaning and applicability of the other 42 parameters undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The first sentence gives a specific verb and resource: 'Create a new merge request.' It clearly identifies this as the creation operation among merge-request siblings, though it does not explicitly name alternatives such as update or approve.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies that this tool is used when creating a new merge request, but it gives no explicit when-to-use versus when-not-to-use guidance, no prerequisites beyond the MissingParameterError note, and no comparison with update_merge_request or other siblings.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools