Skip to content

Commit e7cc199

Browse files
committed
docs
1 parent cffc83c commit e7cc199

File tree

1 file changed

+21
-9
lines changed

1 file changed

+21
-9
lines changed

docs/models.md

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,16 @@ You just need to add your provider to `providers` and make sure add the required
5858

5959
Schema:
6060

61-
| Option | Type | Description | Required |
62-
|-------------------------------|--------|---------------------------------------------------------------------------------|----------|
63-
| `api` | string | The API schema to use (`"openai-responses"`, `"openai-chat"`, or `"anthropic"`) | Yes |
64-
| `urlEnv` | string | Environment variable name containing the API URL | No* |
65-
| `url` | string | Direct API URL (use instead of `urlEnv`) | No* |
66-
| `keyEnv` | string | Environment variable name containing the API key | No* |
67-
| `key` | string | Direct API key (use instead of `keyEnv`) | No* |
68-
| `models` | map | Key: model name, value: its config | Yes |
69-
| `models <model> extraPayload` | map | Extra payload sent in body to LLM | No |
61+
| Option | Type | Description | Required |
62+
|--------------------------------|--------|-----------------------------------------------------------------------------------------------------|----------|
63+
| `api` | string | The API schema to use (`"openai-responses"`, `"openai-chat"`, or `"anthropic"`) | Yes |
64+
| `urlEnv` | string | Environment variable name containing the API URL | No* |
65+
| `url` | string | Direct API URL (use instead of `urlEnv`) | No* |
66+
| `keyEnv` | string | Environment variable name containing the API key | No* |
67+
| `key` | string | Direct API key (use instead of `keyEnv`) | No* |
68+
| `completionUrlRelativePath` | string | Optional override for the completion endpoint path (see defaults below and examples like Azure) | No |
69+
| `models` | map | Key: model name, value: its config | Yes |
70+
| `models <model> extraPayload` | map | Extra payload sent in body to LLM | No |
7071

7172
_* url and key will be search as env `<provider>_API_URL` / `<provider>_API_KEY`, but require config or to be found to work._
7273

@@ -105,6 +106,17 @@ When configuring custom providers, choose the appropriate API type:
105106

106107
Most third-party providers use the `openai-chat` API for compatibility with existing tools and libraries.
107108

109+
#### Endpoint override (completionUrlRelativePath)
110+
111+
Some providers require a non-standard or versioned completion endpoint path. Use `completionUrlRelativePath` to override the default path appended to your provider `url`.
112+
113+
Defaults by API type:
114+
- `openai-responses`: `/v1/responses`
115+
- `openai-chat`: `/v1/chat/completions`
116+
- `anthropic`: `/v1/messages`
117+
118+
Only set this when your provider uses a different path or expects query parameters at the endpoint (e.g., Azure API versioning).
119+
108120
## Providers examples
109121

110122
=== "Anthropic"

0 commit comments

Comments
 (0)