GLM API
GLM Series Large Models
Use GLM series models through an OpenAI-compatible format. GLM-5.3 is suited for complex reasoning, GLM-3-Turbo for general text tasks, and GLM-4.5V supports text and image input.
Why use GLM through Ace Data Cloud?
GLM is a full series of large language models from Zhipu AI. GLM-5.3 supports deep reasoning (Thinking), GLM-4.5v supports multimodal visual understanding, and GLM-3-Turbo is suited for everyday text conversations.
Ace Data Cloud uses an OpenAI-compatible format. When compatible routing is enabled, the platform may process requests using a compatible model in the same tier. Both responses and billing use the public GLM model specified in the request.
Core Capabilities of the GLM API
Unlock the full potential of Zhipu AI GLM through an OpenAI-compatible interface
OpenAI-Compatible Format
Call GLM through /glm/chat/completions, fully compatible with the OpenAI SDK. Switch seamlessly with zero code changes.
Deep Reasoning (Thinking)
GLM-5.3 has built-in deep reasoning capabilities, using structured thinking before answering to significantly improve performance on math, programming, and logic tasks.
Chinese-English Bilingual Optimization
Excellent native Chinese comprehension, with outstanding English performance. Suitable for Chinese-language use cases, cross-language translation, and multilingual application development.
Multimodal Vision
GLM-4.5v supports image understanding and can handle visual tasks such as image description, OCR, and chart analysis, combining them with language understanding to enable multimodal interaction.
Lightweight Text Chat
GLM-3-Turbo can be used for short question answering, classification, and field extraction.
Streaming
Supports SSE streaming, outputting tokens in real time. Set stream: true to receive a streaming response.
from openai import OpenAI
client = OpenAI(
base_url="https://api.acedata.cloud/glm",
api_key="YOUR_API_KEY",
)
response = client.chat.completions.create(
model="glm-5.3",
messages=[{"role": "user", "content": "用一句话解释快速排序"}],
max_tokens=1024,
)
print(response.choices[0].message.content)JSON Response
The following response excerpt from the existing API guide shows the fields used to read the result. The example model, task ID, and media content come from that historical example; use the actual values returned by your request.
{
"id": "msg_202604262252030313862701a04e33",
"object": "chat.completion",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! 👋 How can I assist you today?"
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 10,
"completion_tokens": 23,
"total_tokens": 33
}
}
The answer in a standard response is located at choices[0].message.content. See the API documentation for reasoning, image and text input, and streaming examples.
Switch with one line of OpenAI SDK code
Simply change base_url and model to use GLM in your existing OpenAI project—no code refactoring required.
Get an API Key
Sign in to the application list, open General Application, and click the copy button to the right of API KEY. Keep the key on the server and use it to replace YOUR_API_KEY in the example.
Change base_url
Set base_url to https://api.acedata.cloud/glm
Choose a GLM model
Set model to a GLM model name, such as glm-5.3 or glm-4.7
What can you build with the GLM API?
From Chinese NLP to multimodal vision, developers are building these applications with GLM
Chinese conversational assistants
Build high-quality Chinese customer service, knowledge Q&A, and personal AI assistants with native Chinese understanding far beyond general-purpose models
Code generation and review
The GLM-5 series excels in programming benchmarks, supporting code generation, bug fixes, code reviews, and architectural recommendations
Multimodal visual understanding
GLM-4.5v supports image understanding, enabling visual AI applications such as OCR, chart analysis, and image descriptions
Deep reasoning and analysis
Math problem solving, logical reasoning, data analysis—GLM-5.3 Thinking mode provides deep reasoning capabilities
Get started in 3 steps
From registration to sending your first GLM message, it takes less than 3 minutes
Sign up and get an API Key
Follow the illustration above to copy the API Key for the general application.
Make calls using the OpenAI SDK
Set base_url to Ace Data Cloud and choose any GLM model to get started.
Integrate and scale
Embed GLM in your application. The OpenAI-compatible format makes switching between models effortless.
Why Choose Ace Data Cloud Over Using the Zhipu API Directly?
Comprehensive advantages in format compatibility, global availability, and a unified interface
| Comparison | Ace Data Cloud | Direct Zhipu Connection |
|---|---|---|
| OpenAI-Compatible Format | ✓ | ✗ Proprietary API Format |
| Global Availability | ✓ Ready to Use | ✗ Restricted in Some Regions |
| Streaming | ✓ | ✓ |
| Unified Interface for Multiple Models | ✓ GPT / Claude / Gemini / GLM | ✗ GLM Only |
| Pay as You Go | ✓ Flexible Top-Ups | ✓ |
| No Chinese Phone Number Required to Register | ✓ | ✗ Chinese Phone Number Required |
| Deep Reasoning Models | ✓ | ✓ |
Choose the right GLM model
Choose a flagship reasoning, general-purpose text, or vision-language model for your task
GLM-5.3
Deep reasoningThe latest flagship model for complex software engineering, coding, and Agent tasks. Supports 1M context and up to 128K output.
- ✓ Reasoning always enabled
- ✓ 1M context window
- ✓ Up to 128K output
- ✓ Top choice for complex coding and Agent tasks
GLM-4.7
Balanced choiceThe best balance of performance and cost. Supports reasoning and is suitable for most general conversation and programming scenarios.
- ✓ Excellent value
- ✓ Excellent for general conversation
- ✓ Supports reasoning
- ✓ Suitable for production environments
GLM-3-Turbo
Lightweight textSuitable for text classification, field extraction, and short conversations.
- ✓ Billed by input and output usage
- ✓ Text input and output
- ✓ Suitable for high-volume tasks
- ✓ Classification/extraction/simple conversation
GLM API Pricing
Pay based on Token usage. No subscription fees, no hidden costs.
Get greater discounts with bulk packages
Billed based on actual Token usage, with input and output priced separately
- ✓ 10 GLM models to choose from on demand
- ✓ GLM-3-Turbo text chat
- ✓ GLM-5.3 deep reasoning ready to use
- ✓ Input and output priced separately
- ✓ Streaming responses supported, billed based on actual Token usage
Tailored plans for high-volume teams
- ✓ Tiered discounts based on usage
- ✓ Priority support and an account manager
- ✓ Custom rate limits
- ✓ SLA guarantee
- ✓ Private deployment options
Frequently Asked Questions
Everything you need to know about using the GLM API
What is GLM? How does it differ from other models? ▾
GLM is a series of large language models launched by Zhipu AI and developed by a technical team from Tsinghua University. GLM excels at native Chinese understanding while also performing well in English. GLM-5.3 is the current flagship and supports deep reasoning; GLM-4.5v supports multimodal vision; GLM-3-Turbo is suited to general text generation.
Does it support the OpenAI SDK? ▾
Yes! It is fully compatible with the OpenAI SDK (Python, Node.js, Go, etc.). Simply change base_url to https://api.acedata.cloud/glm and set model to any GLM model name. You can switch your existing OpenAI code to GLM with almost no modifications.
How does GLM-5.3's deep reasoning differ from ordinary models? ▾
GLM-5.3 has built-in Thinking reasoning capabilities. The model reasons based on the complexity of the question before providing a final answer. This gives it stronger performance in mathematical proofs, complex logic, programming, and Agent tasks; reasoning tokens are billed at output token rates.
How can I compare the costs of different models? ▾
Select a model on the service pricing page to view the Credits rates per million input and output tokens. Models that offer discounted cache reads also list cache rates. Actual costs depend on usage and the package purchased.
How does pricing work? ▾
Billing is based on token usage, with input and output tokens priced separately. See the service pricing page for each model's rates. There are no subscription or monthly fees; pay only for what you use. Funds are available immediately after adding them, and your balance never expires.
Can I use GPT, Claude, Gemini, and GLM at the same time? ▾
Yes! Ace Data Cloud provides multiple LLMs, including GPT, Claude, Gemini, and GLM, through a unified OpenAI-compatible interface. Simply change the model parameter to switch between models. The API format is identical, so there is no need to maintain multiple codebases. The same API Key can access all models.
Other AI Models
Explore our complete suite of AI APIs, covering large language models, images, video, and music
Gemini API
Google's complete Gemini model family—million-token context and deep reasoning
Claude API
Anthropic's complete Claude model family—powerful reasoning and conversation capabilities
Kimi API
Moonshot AI's complete Kimi K2 family—trillion-parameter MoE reasoning models
Flux API
Black Forest Labs' top-tier text-to-image model
Start Using the GLM API Now
Use GLM large language models through an OpenAI-compatible format. Pay as you go—no subscription fees, no commitments.