Open a realtime voice session
GET/v1/realtime
Upgrades to a WebSocket and relays the OpenAI realtime protocol to the vendor of the model, with no change to the events. proxium checks the key, the budget and the limit of open sessions before the upgrade, and opens the vendor socket before it answers, so a refusal is an HTTP error. Every response that the vendor starts takes one call of the budget. When the budget refuses a response, proxium cancels it, sends an error event with the refusal code and closes the session. Each response.done writes one usage row. The text events of the client go through the data protection of the project. A server sends the key in Authorization. A browser sends it in the subprotocol openai-insecure-api-key.<key>, next to realtime.
Request
Responses
- 101
- 400
- 401
- 402
- 426
- 429
- 503
The session is open. The events are the vendor's.
The query has no model (missing_model), or no realtime vendor serves it or the key may not use it (no_route).
The bearer virtual key is missing (missing_key), or it is not valid or it is revoked (invalid_key).
The project may not send calls (subscription_required). proxium.tech is in open beta and does not return this answer.
The request is not a WebSocket upgrade (upgrade_required).
The budget refused the session, or the key or the project has its limit of open sessions (too_many_sessions).
Response Headers
Seconds to wait before the next call.
No vendor of the plan opened the session (upstream_failed), or the server is stopping (shutting_down).
Response Headers
Seconds to wait before the next call.