curl --request GET \
--url https://api.acedata.cloud/v1/realtime \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.acedata.cloud/v1/realtime"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.acedata.cloud/v1/realtime', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));Openai Realtime
Low-latency speech-to-speech over a WebSocket using the OpenAI Realtime GA event protocol. Connect with wss://api.acedata.cloud/v1/realtime?model=gpt-realtime and an Authorization: Bearer <token> header (browsers pass realtime, acedata-token.<token> via Sec-WebSocket-Protocol). Client and server exchange Realtime JSON events (session.update, input_audio_buffer.append, response.create, response.output_audio.delta, response.done, …). The relay fixes the connection model, pcm16 @ 24kHz mono transport, output voice, transcription, and noise-reduction settings; choose the model and voice when connecting. A session.update may change GA fields instructions, tools, tool_choice, output_modalities, include, prompt, reasoning, parallel_tool_calls, tracing, truncation, may lower max_output_tokens from the platform cap, and may set audio.input.turn_detection to null, server_vad, or semantic_vad with their documented controls. It preserves the optional client event_id. Attempts to change fixed fields, exceed the output-token cap, use legacy beta fields, or send unknown fields return a recoverable error event; the top-level event_id uniquely identifies the server error event, while error.event_id contains the original client event ID when supplied, and error.param identifies the rejected field. The WebSocket remains open. Billed per assistant turn from response.done.usage (audio and text tokens priced separately).
curl --request GET \
--url https://api.acedata.cloud/v1/realtime \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.acedata.cloud/v1/realtime"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.acedata.cloud/v1/realtime', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));Авторизации
API token from https://platform.acedata.cloud
Параметры запроса
Realtime model to use. Use gpt-realtime-2.1 for best quality or gpt-realtime-2.1-mini for lower cost. Older stable model IDs remain available for compatibility.
gpt-realtime-2.1, gpt-realtime-2.1-mini, gpt-realtime-2, gpt-realtime, gpt-realtime-mini Output voice selected when the connection is established.
alloy, ash, ballad, coral, echo, sage, shimmer, verse, marin, cedar Ответ
Switching Protocols — WebSocket established.
Была ли эта страница полезной?

