Skip to content

Commit bdf867a

Browse files
committed
1 parent f70efaf commit bdf867a

2 files changed

Lines changed: 35 additions & 21 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "unified-ai-router",
3-
"version": "3.7.10",
3+
"version": "3.7.11",
44
"description": "A unified interface and openai-compatible server for multiple LLM providers with automatic fallback. Supports providers like Openrouter, Grok, and more, ensuring reliability and flexibility for your AI applications.",
55
"license": "ISC",
66
"author": "mlibre",

readme.md

Lines changed: 34 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -233,9 +233,6 @@ The server provides these endpoints at `http://localhost:3000`:
233233
| `GET /health` | Health check endpoint |
234234
| `GET /v1/providers/status` | Provider status and health |
235235

236-
<details>
237-
<summary><strong>Click to view server examples</strong></summary>
238-
239236
### 🌐 Web Chatbot Interface
240237

241238
The server includes a responsive web chatbot interface accessible at: `http://localhost:3000/`
@@ -244,24 +241,29 @@ Features include mobile responsiveness, dark/light themes, conversation history,
244241

245242
### 💬 Simple Chat Example
246243

244+
<details>
245+
<summary><strong>Click to view simple chat example</strong></summary>
246+
247247
**Request:**
248248

249-
```json
250-
{
251-
"model": "any-model",
252-
"messages": [
253-
{
254-
"role": "system",
255-
"content": "You are a helpful assistant."
256-
},
257-
{
258-
"role": "user",
259-
"content": "hey"
260-
}
261-
],
262-
"temperature": 0.7,
263-
"stream": false
264-
}
249+
```bash
250+
curl -X POST http://localhost:3000/v1/chat/completions \
251+
-H "Content-Type: application/json" \
252+
-d '{
253+
"model": "any-model",
254+
"messages": [
255+
{
256+
"role": "system",
257+
"content": "You are a helpful assistant."
258+
},
259+
{
260+
"role": "user",
261+
"content": "hey"
262+
}
263+
],
264+
"temperature": 0.7,
265+
"stream": false
266+
}'
265267
```
266268

267269
**Response:**
@@ -311,8 +313,13 @@ Features include mobile responsiveness, dark/light themes, conversation history,
311313
}
312314
```
313315

316+
</details>
317+
314318
### 🛠️ Tool Calling Example
315319

320+
<details>
321+
<summary><strong>Click to view tool calling example</strong></summary>
322+
316323
The server supports function calling with streaming responses:
317324

318325
```bash
@@ -423,10 +430,17 @@ curl -X POST http://localhost:3000/v1/chat/completions \
423430
}
424431
```
425432

433+
</details>
434+
426435
### 🗣️ Responses API Example
427436

437+
<details>
438+
<summary><strong>Click to view responses API example</strong></summary>
439+
428440
The server also supports OpenAI's Responses API with the same reliability features:
429441

442+
**Non-Streaming Response:**
443+
430444
```bash
431445
curl -X POST http://localhost:3000/v1/responses \
432446
-H "Content-Type: application/json" \
@@ -478,7 +492,7 @@ curl -X POST http://localhost:3000/v1/responses \
478492
}
479493
```
480494

481-
**Streaming Responses API:**
495+
**Streaming Response:**
482496

483497
```bash
484498
curl -X POST http://localhost:3000/v1/responses \

0 commit comments

Comments
 (0)