Skip to main content

Client lifecycle

KugelAudio is also a context manager, so resources are released automatically:
The async pre-connection methods are also exposed on the TTS resource as client.tts.connect_async() and client.tts.is_connected(). The synchronous connect() method exists, but synchronous generate() and stream() run on their own event-loop thread and do not reuse that socket. Use streaming_session_sync() when a synchronous application needs a persistent streaming connection.

Region Selection

Pin traffic to the direct EU endpoint when needed. See the EU endpoint guide for details.

Next steps