Skip to main content
Glama

gitlab_delete_cicd_variable

Remove a specific CI/CD variable from a project in GitLab by specifying the variable key and project ID using the GitLab MCP Server.

Instructions

Delete a CI/CD variable

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYesThe key of the variable
project_idYesThe ID or URL-encoded path of the project

Implementation Reference

  • The handler function implementing the gitlab_delete_cicd_variable tool. It extracts project_id and key from arguments, validates them, calls context.ciCdManager.deleteCiCdVariable, and formats the response.
    export const deleteCiCdVariable: ToolHandler = async (params, context) => {
      const { project_id, key } = params.arguments || {};
      if (!project_id || !key) {
        throw new McpError(ErrorCode.InvalidParams, 'project_id and key are required');
      }
      
      const data = await context.ciCdManager.deleteCiCdVariable(project_id as string | number, key as string);
      return formatResponse(data);
    }; 
  • The input schema and metadata definition for the gitlab_delete_cicd_variable tool.
    {
      name: 'gitlab_delete_cicd_variable',
      description: 'Delete a CI/CD variable',
      inputSchema: {
        type: 'object',
        properties: {
          project_id: {
            type: 'string',
            description: 'The ID or URL-encoded path of the project'
          },
          key: {
            type: 'string',
            description: 'The key of the variable'
          }
        },
        required: ['project_id', 'key']
      }
    },
  • Registration of the gitlab_delete_cicd_variable tool name mapping to its handler function in the central toolRegistry.
    gitlab_delete_cicd_variable: cicdHandlers.deleteCiCdVariable,

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/rifqi96/mcp-gitlab'

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