Skip to main content
Glama
djerok

GLM Subagent MCP

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
GLM_CAPNoOutput-token cap. Off by default = generous (up to 131072 per call). Set on to enforce GLM_MAX_TOKENS. Default: offoff
GLM_API_KEYYesYour Z.ai API key with GLM Coding Plan access. Required.
GLM_BASE_URLNoAnthropic-compatible endpoint. Default: https://api.z.ai/api/anthropichttps://api.z.ai/api/anthropic
GLM_COST_BIASNoHow hard to favor GLM (it's ~10x cheaper). Higher = more GLM; 0 = decide on capability only. Default: 1.51.5
GLM_MAX_TOKENSNoThe hard per-call limit applied only when GLM_CAP=on. Default: 3276832768
GLM_PEAK_MODELNoModel used during China peak. Default: glm-5.2glm-5.2
GLM_PEAK_END_CNNoPeak window end (China hour, UTC+8). Default: 1818
GLM_OFFPEAK_MODELNoModel used off-peak. Default: glm-5.2glm-5.2
GLM_PEAK_START_CNNoPeak window start (China hour, UTC+8). Default: 1414
GLM_MAX_CONCURRENTNoGLM caps in-flight requests; keep at 1. Default: 11
GLM_AGENT_MAX_ITERSNoMax tool-loop turns for glm_agent. Default: 3030
GLM_MAX_TOKENS_CEILINGNoThe generous default used when the cap is off. Default: 131072131072

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
glm_delegateA

Text-in/text-out subtask on GLM (~10x cheaper than Opus); returns text only. GLM has no file/tool access -- put everything in task+context. For file edits use glm_agent instead. Not for sensitive, long-debugging, large-refactor, or parallel work.

glm_agentA

Run GLM as a real coding agent with its OWN file tools (read/write/edit/list/bash); it works your repo end-to-end on GLM tokens (~10x cheaper than Opus). Prefer this over doing repo work yourself. Pass task + absolute workdir. Returns a concise summary+stats (use dry_run to preview a diff first). Not for sensitive, huge-context, or heavy dependent-tool-loop work.

glm_recommendA

Free local advisory (no GLM call): given a task profile, returns GLM-vs-Opus, model, confidence, and reasons. Call when unsure which engine to use.

glm_statusA

Free local status: peak window, active model, GLM usage ledger (proof of GLM tokens spent), and config health. No GLM call.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/djerok/glm-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server