Voice Stream ControlCopyCommands that can be executed on an ongoing stream.Connection Flow DiagramCustomer WebSocket ServerSinch PlatformCustomer WebSocket ServerSinch PlatformWebSocket ConnectionStream endedalt[WS accepted][WS rejected]Session StartFirst protocol message.Server decides to accept,reject, or signal busy.Stream endedStream endedalt[Accepted][Busy][Rejected]Bidirectional Audio StreamingPlatform to Server AudioRecommended: 20ms frames.8 kHz = 320 bytes/frame,16 kHz = 640 bytes/frame.Server to Platform AudioQueued in playback buffer.Max buffer: 5 MB per call.Stream Control (Server to Platform)Discards buffered audionot yet played to caller.Prevents 1-minuteno-audio timeout.alt[Flush unplayed audio (e.g.interrupt)][Keep-alive during silence]loop[While call is active]Call EndNo reconnection mechanism.Connection loss = call hung up.Stream endedStream endedalt[Customer closes connection][Sinch ends call]WS connect requestAccept connectionNon-success responseConnectRequest{command: connect}ConnectResponse{command: answer}ConnectResponse{command: busy}ConnectResponse{command: reject}[binary] AudioFrame(16-bit signed PCM, mono, little-endian)[binary] AudioFrame(16-bit signed PCM, mono, little-endian)StreamControl{command: clear}StreamControl{command: heartbeat}WebSocket closeWebSocket closeVoice Stream WebSocket Flow (Sinch Platform - Customer WebSocket Server)Customer WebSocket ServerSinch PlatformCustomer WebSocket ServerSinch PlatformWebSocket ConnectionStream endedalt[WS accepted][WS rejected]Session StartFirst protocol message.Server decides to accept,reject, or signal busy.Stream endedStream endedalt[Accepted][Busy][Rejected]Bidirectional Audio StreamingPlatform to Server AudioRecommended: 20ms frames.8 kHz = 320 bytes/frame,16 kHz = 640 bytes/frame.Server to Platform AudioQueued in playback buffer.Max buffer: 5 MB per call.Stream Control (Server to Platform)Discards buffered audionot yet played to caller.Prevents 1-minuteno-audio timeout.alt[Flush unplayed audio (e.g.interrupt)][Keep-alive during silence]loop[While call is active]Call EndNo reconnection mechanism.Connection loss = call hung up.Stream endedStream endedalt[Customer closes connection][Sinch ends call]WS connect requestAccept connectionNon-success responseConnectRequest{command: connect}ConnectResponse{command: answer}ConnectResponse{command: busy}ConnectResponse{command: reject}[binary] AudioFrame(16-bit signed PCM, mono, little-endian)[binary] AudioFrame(16-bit signed PCM, mono, little-endian)StreamControl{command: clear}StreamControl{command: heartbeat}WebSocket closeWebSocket closeVoice Stream WebSocket Flow (Sinch Platform - Customer WebSocket Server)