Skip to content
mergecat

The mergecat MCP server gives an AI assistant the changesets of a branch, its tags and releases, and Keep a Changelog drafts. It runs locally over stdio, reads the repository with your Git and never changes it. The Claude Code plugin installs it together with the skills; you can also add it on its own, and use it with GitHub Copilot, OpenAI Codex and GitLab Duo.

Tool names

Installed asTool names in Claude Code
Pluginmcp__plugin_mergecat_mergecat__<tool>
Standalone server named mergecatmcp__mergecat__<tool>

Compliance lock

The repository tools (repository_info, tags, changelog, changesets, where_entered) are locked until the compliance question of the session has been answered with outcome proceed. While locked, they return an error with the questions to ask and the instruction to call record_compliance_answer; they read nothing.

compliance_status, record_compliance_answer and render_pdf are not locked: they do not read the history of the repository.

One answer per session

The answer is kept in the memory of the server process. Claude Code, like the other clients, starts one process per session, so every new session asks again, and every answer is written as an audit record. The question names the AI service of the client: a Claude Team or Enterprise account in Claude Code, a GitHub Copilot Business or Enterprise license in Copilot, and so on (see the question of each assistant). See AI usage records.

Which repository

Every repository tool takes an optional repository parameter: the path of a Git repository (any folder inside it). Without it, the server uses, in this order:

  1. MERGECAT_REPOSITORY;
  2. CLAUDE_PROJECT_DIR (the Claude Code project);
  3. the folders open in the client, when it reports them to MCP servers (VS Code does): the first one that is a Git repository;
  4. the current directory of the server.

Tools

compliance_status

Whether the compliance question was answered in this session, and the exact questions to ask. No parameters. Does not read the repository.

Returns aiService (the AI service the questions are about), confirmed, askedThisSession, lastOutcome, lastRecordedAt, lastRecordFile, questions.account, questions.proceedIfNotTeamOrEnterprise and recordsFolder. Field descriptions: AI usage records.

record_compliance_answer

Records the answers the user gave in the conversation as an audit record on this computer (Markdown document and JSON Lines log) and unlocks the repository tools for the session when the outcome is proceed.

ParameterTypeRequiredDescription
team_or_enterprise_accountbooleanyestrue if the user uses the business or enterprise plan named in the first question (in Claude Code: a Claude Team or Enterprise account)
aware_and_proceedbooleanwhen the first answer is falsetrue if the user is aware of the EU AI Act and NIS2 and wants to proceed anyway
requested_actionstringyesWhat the user asked for, e.g. changelog v1.2.0..v1.3.0 or tags
answers_verbatimstringnoThe user’s answers as written, or the options chosen
languagestringnoLanguage the questions were asked in (ISO 639-1)
ai_modelstringnoThe model ID of the assistant
repositorystringnoRepository path

Returns the outcome, the record ID, the paths of the record and of the log, and the record as Markdown. When the outcome is stopped, that Markdown leaves out user, computer and repository details.

render_pdf

Converts a Markdown document (a changelog, release notes, a compliance record) into a PDF file. Does not read the repository.

ParameterTypeRequiredDescription
markdownstringyesThe Markdown document (up to 2,000,000 characters)
file_namestringnoFile name, e.g. changelog-web-v1.3.0.pdf. Default: from the title
folderstringnoAbsolute folder for the file. Default: mergecat in the system temporary folder
titlestringnoDocument title for the PDF metadata and the page footer. Default: the first # heading
allow_in_projectbooleannoAllow writing inside the project folder; only when the user asked to save the PDF there

The server refuses to write inside the project (the folder from Which repository) unless allow_in_project is set. The file name keeps letters, digits, ., _ and -. Returns file, pages and bytes. For the font limits see Changelogs.

repository_info

The default branch, the current branch, the hosting service and the version tags on the default branch with their dates (newest first, up to 30). Also says whether pull request data is available (GitHub (GITHUB_TOKEN set) or none (local Git data only)), the last fetch and whether the clone is shallow.

ParameterTypeRequiredDescription
repositorystringnoRepository path

tags

Every tag, newest first: date, commit, annotated or lightweight, message, tagger, whether it looks like a version and whether it is on the branch. For version tags on the branch: the previous version tag and the number of changesets since it. Also the number of changesets not released yet and the newest version tag.

ParameterTypeRequiredDescription
repositorystringnoRepository path
branchstringnoBranch the releases are made from. Default: the default branch
patternstringnoText contained in the name, or a glob with * and ? (e.g. v2.*); case-insensitive
versions_onlybooleannoOnly tags that look like versions (v1.2.3, 1.2)
limitintegernoMaximum tags, 1 to 500. Default 50

changelog

A Keep a Changelog draft of what entered the branch, one line per changeset, grouped by release (version tags) and by section (Added, Changed, Deprecated, Removed, Fixed, Security). Returns the Markdown draft and structured data: per changeset the section and the reason, the pull request number and link, the branch, the commits, and breaking and internal flags; for a range, how each end was resolved; notes such as swapped ends or missing pull request data.

ParameterTypeRequiredDescription
repositorystringnoRepository path
branchstringnoBranch whose history is described. Default: the default branch (e.g. origin/main)
rangestringnoOne range from..to (also [from..to]); each end a tag, a date (YYYY-MM-DD, optionally with a time) or a commit; open ends allowed (v1.3.0.., ..v1.0.0)
fromstringnoStart of a range, excluded: tag, date or commit
tostringnoEnd of a range, included: tag, date or commit. Default: the branch
max_releasesintegernoReleases to include when no range is given, 0 to 100. Default 5
unreleased_onlybooleannoOnly the changes after the newest version tag
include_internalbooleannoAlso list docs, tests, CI and chores in the Markdown. Default false (they stay in the data)
headerbooleannoStart with the # Changelog title and the Keep a Changelog preamble
languagestringnoISO 639-1 code. Default en. Headings are translated for en, it, de, fr, es; for other languages they stay in English and the data says headingsTranslated: false

Give either range or from/to, not both. The tool never translates change descriptions.

changesets

What entered a branch, newest first, grouped by integration: merged pull requests and merges with the commits they brought in, and direct commits. Also returns the warnings of the history (shallow clone, no merges, squash merges).

ParameterTypeRequiredDescription
repositorystringnoRepository path
branchstringnoBranch to describe. Default: the default branch
basestringnoOnly what entered after this tag, branch or commit
sincestringnoIntegration date from, YYYY-MM-DD
untilstringnoIntegration date to, YYYY-MM-DD
searchstringnoText in subject, SHA, branch name or pull request title (also inside groups)
authorstringnoAuthor or integrator name or e-mail
limitintegernoMaximum entries, 1 to 500. Default 50

where_entered

For a commit: the integration (pull request, merge or direct commit) that brought it into the branch, when, who integrated it, and the first tag that contains it.

ParameterTypeRequiredDescription
repositorystringnoRepository path
shastringyesCommit SHA, at least 7 hexadecimal characters
branchstringnoBranch. Default: the default branch

Pull request data

With a token of the repository’s hosting service in the environment, the tools add pull request (merge request) titles, numbers, labels and linked issues: GITHUB_TOKEN (or GH_TOKEN) for GitHub, GITLAB_TOKEN (or GL_TOKEN) for GitLab, AZURE_DEVOPS_EXT_PAT (a personal access token) or AZURE_DEVOPS_TOKEN (a Microsoft Entra token) for Azure DevOps. Without a token they use local Git data only and say which variable to set.

Use the server without the plugin

The server is also a plain MCP server: no skills, tools named mcp__mergecat__<tool>. Its instructions tell the client to ask the compliance question and to give documents to the user in the conversation, not as files in the project.

Get the server

Download the single file mergecat-mcp.cjs from the download section, or build it from a clone with npm run mcp:build (it is written to plugins/mergecat/server/mergecat-mcp.cjs). It needs Node.js 20 or newer.

Add it to Claude Code

claude mcp add --transport stdio --scope user mergecat -- node /path/to/mergecat-mcp.cjs

To pass environment variables, add -e NAME=value before --, for example -e MERGECAT_COMPLIANCE_DIR=/path/to/records.

Check it

Start Claude Code in a Git repository and run /mcp: the mergecat server should be connected. The server logs to stderr and prints mergecat MCP server 0.3.0 ready when it starts.

Other MCP clients that start stdio servers run it the same way, node /path/to/mergecat-mcp.cjs: see Other AI assistants for GitHub Copilot, OpenAI Codex and GitLab Duo. Outside Claude Code CLAUDE_PROJECT_DIR is not set: the server uses the folders open in the client when it reports them, otherwise set MERGECAT_REPOSITORY or pass repository to the tools.

Environment variables

VariableEffect
GITHUB_TOKENGitHub token for pull request data; GH_TOKEN is used when GITHUB_TOKEN is not set
GITLAB_TOKENGitLab token (read_api) for merge request data; GL_TOKEN is used when GITLAB_TOKEN is not set
AZURE_DEVOPS_EXT_PATAzure DevOps personal access token for pull request data; AZURE_DEVOPS_TOKEN takes a Microsoft Entra token instead
MERGECAT_AI_SERVICEThe AI service the compliance question is about, when the client is not recognized: claude, copilot, openai, gitlab-duo or another name
MERGECAT_GIT_PATHGit executable, when git is not on the PATH
MERGECAT_COMPLIANCE_DIRFolder of the AI usage records instead of the default folder
MERGECAT_REPOSITORYRepository used when a tool gets no repository parameter; also the project folder that render_pdf protects
CLAUDE_PROJECT_DIRSet by Claude Code: the project, used when neither the parameter nor MERGECAT_REPOSITORY is given

In Claude Code, the plugin passes the token variables above, MERGECAT_GIT_PATH and MERGECAT_COMPLIANCE_DIR from the environment you start Claude Code in.