Server-side Python SDK for Vox-hosted WebRTC sessions.
Project description
vox-rtc-server
Server-side Python SDK for Vox-hosted WebRTC sessions.
This package is for backend applications that need to:
- create RTC sessions over HTTP
- attach to
/v1/socket - join
/rtc/{session_id} - send
session.update,response.*, andclient.event - observe RTC control events
It is intentionally narrow. It is not the general STT/TTS/text SDK.
Install
pip install vox-rtc-server pondsocket-client
The SDK uses the PondSocket Python client for the control-plane socket.
Until pondsocket-client is published, install it from your local checkout or git ref.
Authentication can be passed explicitly with api_key=... or through VOX_API_KEY.
Example
import asyncio
import os
from vox_rtc_server import (
ClientEventEnvelope,
SessionConfig,
VoxRtcServerClient,
)
async def main() -> None:
client = VoxRtcServerClient(
http_base="https://vox.example.com",
api_key=os.environ.get("VOX_API_KEY"),
)
bootstrap, session = await client.create_controlled_session()
print("session:", bootstrap.session_id)
session.on_event(lambda event: print(event.session_id, event.type, event.data))
session.configure(
SessionConfig(
stt_model="parakeet-stt-onnx:tdt-0.6b-v3",
tts_model="kokoro-tts-onnx:v1.0",
voice="af_heart",
turn_profile="browser_default",
vad_backend="silero",
turn_detector="livekit",
)
)
session.send_text_response("Hello from Python.")
session.send_client_event(
ClientEventEnvelope(
event="render.url",
payload={"url": "https://example.com"},
)
)
asyncio.run(main())
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vox_rtc_server-0.1.3.tar.gz.
File metadata
- Download URL: vox_rtc_server-0.1.3.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ec2c9e7553ccd99ce693710fe8054f9e130818248b46d28d797ef464b519e0a
|
|
| MD5 |
6b665e6d269cf37c72c0c90cc02aad0e
|
|
| BLAKE2b-256 |
93bf3368a90b534233fdc04b97bb471bf1ba6d329be574d1381b341da75f4187
|
File details
Details for the file vox_rtc_server-0.1.3-py3-none-any.whl.
File metadata
- Download URL: vox_rtc_server-0.1.3-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
19c07cb65cb13f6f021bb7e1c97759c80fc9234cdbf8275a021581f894f4b5fd
|
|
| MD5 |
10c61f4ed4354e7f608bae395c2bb5a5
|
|
| BLAKE2b-256 |
f51b6a78fa522ab97f3ee5b76d1bda3ac078f3d8ea40abb00db1db0bba234009
|