Vinix· docs

Contact Center Websockets

Real-time push events for Vinix Contact Center — queue, recipient, and session bindings. Subscribe to live state changes from a long-lived websocket client.

Vinix Contact Center publishes live events to clients over a websocket connection. Subscribe to per-account bindings to receive queue lifecycle events, recipient state transitions, and session events as they happen — without polling.

Connecting

Open a websocket connection to the platform's event gateway:

const ws = new WebSocket("ws://{SERVER}:5555");

In production, prefer the secure variant wss:// and the URL provided by Vinix for your deployment. Reach out to [email protected] for the current gateway hostname.

Subscribing to bindings

Once connected, send a JSON subscription message including your auth_token (from Authentication), your account_id, and the family of events you want:

{
  "action": "subscribe",
  "auth_token": "{AUTH_TOKEN}",
  "data": {
    "account_id": "{ACCOUNT_ID}",
    "binding": "qubicle.queue.{ACCOUNT_ID}.*"
  }
}

The three top-level binding families are:

  • qubicle.queue.{ACCOUNT_ID}.* — queue lifecycle + delivery
  • qubicle.recipient.{ACCOUNT_ID}.* — recipient state + session handling
  • qubicle.session.{ACCOUNT_ID}.{SESSION_ID} — session create / delete

Subscriptions can be narrowed by adding more path segments (a specific queue ID, recipient ID, or session ID).

Events arrive via the onmessage callback as JSON.

Queue events

Subscription: qubicle.queue.{ACCOUNT_ID}.*

EventFires when
qubicle.queue.{ACCOUNT_ID}.{QUEUE_ID}.createA queue has started running
qubicle.queue.{ACCOUNT_ID}.{QUEUE_ID}.deleteA queue is no longer running
qubicle.queue.{ACCOUNT_ID}.{QUEUE_ID}.joinA caller enters a queue — includes position and estimated wait
qubicle.queue.{ACCOUNT_ID}.{QUEUE_ID}.leaveA caller exits a queue — includes reason and total wait duration
qubicle.queue.{ACCOUNT_ID}.{QUEUE_ID}.deliveredA call is routed to a recipient — includes recipient ID and wait metrics

Recipient events

Subscription: qubicle.recipient.{ACCOUNT_ID}.*

EventFires when
create (login)Recipient logs into Contact Center
delete (logout)Recipient logs out
readyRecipient becomes available to receive queue sessions
awayRecipient enters away state, ineligible for delivery
pauseRecipient pauses delivery from a specific queue
resumeRecipient resumes delivery from a specific queue
wrapup_startPost-call wrap-up window begins after handling a session
wrapup_completePost-call wrap-up window ends
offerA session is being presented to the recipient
rejectRecipient declines an offered call
rescindOffered session is withdrawn (e.g. caller hung up)
deliveredSession successfully routed; recipient is handling it
hangupThe handled session disconnects
external_call_startRecipient initiates a non-queue call
external_call_endRecipient ends a non-queue call
syncPeriodic state synchronization for client consistency
wiretap_startSupervisor monitoring connection initiated
wiretap_stopSupervisor monitoring connection terminated
wiretap_failedMonitoring attempt was unsuccessful
interaction_finalize_startDisposition / notes update window opens
interaction_finalize_endDisposition / notes update window closes

Each event arrives with the full binding name as the event identifier; the format is qubicle.recipient.{ACCOUNT_ID}.{RECIPIENT_ID}.<event>.

Session events

Subscription: qubicle.session.{ACCOUNT_ID}.*

EventFires when
qubicle.session.{ACCOUNT_ID}.{SESSION_ID}.createA new call session is established — payload includes caller identification and session metadata
qubicle.session.{ACCOUNT_ID}.{SESSION_ID}.deleteA session terminates — payload includes a disconnection reason code

All event payloads include standardized timestamp fields for correlation across the queue, recipient, and session feeds.

On this page