Where alert rules live
Alert rules are configured on the Alerts screen in the admin section of the console. The screen body ships from the shared UI package, so the contact-centre console and the operator console render the same rule form and the same rule fields. The screen is part of the control-plane admin surface. Like every other control-plane call, it authenticates with a long-lived API key scoped to an org and a set of capabilities, and the control-plane API rejects a key that lacks the capability scope for the procedure it calls. See Authentication.Which signals you can alert on
There are three distinct sources, with different shapes. Live metrics. The gateway exposes a fixed, stable set of metric families on an OpenMetrics endpoint athttp://<gateway-host>:9091/metrics. These are
aggregates. They carry label values, not call identifiers.
Call Detail Records. When a call ends, the gateway pushes one CDR row to
ClickHouse. A CDR is per-call and carries
call_sid, so a rule that reads
CDRs can point at an individual call. The fields that alerting typically
reads:
Call events. The same fields reach your SDK live as a
CallEvent, with
the full set arriving on CHANNEL_HANGUP_COMPLETE. The data is identical to
the CDR; the CDR is the server-side persisted copy.
Any of the telemetry streams can be disabled in the gateway’s deployment
config. A rule that reads a stream you have opted out of will never fire.
Scoping a rule with labels
Scope comes from the label or column set of whichever signal the rule reads — there is no separate scoping dimension.tenant/tenant_idis available on nearly every signal. It is the primary scoping key and the one that correlates metrics with CDRs.trunk/trunk_idscopes a rule to a single carrier.directionisoutboundorinbound.result/statusseparates answered calls from failures, so a quality rule does not average over calls that never carried audio.codecis present ontelequick_rtp_packets_totaland on CDRs.shardis present only ontelequick_codec_engine_lag_us, andmethodonly ontelequick_admin_requests_total.
telephony_cdrs table is partitioned by month and indexed on
(tenant_id, timestamp_ms). Rules that read CDRs are cheapest when they pin
tenant_id and a bounded time range.
Choosing a threshold
The platform does not ship default thresholds — the number in a rule is yours. What the signal’s type dictates is the shape of the comparison:estimated_mos is an estimate derived from the E-Model R-factor, not a
measured opinion score. For the industry reference ranges that these metrics
are usually judged against — jitter, packet loss, MOS, PDD, ASR, ACD — see
Telephony Metrics. Those are published healthy ranges,
not platform-enforced limits.
Evaluation windows
The stream a rule reads bounds how tight its window can be.- Metrics are pulled by a Prometheus-style scrape. Resolution is bounded by your scrape interval, so a window shorter than that interval has nothing to evaluate.
- CDRs are written when the call ends. Anything computed from
duration_seconds,q850_cause,status, or the per-call quality columns is only visible after hangup. A CDR-backed rule cannot catch a problem mid-call. - Call events arrive live over the SDK connection, including the state
transitions that precede
CHANNEL_HANGUP_COMPLETE. Use these when the condition must be detected while the call is still up. - Traces are emitted per RPC over OTLP and cover RPC parse, JWT validation, trunk lookup, dialplan node execution, and SIP/RTP setup.
From a fired alert to the call sid
Whether a notification can name a call depends on the signal behind it.- CDR-backed: the row carries
call_siddirectly, plustenant_id,trunk_id,start_timestamp_ms,answer_timestamp_ms, andend_timestamp_ms. - Metric-backed: metric series carry no call identifier. Use the rule’s
label values and its evaluation window to query
telephony_cdrsfor the matching calls —tenant_idplus a time range hits the table’s index. - Traces: spans carry
call.sidwhen applicable, alongsidetenant.id,method.id,transport(quic/webtransport/webrtc/sip), andservice.name=telequick-gateway. Correlate with metrics on thetenantlabel. - Recording: the CDR’s
recording_urlis empty if the call was not recorded. - Failures with no call record: if a call fails before any
CallEventreaches the SDK, there is nothing to link to. Inspect the SIP exchange itself via HEPv3 capture to a Homer / heplify-server instance. HEPv3 doubles the SIP-side packet rate, so enable it only while debugging.
Related
- Voice observability overview — what data exists
- Telemetry — the four streams, metric names, CDR schema, HEPv3
- Telephony Metrics — definitions, formulas, published healthy ranges
- Authentication — API keys and capability scopes for control-plane admin calls