Black Friday Sale 2026. Get up to 20% bonus credits.

Ends inSee the offer

glm-5

Input price
$0.80/1M tokens
Output price
$2.56/1M tokens
Context window
200K
Modalities
Text → Text

Pricing

Per million tokens

API call price20% OFF

Input

$0.80

Output

$2.56

Cache write

$0.00

Cache read

$0.16

Server tools

Billed per successful upstream call

  • Web Search

    The model searches the live web. The search runs upstream.

    $10.00/1K calls



Integration & capabilities

Supported protocols

Messages API
Compatible formatAnthropic
Routes
POST /v1/messages
POST /v1/messages/count_tokens
FeaturesStreaming · Prompt caching · Function calling · System messages
Request parametersmodel, messages, system, tools, stream, metadata

cURL Example

curl -X POST https://api.openmodel.ai/v1/messages \
  -H "Content-Type: application/json" \
  -H "x-api-key: $API_KEY" \
  -H "anthropic-version: 2023-06-01" \
  -d '{
    "model": "glm-5",
    "max_tokens": 1024,
    "messages": [
      {"role": "user", "content": "Hello"}
    ]
  }'

Supported capabilities

Function Calling
Function calling (also known as tool calling) provides a powerful and flexible way for models to interface with external systems and access data outside their training data.
Tool Choice
By default the model will determine when and how many tools to use. You can force specific behavior with the tool_choice parameter.
Reasoning
Reasoning models use internal reasoning tokens before producing a response.
Prompt Caching
Optimizes API usage by allowing resuming from specific prefixes in your prompts. This significantly reduces processing time and costs for repetitive tasks or prompts with consistent elements.

Context & limits

Context window

200K

Max output tokens

128K