400 BAD REQUEST #4361

Closed
opened 2026-02-21 18:06:04 -05:00 by yindo · 5 comments
Owner

Originally created by @xkcp008 on GitHub (Jul 1, 2024).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.6.11

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

微信截图_20240701152622
http://********/console/api/workspaces/current/model-providers/openai
Error 400 BAD REQUEST invalid_param encountered while setting up the model

✔️ Expected Behavior

No response

Actual Behavior

No response

Originally created by @xkcp008 on GitHub (Jul 1, 2024). ### Self Checks - [X] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [X] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [X] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [X] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [X] Please do not modify this template :) and fill in all the required fields. ### Dify version 0.6.11 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce ![微信截图_20240701152622](https://github.com/langgenius/dify/assets/6188585/4724b1b1-c883-47ee-adf1-c490aa279563) http://********/console/api/workspaces/current/model-providers/openai Error 400 BAD REQUEST invalid_param encountered while setting up the model ### ✔️ Expected Behavior _No response_ ### ❌ Actual Behavior _No response_
yindo added the 🤔 cant-reproduce label 2026-02-21 18:06:04 -05:00
yindo closed this issue 2026-02-21 18:06:04 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Jul 1, 2024):

Hello, @xkcp008! I'm here to assist you with any bugs, questions, or contributions you may have while waiting for a human maintainer. Let's work together to resolve the issue you've encountered.

The 400 BAD REQUEST error with "invalid_param" and "Connection error" messages while setting up the OpenAI API key in your self-hosted Dify instance is likely due to a proxy configuration issue in your environment. Please check if your environment has a proxy set up and ensure it is correctly configured or disabled if not needed [1].

Additionally, ensure that the frontend and backend versions of your Dify instance are up-to-date and consistent with each other to avoid potential connection issues [2].

To continue talking to Dosu, mention @dosu.

@dosubot[bot] commented on GitHub (Jul 1, 2024): <!-- Greeting --> Hello, @xkcp008! I'm here to assist you with any bugs, questions, or contributions you may have while waiting for a human maintainer. Let's work together to resolve the issue you've encountered. <!-- Answer --> The 400 BAD REQUEST error with "invalid_param" and "Connection error" messages while setting up the OpenAI API key in your self-hosted Dify instance is likely due to a proxy configuration issue in your environment. Please check if your environment has a proxy set up and ensure it is correctly configured or disabled if not needed <sup>[[1]](https://github.com/langgenius/dify-docs/blob/main/zh_CN/learn-more/faq/llms-use-faq.md)</sup>. Additionally, ensure that the frontend and backend versions of your Dify instance are up-to-date and consistent with each other to avoid potential connection issues <sup>[[2]](https://github.com/langgenius/dify-docs/blob/main/en/guides/application-orchestrate/llms-use-faq.md)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
Author
Owner

@xkcp008 commented on GitHub (Jul 1, 2024):

Do I need to climb over a wall to successfully set up ChatGPT? I am using the latest version of GitHub, which should be the latest version

@xkcp008 commented on GitHub (Jul 1, 2024): Do I need to climb over a wall to successfully set up ChatGPT? I am using the latest version of GitHub, which should be the latest version
Author
Owner

@dosubot[bot] commented on GitHub (Jul 1, 2024):

Yes, if you are in a region where access to OpenAI's services is restricted, you may need to use a VPN or proxy to successfully set up and communicate with ChatGPT. Ensure that your proxy settings are correctly configured in your environment to avoid connection issues [1].

To continue talking to Dosu, mention @dosu.

@dosubot[bot] commented on GitHub (Jul 1, 2024): <!-- Answer --> Yes, if you are in a region where access to OpenAI's services is restricted, you may need to use a VPN or proxy to successfully set up and communicate with ChatGPT. Ensure that your proxy settings are correctly configured in your environment to avoid connection issues <sup>[[1]](https://github.com/langgenius/dify-docs/blob/main/zh_CN/learn-more/faq/llms-use-faq.md)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
Author
Owner

@xkcp008 commented on GitHub (Jul 1, 2024):

How can ordinary users use my website services without VPN ? Whether to deploy the website abroad ?

@xkcp008 commented on GitHub (Jul 1, 2024): How can ordinary users use my website services without VPN ? Whether to deploy the website abroad ?
Author
Owner

@crazywoola commented on GitHub (Jul 1, 2024):

Please check your openai provider, I can not reproduce this problem with OpenAI apikey.

How can ordinary users use my website services without VPN ? Whether to deploy the website abroad ?

You can deploy in Aliyun or Tencent Cloud.

@crazywoola commented on GitHub (Jul 1, 2024): Please check your openai provider, I can not reproduce this problem with OpenAI apikey. > How can ordinary users use my website services without VPN ? Whether to deploy the website abroad ? You can deploy in Aliyun or Tencent Cloud.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#4361