inference-providers

GLM-4.7

by zai · family glm

Facts

Release date2025-12-22
Retired date
Knowledge cutoff
Context (max)202,752
Max output128,000
Modalitiestext → text
Aliasesglm-4.7glm-4p7GLM-4.7
Open weightsyes
DescriptionOpen-weight GLM generation between 4.6 and 5.x; hybrid thinking via enable_thinking on self-host-style surfaces.

Unknown values are shown as —.

Intelligence Index v4.1.1: 34 · Reasoning · Source: Artificial Analysis (accessed 2026-08-20)

Offerings

ProviderWire IDVariantEndpointProtocolStatusPrice (USD / Mtok)Reasoning
Fireworks AIglm-4p7inference-v1openai-chatga0.60 / 2.20adaptive · default on · returns reasoning_content · round-trips reasoning_content
IO Intelligence (io.net)zai-org/GLM-4.7chatopenai-chatga0.88 / 2.37effort · default on · returns reasoning_content
OpenRouterz-ai/glm-4.7chat-completionsopenai-chatga0.40 / 1.75effort · default on · returns reasoning_content · round-trips reasoning_content

Reasoning controls

Fireworks AI· glm-4p7· inference-v1 adaptive

adaptive · default on · returns reasoning_content · round-trips reasoning_content

IO Intelligence (io.net)· zai-org/GLM-4.7· chat effort

reasoning.effort nonelowmediumhigh● Default not documented — verify.

effort · default on · returns reasoning_content

OpenRouter· z-ai/glm-4.7· chat-completions effort

reasoning.effort nonelowmedium●highxhighmax

effort · default on · returns reasoning_content · round-trips reasoning_content

Example requests

Fireworks AI · openai-chat · glm-4p7

curl 'https://api.fireworks.ai/inference/v1/chat/completions' \
  -H 'Authorization: Bearer <YOUR_API_KEY>' \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "glm-4p7",
  "messages": [
    {
      "role": "user",
      "content": "Tell me about the weather."
    }
  ]
}'
Python (requests)
import requests

resp = requests.post(
    "https://api.fireworks.ai/inference/v1/chat/completions",
    headers={
      "Authorization": "Bearer <YOUR_API_KEY>",
      "Content-Type": "application/json"
    },
    json={
      "model": "glm-4p7",
      "messages": [
        {
          "role": "user",
          "content": "Tell me about the weather."
        }
      ]
    },
)
print(resp.json())
TypeScript (fetch)
const resp = await fetch("https://api.fireworks.ai/inference/v1/chat/completions", {
  method: "POST",
  headers: {
    "Authorization": "Bearer <YOUR_API_KEY>",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "model": "glm-4p7",
    "messages": [
      {
        "role": "user",
        "content": "Tell me about the weather."
      }
    ]
  }),
})
console.log(await resp.json())
  • ⚠ Responses include reasoning_content artifacts — pass them back unmodified on subsequent turns (dropping them triggers 400s or quality loss).

IO Intelligence (io.net) · openai-chat · zai-org/GLM-4.7

curl 'https://api.intelligence.io.solutions/api/v1/chat/completions' \
  -H 'Authorization: Bearer <YOUR_API_KEY>' \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "zai-org/GLM-4.7",
  "messages": [
    {
      "role": "user",
      "content": "Tell me about the weather."
    }
  ],
  "reasoning": {
    "effort": "high"
  }
}'
Python (requests)
import requests

resp = requests.post(
    "https://api.intelligence.io.solutions/api/v1/chat/completions",
    headers={
      "Authorization": "Bearer <YOUR_API_KEY>",
      "Content-Type": "application/json"
    },
    json={
      "model": "zai-org/GLM-4.7",
      "messages": [
        {
          "role": "user",
          "content": "Tell me about the weather."
        }
      ],
      "reasoning": {
        "effort": "high"
      }
    },
)
print(resp.json())
TypeScript (fetch)
const resp = await fetch("https://api.intelligence.io.solutions/api/v1/chat/completions", {
  method: "POST",
  headers: {
    "Authorization": "Bearer <YOUR_API_KEY>",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "model": "zai-org/GLM-4.7",
    "messages": [
      {
        "role": "user",
        "content": "Tell me about the weather."
      }
    ],
    "reasoning": {
      "effort": "high"
    }
  }),
})
console.log(await resp.json())

OpenRouter · openai-chat · z-ai/glm-4.7

curl 'https://openrouter.ai/api/v1/chat/completions' \
  -H 'Authorization: Bearer <YOUR_API_KEY>' \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "z-ai/glm-4.7",
  "messages": [
    {
      "role": "user",
      "content": "Tell me about the weather."
    }
  ],
  "reasoning": {
    "effort": "medium"
  }
}'
Python (requests)
import requests

resp = requests.post(
    "https://openrouter.ai/api/v1/chat/completions",
    headers={
      "Authorization": "Bearer <YOUR_API_KEY>",
      "Content-Type": "application/json"
    },
    json={
      "model": "z-ai/glm-4.7",
      "messages": [
        {
          "role": "user",
          "content": "Tell me about the weather."
        }
      ],
      "reasoning": {
        "effort": "medium"
      }
    },
)
print(resp.json())
TypeScript (fetch)
const resp = await fetch("https://openrouter.ai/api/v1/chat/completions", {
  method: "POST",
  headers: {
    "Authorization": "Bearer <YOUR_API_KEY>",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "model": "z-ai/glm-4.7",
    "messages": [
      {
        "role": "user",
        "content": "Tell me about the weather."
      }
    ],
    "reasoning": {
      "effort": "medium"
    }
  }),
})
console.log(await resp.json())
  • ⚠ Responses include reasoning_content artifacts — pass them back unmodified on subsequent turns (dropping them triggers 400s or quality loss).