Skip to main content
Glama

unshare_project_with_group

Remove a group's access to a GitLab project by specifying project and group IDs.

Instructions

Remove project sharing with a group.

Args:
    project_id: GitLab project ID
    group_id: Group ID to unshare from
    token: GitLab Personal Access Token (optional)
    ctx: MCP context (automatically injected)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYes
group_idYes
tokenNo
ctxNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The handler function for the 'unshare_project_with_group' tool. It removes sharing of a project with a group by sending a DELETE request to the GitLab API endpoint /projects/{project_id}/share/{group_id}.
    @mcp.tool()
    async def unshare_project_with_group(project_id: int, group_id: int, token: str = None, ctx=None) -> str:
        """Remove project sharing with a group.
        
        Args:
            project_id: GitLab project ID
            group_id: Group ID to unshare from
            token: GitLab Personal Access Token (optional)
            ctx: MCP context (automatically injected)
        """
        result = await make_gitlab_request(f"/projects/{project_id}/share/{group_id}", "DELETE", ctx=ctx, token=token)
        
        if isinstance(result, dict) and "error" in result:
            return f"Error unsharing project: {result['error']}"
        
        return f"Project unshared from group {group_id}"
  • The tool is registered via the @mcp.tool() decorator on line 1315, which is part of the FastMCP framework.
    @mcp.tool()
    async def unshare_project_with_group(project_id: int, group_id: int, token: str = None, ctx=None) -> str:
Behavior2/5

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

With no annotations provided, the description must fully disclose behavioral traits. It merely restates the operation ('remove') without detailing consequences, authorization needs, rate limits, or irreversibility. The token and ctx parameters are listed but not explained.

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 description is brief, but the structure is suboptimal for MCP: a single sentence followed by a parameter list that mirrors the schema. It is concise but not front-loaded with the most critical information for an AI agent.

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?

Given the tool has 4 parameters, no annotations, and an output schema (though not described), the description is incomplete. It lacks details on return values, error handling, or idempotency, leaving the agent with insufficient context to use the tool reliably.

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%, so the description must compensate. However, it only lists parameter names without adding meaning, constraints, or examples. The schema already provides names and types, so the description adds minimal value beyond redundancy.

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

Purpose5/5

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

The description clearly states the action ('Remove project sharing with a group') and the target resource. It directly distinguishes from sibling tools like 'share_project_with_group', making the purpose unambiguous.

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?

No guidance is given on when to use this tool versus alternatives such as 'share_project_with_group'. There's no mention of prerequisites, side effects, or typical contexts where removing group sharing is appropriate.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/skmprb/gitlab-clone-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server