freeaiapi.aiSign Up

GLM API — up to 30% cheaper

Get free GLM API key

Use GLM models for coding and agents through one OpenAI-compatible endpoint.

Models
10
From
$0.037 /M input
Below official
up to 30%
Prices updated
2026-11-26

GLM API pricing

Live prices next to the official list price

Zhipu AI: glm-4-airx

−30% vs official

glm-4-airx is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.037/M input tokens$0.148/M output tokens

Zhipu AI: glm-4-flash

−30% vs official

glm-4-flash is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.037/M input tokens$0.148/M output tokens

Zhipu AI: glm-4-long

−30% vs official

glm-4-long is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.037/M input tokens$0.148/M output tokens

Zhipu AI: glm-4.5

−30% vs official

glm-4.5 is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.42/M input tokens$1.68/M output tokens

Zhipu AI: glm-4.5-air

−30% vs official

glm-4.5-air is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.14/M input tokens$0.77/M output tokens$0.021/M cached input

Zhipu AI: glm-5

−30% vs official

glm-5 is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.70/M input tokens$2.24/M output tokens

Zhipu AI: glm-5.1

−30% vs official

glm-5.1 is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.98/M input tokens$3.08/M output tokens$0.182/M cached input

Zhipu AI: glm-5.2

−30% vs official

glm-5.2 is a text and chat model from Zhipu AI, available through one freeaiapi.ai API key and billed from your prepaid balance.

by zhipu ai$0.98/M input tokens$3.08/M output tokens$0.182/M cached input

Zhipu AI: glm-5.3

−30% vs official

GLM-5.3 is Zhipu's flagship model, with clear gains in complex software engineering and agent tasks delivered through post-training on the GLM-5.2 base.

by zhipu ai$0.98/M input tokens$3.08/M output tokens$0.182/M cached input

Zhipu AI: glm-5.3-flash

−30% vs official

GLM-5.3 Flash is an open-weight model that combines sparse and linear attention to cut the cost of long-context work while keeping strong coding performance.

by zhipu ai$0.105/M input tokens$0.35/M output tokens$0.021/M cached input

Call GLM models with the OpenAI SDK

Change the base URL and key — nothing else

curl https://api.freeaiapi.ai/v1/chat/completions \
  -H "Authorization: Bearer $FREEAIAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "glm-4-airx",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'

GLM API FAQ

Is this the official Zhipu AI API?

No. freeaiapi.ai is an independent API gateway. You get one OpenAI-compatible key that routes to Zhipu AI and other models, billed from a prepaid balance.

Do I need a credit card to start?

No. Sign up, connect Telegram and join our channel to unlock $1 trial credit. Create an API key and make your first request. Add funds when you want to keep going.

Does it work with the OpenAI SDK?

Yes. Point any OpenAI SDK or OpenAI-compatible tool at https://api.freeaiapi.ai/v1 and use your freeaiapi.ai key. No code changes beyond the base URL and key.

Other model APIs

Get your free GLM API key

No card required. One key for every model, up to 30% below official pricing.

Get free API key

Not affiliated with Zhipu AI. GLM is a trademark of Zhipu AI.