使用智谱 BigModel对接时报错

Author: hui98765Created May 9, 2026Updated May 9, 2026

F:\opensource\Open-AutoGLM-main>python main.py --device-type hdc --base-url https://open.bigmodel.cn/api/paas/v4 --model "autoglm-phone" --apikey "我的apikey" "打开短信" Checking system requirements...

  1. Checking HDC installation... ✅ OK (Ver: 3.1.0a)
  2. Checking connected devices... ✅ OK (1 device(s): 3DK0124730000521)
  3. Skipping keyboard check for HarmonyOS... ✅ OK (using native input)

✅ All system checks passed!

Checking model API...

  1. Checking API connectivity (https://open.bigmodel.cn/api/paas/v4)... ❌ FAILED Error: Cannot connect to https://open.bigmodel.cn/api/paas/v4 Solution:
    1. Check if the model server is running
    2. Verify the base URL is correct
    3. Try: curl https://open.bigmodel.cn/api/paas/v4/chat/completions

❌ Model API check failed. Please fix the issues above.

提示API连接失败,但是我用postman post https://open.bigmodel.cn/api/paas/v4/chat/completions可以正常返回内容,请问如何解决?