Endpoint Matrix
Base URL:
text
https://api.rout.my/v1| Endpoint | Method | Body shape | Output | Notes |
|---|---|---|---|---|
GET /models | GET | none | OpenAI-style model list | Use this first to copy exact model IDs. |
POST /chat/completions | POST | model, messages, optional stream, tools, vision content | Chat completion or SSE stream | Best for OpenAI-compatible chat clients. |
POST /responses | POST | model, input, optional tools/stream-like fields | Responses-style object or stream | Useful when an app expects the newer Responses shape. |
POST /embeddings | POST | model, input, optional encoding_format | Embedding list | For search, RAG, clustering, and semantic matching. |
POST /images/generations | POST | model, prompt, optional n, size, quality, image_config | data[].url or data[].b64_json | Single-prompt image generation. |
POST /video/generations | POST | model, prompt, optional provider-neutral video fields | Video generation response | Provider capabilities differ by model. |
GET https://api.rout.my/embed/image:{model} | GET | query params | Raw image bytes | Convenient for embedding generated images in pages. This route is outside /v1. |
POST /messages | POST | Anthropic-style messages body | Anthropic-compatible response | For Anthropic-native clients. |
POST /compatible/v1beta/models/{model}:generateContent | POST | Gemini-style contents | Gemini-compatible response | For Gemini-compatible clients. |
Compatibility Notes
- rout.my forwards model-specific fields when the selected provider supports them.
- Unknown fields can be ignored or rejected depending on endpoint family and provider behavior.
- For browser tools, keep keys user-supplied. Do not hardcode a shared key into public frontend code.
- For retries, prefer exponential backoff on
429,500,502, and503.