Status: [UNTESTED] Endpoints found: http://localhost:3001/v1/chat/completions http://localhost:3001/v1/messages Source: https://github.com/izaart95-jpg/GLM-Free-API # GLM Bridge — Z.AI Proxy API OpenAI- & Anthropic-compatible API proxy for chat.z.ai. Pure HTTP, no browser automation at runtime. **Hosted:** `https://glm.cognix.sryze.cc/v1` — auth `Waguri` (Bearer or `x-api-key`), agent mode, supports `glm-5.2`/`glm-5.3-flash`. OpenAI endpoint recommended. ## Features - Dual protocol: OpenAI `/v1/chat/completions` + Anthropic `/v1/messages`; streaming (SSE, 5s keep-alive) + non-streaming - Pure HTTP (HTTP/2 pooled), pure-Go SQLite (no CGO) - Vision: images on both endpoints (URL/base64), uploaded to Z.AI file endpoint; 10 images / 50MB each; requires `ZAI_TOKEN` - Throwaway sessions: chat deleted on Z.AI when response completes - Async session pool (default 5 pre-made sessions; `--sync-mode` for legacy per-request flow) - Agent mode: translates OpenAI tools/roles into user-only prompt, rewrites `<<>>` back to native `tool_calls`/`tool_use`. Modern XML shim (default) + legacy `[ROLE: ...]` shim - Per-model feature resolution; `image_generation` always `false`; `reasoning_effort` (`high`/`max`) forwarded only if supported - Live model list from Z.AI `/api/models` (cached 5 min) - Token pool from `cmd/token-collector` (device tokens minted in Go, ≥35 min after browser closes) - Background captcha cache (2 cached, 75s TTL) - Graceful shutdown: drains in-flight (10s), deletes pooled sessions - WAF circuit breaker (issue #41): shared pacing gate, block detection, fail-fast 503, background recovery with doubling backoff ## Supported Models Fetched live (cached 5 min), keeps newest down to `glm-4.7`. Fallback list: `glm-5.3-flash`, `glm-5.3`, `glm-5.2`, `GLM-5.1`, `GLM-5-Turbo`, `GLM-5v-Turbo` (vision), `glm-4.7`. Each `/v1/models` entry has OpenAI-style `architecture` (modality, input/output modalities). No `model` in body → defaults `glm-5`. Guest sessions typically only allow `glm-5.3-flash` and `glm-4.7`. `/models` returns `{ models, currentModel }`. ## Getting `ZAI_TOKEN` (recommended) Log in at chat.z.ai â†