GitLab ships a native MCP server at /api/v4/mcp on GitLab.com, Self-Managed and Dedicated instances (beta, GitLab 18.6+). It authenticates each user via OAuth 2.0 Dynamic Client Registration and exposes toolsets for merge requests, work items, repositories, CI and optional Duo Agent Platform, wiki and code security tools.
Connect
- 1Connect it in ChatGPT
Turn on Developer mode in ChatGPT (Settings → Security and login), open Plugins, select + and paste https://gitlab.com/api/v4/mcp as the MCP server URL, then sign in with OAuth. Add it to a chat from the composer's tools menu.
- 2Or add it to Codex or the API
codex mcp add gitlab --url https://gitlab.com/api/v4/mcp codex mcp login gitlabThe login command opens a browser to finish OAuth.
Configs are generated from the publisher's documented endpoint. Check their docs for plan requirements and scopes. New to this? Read the step-by-step tutorial.
Tools 12
get_mcp_server_versionget_projectadd_commitget_merge_requestsave_merge_requestsave_notelist_work_itemssave_work_itemsearchsemantic_searchstart_duo_sessionget_duo_sessionThings to ask
- “Summarize merge request !42 in my project”
- “Create a work item for the login timeout bug”
- “Search the codebase for where we validate API tokens”
- “Add a review note to the open merge request”