Delegates repository coding tasks to Z.ai GLM through four MCP tools, with routing, dry runs, progress, and usage tracking.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent โ or use 1-click editor setup below.
We haven't yet run this listing's install command through our automated sandbox check. This isn't a red flag โ we're steadily working through the catalog.
๐ก Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Inspect callable tools, capabilities, and parameters exposed to AI agents by Glm MCP.
djerok/glm-mcp MCP server exposes Z.ai GLM to an MCP-compatible coding workflow. Its central glm_agent tool accepts a task and an absolute repository working directory, then lets GLM operate through an agent loop rather than making one isolated completion request. The loop can inspect files, modify them, enumerate directories, and execute Bash commands in the target repository.
The server is designed for a main agent such as Claude Code, GitHub Copilot, or Codex to delegate work and review the result. After the delegated run, the main agent receives a concise summary and a GLM STATS block containing the selected model, token counts, and estimated cost. Every GLM call is also appended to a usage.jsonl ledger.
When glm_agent is called, a peak-aware router selects a GLM model and sends the request to Z.ai's Anthropic-compatible /v1/messages endpoint. GLM handles the tool loop against the supplied repository, and the MCP server relays the result to the orchestrating client. A cost bias keeps GLM as the default engine in the routing behavior described by the project.
The tool supports dry_run: true, which previews a diff without writing changes. A completed real run prints a Git checkpoint revert line, giving the primary agent a way to review or undo changes. Progress notifications report the current iteration, token count, and token rate. Cancellation stops the run promptly, although partial changes may remain and need review or reversion.
For a general MCP client, install the published glm-mcp package with npx -y glm-mcp. Configure it as a stdio server and provide GLM_API_KEY with a Z.ai key. The server can start and answer MCP introspection requests without a key, but actual GLM calls require one.
The repository also provides separate installers for Claude Code, GitHub Copilot in VS Code, and Codex. Those installers add client-specific subagents, hooks, skills, or configuration in addition to registering the same underlying MCP server. The documented installer packages are glm-mcp-claude, glm-mcp-copilot, and glm-mcp-codex.
GLM_DELEGATE=on exposes the optional text-only delegation tool. max_tokens defaults to auto, or the orchestrating agent can provide a numeric limit. The default stall timeout is controlled by GLM_STALL_TIMEOUT_MS; client tool-call limits can also involve MCP_TOOL_TIMEOUT or CLAUDE_CODE_MCP_TOOL_IDLE_TIMEOUT.
The djerok/glm-mcp MCP server provides four tools:
glm_agent: delegates repository work to GLM, including read, write, edit, directory listing, and Bash execution.glm_delegate: performs text-in/text-out generation and is hidden unless GLM_DELEGATE=on is set.glm_recommend: gives a free local recommendation about GLM versus the main model, including model choice, confidence, and reasons.glm_status: reports the peak window, active model, usage-ledger totals, and configuration health without making a GLM request.The delegated agent can mutate files and run commands in the supplied repository, so the main agent should inspect its output and diffs. A dry run avoids writes, but normal execution can leave partial changes if cancelled. The server reports estimated cost and ledger totals, but the README does not establish those estimates as billing statements. GLM usage requires the user's Z.ai GLM Coding Plan key, and a hybrid main-agent workflow still consumes tokens for orchestration and review.
Factual signals from GitHub, npm, and our automated checks โ not a rating.
No reviews yet โ be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/djerok-glm-mcp)<a href="https://allmcps.com/mcp/djerok-glm-mcp"><img src="https://allmcps.com/api/badge/djerok-glm-mcp?style=directory" alt="Glm MCP on AllMCPs" /></a>