docs: document OPENAI_BASE_URL /v1 requirement (#2533) - #2556
docs: document OPENAI_BASE_URL /v1 requirement (#2533)#2556KunyangZhang wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d9f4618b24
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| | llama.cpp | `http://127.0.0.1:8080/v1` | | ||
| | OpenRouter | `https://openrouter.ai/api/v1` | | ||
|
|
||
| > **Important:** `OPENAI_BASE_URL` must include the API version prefix used by your provider, usually `/v1`. Chat UI appends `/models` to this value to discover available models, so an origin-only value such as `https://api.example.com` returns `404`. Do not set it to an endpoint that already includes `/chat/completions` — Chat UI sends that path itself when completing requests. |
There was a problem hiding this comment.
Don't require a version segment in every base URL
This describes /v1 as mandatory even though the implementation treats OPENAI_BASE_URL as an arbitrary common prefix: it only strips a trailing slash and requests ${baseURL}/models, while the OpenAI client appends chat/completions. Consequently, an OpenAI-compatible provider or reverse proxy that exposes GET /models and POST /chat/completions at its origin works with an origin-only value; the new guidance incorrectly tells those users it will 404. Describe the value as the common API prefix required by the configured provider rather than requiring a version segment.
Useful? React with 👍 / 👎.
No description provided.