Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add instructions/ttpears/gitlab-mcp/claude-mdgit clone --depth 1 https://github.com/ttpears/gitlab-mcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/ttpears/gitlab-mcp/claude-md)<a href="https://agentmods.dev/instructions/ttpears/gitlab-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/ttpears/gitlab-mcp/claude-md.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.01694 | $0.01694 |
| Opus 5 | $0.00847 | $0.00847 |
| Sonnet 5 | $0.00339 | $0.00339 |
| Haiku 4.5 | $0.00169 | $0.00169 |
Grade A, and why
gitlab-mcp CLAUDE.md scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
- Local smoke test over HTTP: `MCP_TRANSPORT=http GITLAB_MCP_PORT=8008 GITLAB_TOKEN=glpat-... npm run dev`, then point an MCP client at `http://localhost:8008/` (health check: `curl http://localhost:8008/health`). How it starts
The opening of the file, as written. The whole thing — 53 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Commands
npm run build— TypeScript compile todist/(tsc, ESM).npm run dev— Run the server directly fromsrc/viatsx(stdio transport by default).npm start— Run the compiled server fromdist/index.js.npm test— Jest. Run a single test withnpx jest <path>ornpx jest -t "<name>".- Local smoke test over HTTP:
MCP_TRANSPORT=http GITLAB_MCP_PORT=8008 GITLAB_TOKEN=glpat-... npm run dev, then point an MCP client athttp://localhost:8008/(health check:curl http://localhost:8008/health). - Interactive tool testing:
npx @modelcontextprotocol/inspector npx @ttpears/gitlab-mcp-server. - Debug logging: set
NODE_ENV=development— startup prints the resolved config to stderr; production suppresses it.
Architecture
Four source files, ~4.7k lines total — keep the layering in mind before adding code:
src/config.ts—loadConfig()reads env (GITLAB_URL,GITLAB_TOKEN,GITLAB_READ_TOKEN,GITLAB_MAX_PAGE_SIZE,GITLAB_TIMEOUT) into a zod-validatedConfig.validateUserConfig()parses per-requestuserCredentials.GITLAB_TOKENandGITLAB_READ_TOKENare mutually exclusive; setting both is a startup error. OldGITLAB_AUTH_MODEandGITLAB_SHARED_ACCESS_TOKENenv vars trigger a deprecation warning and are ignored.src/gitlab-client.ts—GitLabGraphQLClientwrapsgraphql-requestand is the only place that talks to GitLab. Every method accepts optionaluserCredentials;getClient()picks a token per the four-step rule (see Project Conventions below). Also hostsfetchAllPages()— the cursor-loop helper everyfetchAlltool uses — and schema-introspection helpers.src/tools.ts— Declarative tool registry: each entry is{ name, description, inputSchema: zod, handler(args, client) }. Handlers are thin — they validate input, call the client, and shape the response. This is where pagination defaults and sort enums live for each tool.src/index.ts—GitLabMCPServerowns both transports. Stdio mode uses a singleServerinstance. HTTP mode (MCP_TRANSPORT=http) runs Express and maintains ahttpSessionsmap keyed by session id, each with its ownServer+StreamableHTTPServerTransport+ per-sessionuserConfig. The HTTP entry point accepts both/and/mcp(the latter exists for container setups). LibreChat sends credentials viaAuthorization: Bearer <PAT>and optionalX-GitLab-Urlheaders — these are lifted into the session'suserConfig. Idle sessions are reaped bysessionCleanupInterval.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 53 lines · 1,694 tokens per session scan A 466ccfbf712a
gitlab-mcp CLAUDE.md is an instructions file published in the GitHub repository ttpears/gitlab-mcp (10 stars, last pushed 1mo ago), licensed MIT. It adds 1,694 tokens to every session, about $0.0085 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
openrouter-mcp-multimodal AGENTS.md
AGENTS.md instructions for stabgan/openrouter-mcp-multimodal, covering agent instructions, before you ship, releasing (read this before publishing), short version and version files (must all match package.json).
gitlab-mcp-server mcp-best-practices.instructions.md
MCP protocol-level best practices for tool design, annotations, response formats, pagination, and security. Applies to all Go MCP server code.
gitlab-mcp-server security-and-owasp.instructions.md
Comprehensive secure coding instructions for all languages and frameworks, based on OWASP Top 10 and industry best practices.
seekstone CLAUDE.md
Instructions for shaqmughal/seekstone, covering claude.md, what this repo is, commands, the harness itself (run after npm install) and architecture.
mistral-mcp CLAUDE.md
Instructions for Swih/mistral-mcp, covering claude.md — mistral-mcp, 1. identité du projet, 2. règles dures (ne pas transgresser), 3. layout & responsabilités and 4. conventions de code.
pfsense-mcp-server AGENTS.md
Instructions for night4me/pfsense-mcp-server, covering pfsense mcp server, architecture and security, development workflow, long-running validation and test parallelism.