zhipuai
A SDK library for accessing big model apis from ZhipuAI
Decision gist · record as of 2026-08-14
Yes, if you are actively using ZhipuAI's APIs and need a typed Python client. The SDK is straightforward to install and use, with low dependency friction. However, the aging maintenance status (354 days since last release, no recent commits tracked) and unclear license are concerns—verify the license for your use case and monitor for upstream API changes that the SDK may not immediately reflect.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires a valid ZhipuAI API key; set via api_key parameter or ZHIPUAI_API_KEY environment variable.
- Low install friction with five common dependencies (httpx, pydantic, cachetools, pyjwt, pydantic-core).
- Maintenance status is aging—no recent commits tracked and last release was 354 days ago, so expect slower response to issues or breaking upstream changes.
License · maintenance · safety
(unclear) — License treatment is unclear; no SPDX identifier or raw license text is available in the package metadata. Verify the actual license terms before using in proprietary or commercial projects.
last release 2025-08-25 (354 days)
0 known vulnerabilities (OSV.dev, 2026-08-14) · 342,875 downloads/mo, #7,393 on PyPI
Alternatives
Verify before relying
pip install zhipuai
from zhipuai import ZhipuAI
client = ZhipuAI(api_key="your-api-key")
response = client.chat.completions.create(
model="glm-4",
messages=[{"role": "user", "content": "Hello"}]
)
print(response.choices[0].message.content)- Whether the unclear license permits commercial or proprietary use without restriction.
- Current maintenance status and responsiveness to bug reports or security issues.
- Whether typing-extensions is truly optional or required despite not appearing in the runtime deps list.
What it is and what it does
This is the official Python SDK for ZhipuAI's large model API platform. It wraps HTTP calls to ZhipuAI's endpoints (chat completions, multimodal models, video generation, and assistants) behind a typed Python client interface. The SDK handles authentication via API keys, supports both standard and streaming responses, and includes connection pooling and token caching.
Developers use it to integrate ZhipuAI's models (like glm-4 and charglm-3) into Python applications without writing raw HTTP requests. It supports chat completions with tools, multimodal input (text and images), video generation, and character role-playing modes. The package requires Python 3.8+ and depends on httpx for HTTP transport and pydantic for request/response validation.
Use it for
- Build a chatbot or conversational AI system using glm-4 or charglm-3 models with streaming responses.
- Integrate multimodal capabilities (text + image analysis) into an application via glm-4v.
- Generate videos from text prompts using the cogvideox-2 model for content creation workflows.
- Implement an assistant-based system with custom knowledge or tools via the assistant endpoint.
- Add web search or tool-calling capabilities to chat completions for real-time information retrieval.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you are actively using ZhipuAI's APIs and need a typed Python client.
The SDK is straightforward to install and use, with low dependency friction. However, the aging maintenance status (354 days since last release, no recent commits tracked) and unclear license are concerns—verify the license for your use case and monitor for upstream API changes that the SDK may not immediately reflect.
Install
zhipuai on PyPI
Before you install
Low install friction with five common dependencies (httpx, pydantic, cachetools, pyjwt, pydantic-core). Maintenance status is aging—no recent commits tracked and last release was 354 days ago, so expect slower response to issues or breaking upstream changes.
Requires a valid ZhipuAI API key; set via api_key parameter or ZHIPUAI_API_KEY environment variable.
License in practice
License treatment is unclear; no SPDX identifier or raw license text is available in the package metadata. Verify the actual license terms before using in proprietary or commercial projects.
Quickstart
pip install zhipuai
from zhipuai import ZhipuAI
client = ZhipuAI(api_key="your-api-key")
response = client.chat.completions.create(
model="glm-4",
messages=[{"role": "user", "content": "Hello"}]
)
print(response.choices[0].message.content)
Verify before relying
- Whether the unclear license permits commercial or proprietary use without restriction.
- Current maintenance status and responsiveness to bug reports or security issues.
- Whether typing-extensions is truly optional or required despite not appearing in the runtime deps list.
Package facts
| License | Not declared unclear |
| Python support | Supports the current Python release !=2.7.*,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,!=3.7.*,>=3.8 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 5 packagescachetoolshttpxpydanticpydantic-corepyjwt |
| Maintenance | Aging 354 days since the last release |
| First released | |
| Downloads | 342,875 / month, #7,393 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Programming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9 |
Evidence: zhipuai-2.1.5.20250825-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “zhipuai api client”
- zhipuaiOfficial Python SDK for ZhipuAI's large model APIs, providing…
- codewords-clientA Python client library for the Codewords API with built-in FastAPI…
- twentyc.rpcA client library for consuming 20c's RESTful API, built on top of the…
Give your agent the search over MCP, or paste the wish link into any chat.
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.
Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.
Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.
Install it if you work with Hugging Face Hub models or datasets.
LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.
hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.
Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.
Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.
Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.
See also zai-sdk · ai21 · llama-api-client · vlmrun · groq · llama-index-llms-openai · writer-sdk · cerebras-cloud-sdk · pydo · pyimouapi