Buy a GLM API Key

GLM is the flagship model series from Z.ai, a leading AI lab. Its models GLM-5.1 / GLM-5-Turbo are strong at reasoning and code generation. This guide walks you from zero to a working API Key in about 5 minutes.


Step 1: Create a Z.ai Account

  1. Go to the international platform: https://z.ai/manage-apikey/apikey-list
  2. Click Continue with Google, Continue with Email, or Continue with GitHub
  3. Follow the prompts to complete registration and sign in
Z.ai signup page
Fig 1: Z.ai signup page

Step 2: Add a Payment Method and Top Up

  1. In the left sidebar, click Billing
  2. Click Add a Payment Method
  3. Enter your card details and complete the payment setup
  4. Credits activate instantly after payment
Z.ai Billing page
Fig 2: Add a payment method

⚠️ Balance is non-refundable — only load what you plan to use.


Step 3: Create an API Key

  1. In the left sidebar, click API Keys
  2. Click Create a new API key in the bottom right
  3. Give it a recognizable name (e.g. openclacky-mac)
  4. Find the newly created key in the list and click the copy icon
Create API Key
Fig 3: Create API Key

⚠️ The full Key is not displayed in plain text. Click the copy icon to copy it, then paste it somewhere safe immediately.


Step 4: Configure in OpenClacky

Open the Connect AI Model page in OpenClacky and follow these steps:

  1. Provider dropdown → select GLM (Z.ai / Zhipu)
  2. Model dropdown → pick a model
  3. Base URL → open the dropdown and select International · Pay-as-you-go
  4. API Key — paste the Key from Step 3, click Test & Continue

A green success message means you're all set.

⚠️ If you purchased a GLM Coding Plan, the endpoint is different — select Coding Plan from the Base URL dropdown.


FAQ

Q1: What's the difference between the models?

  • glm-5.1: Latest flagship, stronger reasoning, best for complex tasks
  • glm-5-turbo: Optimized for coding tools like OpenClacky, better at tool-calling but weaker than glm-5.1
  • glm-5v-turbo: Native multimodal model, supports image input

Q2: My Key keeps throwing errors — what should I check?

Check that your account has sufficient balance, the API Key hasn't expired, and the Key was fully copied. If you're using a Coding Plan key, make sure to select the Coding Plan endpoint in the Base URL dropdown.

Q3: I forgot to save my API Key!

Go back to the API Keys page and copy it again from the list.

Q4: How do I track spending?

Go to Billing → Billing History to view daily usage and charges per Key.