ping_pong

View as Markdown

Direction: both ways. Dial sends a ping_pong to your server roughly every 2 seconds; echo the same frame straight back. If Dial doesn’t receive a pong within ~5 seconds it treats the link as dead, closes it, and reconnects — at which point you get a fresh call_connected with reconnect: true and resume streaming.

This is an application-level keepalive on top of the WebSocket — the same frame as in the LLM protocol. Note that a steady inbound media stream does not replace it: only an echoed ping_pong counts as proof the link is alive both ways.

Schema

FieldTypeDescription
typestringAlways "ping_pong".
timestampintegerMilliseconds since epoch (for round‑trip timing). Echo it back unchanged.

Example

Dial → your server:

1{ "type": "ping_pong", "timestamp": 1749480000000 }

Echo it straight back, your server → Dial:

1{ "type": "ping_pong", "timestamp": 1749480000000 }