gitlab_trigger_pipeline
Creates a new GitLab CI/CD pipeline on a specified branch or tag, with optional CI variables. Use it to start a fresh run; for retries, reuse the existing pipeline ID instead.
Instructions
Create a new pipeline on the given ref, optionally with CI variables.
Not idempotent: each call creates a new pipeline. Consumes minutes on your runners — avoid calling in loops.
Examples:
- "Run the pipeline on master" → default (ref='master')
- "Run the pipeline on feature/x with DEBUG=1" → ref='feature/x', variables={'DEBUG': '1'}
- Don't call to retry — use gitlab_retry_pipeline which keeps the same pipeline ID.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project_path": "<project_path>"
},
"name": "gitlab_trigger_pipeline"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | Branch or tag to run the pipeline on. | master |
| variables | No | Optional CI variables to pass to the pipeline (``{key: value}``). | |
| project_path | Yes | GitLab project path (e.g. 'my-org/my-repo'). Required by default. For legacy deployments only, set GITLAB_ALLOW_DEFAULT_PROJECT=true to use GITLAB_PROJECT_PATH when omitted. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | ||
| status | No | ||
| web_url | No | ||
| created_at | No | ||
| pipeline_id | No | ||
| status_note | No |