Connect to the Hosted Service
Select remote MCP (Streamable HTTP) in the client and enterhttps://glm.mcp.acedata.cloud/mcp as the server address. After selecting OAuth, follow the browser prompts to log in to Ace Data Cloud and authorize access.
If using an application API Key, select a general-purpose application or an application with GLM conversation permissions on the application management page, and check the allowed APIs and balance. Set the request header to
Authorization: Bearer <application API Key> in the client’s private credential settings. Applications and API Keys
Use an Application Key with Gemini CLI and OpenCode
First, set the environment variableACEDATACLOUD_API_TOKEN to the application API Key in the terminal where you launch the client. The following commands use macOS or Linux shell quoting and save a variable reference.
For OpenCode 1.x, add a service named
glm to the mcp object in your personal opencode.json, set type to remote, url to the address above, oauth to false, and headers.Authorization to Bearer {env:ACEDATACLOUD_API_TOKEN}. OpenCode 1.x configuration
Connect Locally via stdio
Install uv, open the local MCP configuration in Claude Desktop’s developer settings, and merge the following entry into the user configuration. Replace the placeholder with the application API Key, save, and restart the client. Other clients that support stdio can also run theuvx mcp-glm command and pass the key to the process as an environment variable.
Verify the Connection and Available Tools
Open the client’s tool list, find GLM, and first have the assistant callglm_list_models to list the GLM model identifiers accepted by the tool. This query can check whether the client has loaded the tools without submitting a business request.
Call Example
Ask the assistant to callglm_chat_completions with the following set of messages to summarize a sentence of product feedback as a to-do item.
model to use the tool’s default value, or pass an identifier from the model list. The MCP conversation tool returns the complete JSON at once, so omit stream or set it to false. For follow-up questions, pass both the question and answer from the previous turn.
Before making an actual call, you can check current pricing and availability on the service page. GLM service · Conversation API · Conversation parameters and response example
