Skip to main content

WebRTC Call Reports

The Telnyx Android SDK automatically collects detailed call statistics during WebRTC calls and sends them to Telnyx for troubleshooting and monitoring purposes. This feature helps diagnose call quality issues, connection problems, and provides insights into call performance.

Overview

When enabled, the SDK collects:
  • Call summary: Call identifiers, timestamps, duration, and device information
  • Connection metrics: ICE states, DTLS states, signaling transitions
  • Media statistics: Packet loss, jitter, round-trip time, audio levels
  • Network information: Selected ICE candidates, transport details
The data is automatically uploaded to Telnyx when a call ends, and can also be accessed locally for debugging.

Enabling Call Reports

Call reports are automatically enabled when you connect to the Telnyx WebRTC service. The SDK handles data collection and upload transparently.
Call reports are sent automatically when a call ends. No additional configuration is required.

Accessing Local Call Reports

For debugging purposes, you can access the call report JSON file that is saved locally after each call:
Call stats files are saved to: <cache_dir>/call_stats/call_stats_<callId>.json

Call Report JSON Structure

The call report JSON contains the following sections:

Top-Level Identifiers

Summary Section

Contains high-level call information:

Stats Array

Contains interval-based statistics captured during the call. Each interval (typically 5 seconds) includes:

Android Extra Section

Contains Android-specific debugging information:

Metrics Reference

Audio Inbound Metrics

Audio Outbound Metrics

Connection Metrics

Troubleshooting with Call Reports

Call reports can help diagnose common issues:

High Packet Loss

Look at packetsLost in the audio inbound stats. Values above 1-2% may indicate network issues.

Audio Quality Issues

Check jitterAvg and concealmentEvents. High jitter (>30ms) or frequent concealment events indicate audio quality degradation.

Connection Failures

Review the connectionTimeline in android_extra. Look for:
  • ICE_FAILED - Network connectivity issues
  • DTLS_FAILED - TLS/security handshake failures
  • Long gaps between ICE_CONNECTED and DTLS_CONNECTED (>5 seconds)

One-Way Audio

Check if:
  • packetsReceived is 0 (not receiving audio)
  • audioLevelAvg is 0 (microphone not capturing)
  • Review microphone permissions in deviceInfo.permissions

Privacy & Data Handling

Call reports are sent securely to Telnyx and are used solely for:
  • Troubleshooting call quality issues
  • Monitoring service health
  • Improving SDK performance
Call reports do not include actual audio content or personally identifiable information beyond call metadata.

See Also