Skip to content

Installation

gitlab-api is a standard Python package and a prebuilt container image. Pick the path that matches how the operator want to run it.

Requirements

  • Python 3.11 – 3.14.
  • A reachable GitLab instance (GitLab.com or self-managed) and a personal / project access token — see Backing Platform to deploy one locally.
pip install gitlab-api

Optional extras

The base install is intentionally minimal. Install the extra for what the operator need:

Extra Install Pulls in
mcp pip install "gitlab-api[mcp]" FastMCP MCP-server runtime (scion-sdk)
gql pip install "gitlab-api[gql]" gql client for the GitLab GraphQL API
all pip install "gitlab-api[all]" Everything above
# Typical: run the MCP server with GraphQL support
pip install "gitlab-api[mcp,gql]"

From source

git clone https://github.com/Knuckles-Team/gitlab-api.git
cd gitlab-api
pip install -e ".[all]"          # editable install with every extra

With uv:

uv pip install -e ".[all]"
uv run gitlab-mcp

Prebuilt Docker image

A multi-stage runtime image is published on every release (entrypoint gitlab-mcp):

docker pull example/gitlab-api@sha256:<digest>

docker run --rm -i \
  -e GITLAB_URL=https://gitlab.example.com \
  -e GITLAB_TOKEN=<your-gitlab-token> \
  example/gitlab-api@sha256:<digest>        # stdio transport (default)

Deployment.

Verify the install

Next steps

  • Usage — call the tools, the API, and the CLI.
  • Configuration — every environment variable.