ExoVoIPDeveloper guide

Real-time

Real-time phone system status: active calls, extensions and connected phones, trunks, queues, call parking and service status. Available through REST requests (status snapshot) and SSE or WebSocket events (updates). Scope live:read.

Status snapshot

curl -s https://centralino.exovoip.it/api/v1/live/snapshot -H "X-API-Key: $EXOPBX_API_KEY"
curl -s https://centralino.exovoip.it/api/v1/live/extensions -H "X-API-Key: $EXOPBX_API_KEY"
EndpointContent
GET /v1/live/snapshotEverything in one call: calls, extensions, trunks, queues, parking, health
GET /v1/live/channelsActive calls
GET /v1/live/extensionsExtensions: status, registration, availability, Do Not Disturb, devices
GET /v1/live/devicesOne item per registered phone (IP, user agent, latency, reachability)
GET /v1/live/trunksTrunks: registration, reachability, active calls
GET /v1/live/queuesQueues: waiting callers, longest wait, agents
GET /v1/live/healthService status: operational, degraded, outage

Extension availability (availability): available, ringing, busy, on_hold, dnd, unreachable (registered but not responding), offline (no phone registered).

Events (SSE)

GET /v1/live/events keeps the connection open and sends an event for every change. On connection you receive a full snapshot, then only changes; a heartbeat every 15 seconds. With ?types= you receive only the listed types (snapshot and heartbeat are always sent).

# -N disattiva il buffer: gli eventi arrivano appena accadono
curl -N "https://centralino.exovoip.it/api/v1/live/events?types=channel.update,channel.hangup,calendar.override" \
  -H "X-API-Key: $EXOPBX_API_KEY"

The SDKs reconnect automatically with increasing delays and receive a new snapshot after each reconnection: use it as the reference state instead of accumulating changes. An invalid key, or one without permissions, ends the stream without retries.

Events (WebSocket)

GET /v1/live/ws sends the same events, one per JSON message. SSE remains the recommended channel; WebSocket is useful in environments that prefer it.

# WebSocket: stessi eventi dell'SSE, un evento JSON per messaggio
websocat -H "X-API-Key: $EXOPBX_API_KEY" "wss://centralino.exovoip.it/api/v1/live/ws?types=extension.state"

In the browser, WebSocket and EventSource cannot send headers: they work with the control panel session. API keys must be used server-side only.

Event types

TypeWhen
snapshotConnection or resynchronization
channel.updateNew call, state change, answer, hold, recording, bridging
channel.hangupEnd of a call (cause, duration)
extension.stateAny extension state change
extension.registrationFirst phone registered / last one disconnected
extension.contactPhone added, removed, reachable or unreachable
trunk.stateTrunk registration, reachability or active calls
queue.caller.join / queue.caller.leaveCaller enters / leaves the queue (answered, abandoned, exited)
queue.memberAgent status or pause
parking.updateCall parked, retrieved, timed out or abandoned
calendar.overrideBusiness hours override (control panel, API, phone, expiry)
system.statusService status change
heartbeatEvery 15 seconds

Platform only: system.asterisk, system.service, system.reload.

Example event:

{
  "type": "calendar.override",
  "tenantId": 3,
  "calendarId": 4,
  "name": "Ufficio",
  "forceState": "closed",
  "forceUntil": "2026-11-04T12:00:00.000Z",
  "previousForceState": "auto",
  "state": "closed"
}

The full schema of each event (fields and values) is in the Swagger reference, under GET /v1/live/events.

Global view

For a global key without X-Tenant-Id (or ?tenantId=), events and snapshots cover all tenants; each object includes its tenantId.

Endpoints

RequestScopeSDK method
GET /v1/live/snapshotlive:readlive.snapshot()
GET /v1/live/channelslive:readlive.channels()
GET /v1/live/extensionslive:readlive.extensions()
GET /v1/live/deviceslive:readlive.devices()
GET /v1/live/trunkslive:readlive.trunks()
GET /v1/live/queueslive:readlive.queues()
GET /v1/live/healthlive:readlive.health()
GET /v1/live/eventslive:readlive.stream()
GET /v1/live/wslive:readlive.websocket() (TS)