[PR #2002] [MERGED] feat(zhipuai): add optional base_url field in provider schema #2202

Closed
opened 2026-02-16 11:16:21 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/langgenius/dify-official-plugins/pull/2002
Author: @WenXIN-AI
Created: 11/5/2025
Status: Merged
Merged: 11/11/2025
Merged by: @crazywoola

Base: mainHead: feat/zhipuai-baseurl


📝 Commits (3)

  • 3c2ddc0 feat(zhipuai): add optional base_url field in provider schema
  • 4e6a07f chore(zhipuai): bump version to 0.0.17
  • 631270b Update models/zhipuai/models/llm/llm.py

📊 Changes

5 files changed (+22 additions, -5 deletions)

View changed files

📝 models/zhipuai/manifest.yaml (+1 -1)
📝 models/zhipuai/models/_common.py (+6 -0)
📝 models/zhipuai/models/llm/llm.py (+3 -3)
📝 models/zhipuai/provider/zhipuai.py (+1 -1)
📝 models/zhipuai/provider/zhipuai.yaml (+11 -0)

📄 Description

Related Issues or Context

This PR adds an optional API Endpoint Host field to the ZhipuAI provider schema.
It allows users to configure different API endpoints depending on their region.

Context:
ZhipuAI provides two different API Base URLs based on the user's location:

  • Mainland China: https://open.bigmodel.cn/api/paas/v4/
  • Overseas regions: https://api.z.ai/api/paas/v4/

By introducing an optional API Endpoint Host, users can now flexibly switch between these endpoints without modifying the plugin source code.
This improves usability for global developers using Dify.


This PR contains Changes to Non-Plugin

  • Documentation
  • Other

This PR contains Changes to Non-LLM Models Plugin

  • I have Run Comprehensive Tests Relevant to My Changes

This PR contains Changes to LLM Models Plugin

  • My Changes Affect Model Configuration or Initialization Logic (e.g., Provider Schema Fields)
  • Other Changes (Add New Models, Fix Model Parameters etc.)

Version Control (Any Changes to the Plugin Will Require Bumping the Version)

  • I have Bumped Up the Version in Manifest.yaml (version: 0.0.16)

Dify Plugin SDK Version

  • Ensured dify_plugin>=0.3.0,<0.6.0 is in requirements.txt

Environment Verification

☁️ SaaS Environment

  • Tested on cloud.dify.ai to ensure consistent provider configuration behavior

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/langgenius/dify-official-plugins/pull/2002 **Author:** [@WenXIN-AI](https://github.com/WenXIN-AI) **Created:** 11/5/2025 **Status:** ✅ Merged **Merged:** 11/11/2025 **Merged by:** [@crazywoola](https://github.com/crazywoola) **Base:** `main` ← **Head:** `feat/zhipuai-baseurl` --- ### 📝 Commits (3) - [`3c2ddc0`](https://github.com/langgenius/dify-official-plugins/commit/3c2ddc011e4dccb1aace6755761b3508d896b4f4) feat(zhipuai): add optional base_url field in provider schema - [`4e6a07f`](https://github.com/langgenius/dify-official-plugins/commit/4e6a07f8358d93291b7f2cd2a59ac5a198a4300f) chore(zhipuai): bump version to 0.0.17 - [`631270b`](https://github.com/langgenius/dify-official-plugins/commit/631270bfc11674440e67d1f33c1fb4f20d01d89d) Update models/zhipuai/models/llm/llm.py ### 📊 Changes **5 files changed** (+22 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `models/zhipuai/manifest.yaml` (+1 -1) 📝 `models/zhipuai/models/_common.py` (+6 -0) 📝 `models/zhipuai/models/llm/llm.py` (+3 -3) 📝 `models/zhipuai/provider/zhipuai.py` (+1 -1) 📝 `models/zhipuai/provider/zhipuai.yaml` (+11 -0) </details> ### 📄 Description ### Related Issues or Context This PR adds an optional `API Endpoint Host` field to the **ZhipuAI provider schema**. It allows users to configure different API endpoints depending on their region. **Context:** ZhipuAI provides two different API Base URLs based on the user's location: - **Mainland China:** `https://open.bigmodel.cn/api/paas/v4/` - **Overseas regions:** `https://api.z.ai/api/paas/v4/` By introducing an optional `API Endpoint Host`, users can now flexibly switch between these endpoints without modifying the plugin source code. This improves usability for global developers using Dify. --- ### This PR contains Changes to *Non-Plugin* - [ ] Documentation - [ ] Other --- ### This PR contains Changes to *Non-LLM Models Plugin* - [ ] I have Run Comprehensive Tests Relevant to My Changes --- ### This PR contains Changes to *LLM Models Plugin* - [x] My Changes Affect Model Configuration or Initialization Logic (e.g., Provider Schema Fields) - [x] Other Changes (Add New Models, Fix Model Parameters etc.) --- ### Version Control (Any Changes to the Plugin Will Require Bumping the Version) - [x] I have Bumped Up the Version in Manifest.yaml (`version: 0.0.16`) --- ### Dify Plugin SDK Version - [x] Ensured `dify_plugin>=0.3.0,<0.6.0` is in requirements.txt --- ### Environment Verification #### ☁️ SaaS Environment - Tested on `cloud.dify.ai` to ensure consistent provider configuration behavior --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 11:16:21 -05:00
yindo closed this issue 2026-02-16 11:16:21 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-official-plugins#2202