Skip to main content
Glama

Get project level rule

gitlab_get_project_level_rule
Read-onlyIdempotent

Retrieves project-level merge request approval settings from GitLab to inspect approval, reauthentication, and override options for a specific project.

Instructions

Get details of a project-level merge request approval setting.

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

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

Raises: MissingParameterError: If the project_id 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_get_project_level_rule"
  }
}

Input Schema

NameRequiredDescriptionDefault
dataNo
group_idNo
project_idNo
allow_author_approvalNo
allow_committer_approvalNo
retain_approvals_on_pushNo
selective_code_owner_removalsNo
require_reauthentication_to_approveNo
allow_overrides_to_approver_list_per_merge_requestNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv27.3.20
    • removedInput schema / properties / api_parameters
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "additionalProperties": true,
      -      "type": "object"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
  2. First observedv27.3.13

TDQS

C2.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the safety profile is covered. The description adds genuinely useful context beyond that: it names the return wrapper and MergeRequestRuleSettings model, and discloses that MissingParameterError is raised when project_id is absent — a fact the schema contradicts by marking nothing required. It stops short of describing scoping or permission requirements.

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

Conciseness3/5

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

The first sentence is a clean, front-loaded purpose statement, but the docstring scaffolding (Args/Returns/Raises) is padded: 'Args: **kwargs' is misleading since the tool takes named parameters, not arbitrary kwargs. The Raises block is the most informative part and is buried last.

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?

For a 9-parameter tool with zero schema documentation, no output schema, and five similarly named siblings covering create/update/delete/get of the same resource, this description is not sufficient. It omits the meaning of most parameters and gives no disambiguation, so an agent could easily invoke the wrong sibling or pass the wrong fields.

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% across 9 parameters, so the description carries the full burden and mostly fails it. It only explains project_id (as required) and waves the rest away as '**kwargs', leaving the seven boolean flags (allow_author_approval, retain_approvals_on_push, etc.) and group_id/data completely undefined in both schema and description.

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

Purpose3/5

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

The description states a concrete verb and resource: 'Get details of a project-level merge request approval setting.' However, the sibling list contains gitlab_get_project_level_merge_request_rule and gitlab_get_project_level_merge_request_rules, which are near-identical in wording, and the description offers no basis for telling them apart. The purpose is understandable in isolation but ambiguous in the actual toolset.

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?

There is no when-to-use guidance, no prerequisites, and no mention of the sibling getters, creators, updaters, or deleters of the same rule. An agent must guess whether this is the singular vs. plural variant or the 'rule' vs. 'merge_request_rule' variant. The only implicit usage signal is the MissingParameterError note about project_id.

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