Call Detail Records (CDR) Module Documentation
Table of Contents
- Module Overview (Technical)
- Module Overview (Commercial/Business)
- Module Overview (End User/Administrator)
- CDR Fields Reference
- Filtering Options
- Common Scenarios & Examples
- Limitations & Important Notes
- Troubleshooting Tips
- Glossary
---
1. Module Overview (Technical)
What Are Call Detail Records?
Call Detail Records (CDR) is a call logging and reporting system that captures comprehensive information about every call processed by the PBX. It includes caller/destination info, timestamps, duration, quality metrics, and recording access.
Architecture
Key Tables
| Table | Purpose | |
|---|---|---|
public.cdr | Main call detail records | |
public.cdr_leg_a | A-leg (originator) details | |
public.cdr_leg_b | B-leg (destination) details |
Key Files
| File | Description | |
|---|---|---|
modules/callDetailRecords/CdrRecordsPage.tsx | Main CDR page | |
modules/callDetailRecords/components/ | UI components | |
modules/callDetailRecords/hooks/ | Data hooks |
2. Module Overview (Commercial/Business)
Business Value
CDR provides complete call visibility:
| Without CDR | With CDR | |
|---|---|---|
| No call history | Full audit trail | |
| Unknown call quality | QoS metrics | |
| Manual billing | Automatic logging | |
| No recordings | Integrated playback |
Use Cases
- Billing & Accounting
- Account code reporting
- Troubleshooting
- Analyze call quality
- Compliance
- Audit trail
- Analytics
- Peak hour analysis
Feature Highlights
| Feature | Benefit | |
|---|---|---|
| Date Filters | Historical queries | |
| Call Type Filter | In/Out/Internal | |
| Search | Find specific calls | |
| QoS Metrics | MOS, jitter, packet loss | |
| Recording Access | Play/download recordings | |
| Export | Generate reports |
3. Module Overview (End User/Administrator)
What Can You Do?
- View all call records
- Filter by date range
- Filter by call type
- Search by caller/destination
- Play call recordings
- Download recordings
- Analyze call quality
CDR Interface
Quick Tips
TIP
Quick Date Ranges: Use dropdown for Today, 7 Days, 15 Days, 30 Days.TIP
Recording Playback: Click the play icon to hear call recordings.CAUTION
Large Date Ranges: Limit to 30 days for performance.---
4. CDR Fields Reference
Call Information
| Field | Description | |
|---|---|---|
| UUID | Unique call identifier | |
| Caller Name | Caller ID name | |
| Caller Number | Caller phone/extension | |
| Destination | Called number | |
| Direction | Inbound/Outbound/Internal | |
| Context | FreeSWITCH context |
Timestamps
| Field | Description | |
|---|---|---|
| Start Time | Call initiated | |
| Answer Time | Call answered | |
| End Time | Call ended | |
| Duration | Total duration (seconds) | |
| Billable Seconds | Answered duration |
Technical Details
| Field | Description | |
|---|---|---|
| Hangup Cause | Call termination reason | |
| SIP Disposition | SIP status | |
| Gateway/Trunk | Gateway used | |
| Account Code | Billing code | |
| Authorization Code | Auth code used | |
| Read/Write Codec | Audio codecs |
Quality Metrics
| Field | Description | |
|---|---|---|
| MOS Score | Mean Opinion Score (1-5) | |
| Packet Loss (%) | Audio packet loss | |
| Jitter (ms) | Audio jitter | |
| Max Delay (ms) | Maximum delay | |
| PDD (ms) | Post-dial delay |
Recording
| Field | Description | |
|---|---|---|
| Recording File | Path to recording | |
| Play | In-browser playback | |
| Download | Download recording |
5. Filtering Options
Date Range
| Option | Description | |
|---|---|---|
| Today | Current day | |
| 7 Days | Last week | |
| 15 Days | Last 2 weeks | |
| 30 Days | Last month | |
| Custom | Select dates |
Call Type
| Type | Description | |
|---|---|---|
| All | All calls | |
| Inbound | Incoming calls | |
| Outbound | Outgoing calls | |
| Internal | Extension to extension | |
| Transit | Pass-through |
Search Fields
| Field | Description | |
|---|---|---|
| Caller | Partial match on caller | |
| Destination | Partial match on destination | |
| Saved Filters | Apply CDR Filter templates |
6. Common Scenarios & Examples
Scenario 1: View Today's Calls
- Select Today from range dropdown
- Click Apply Filters
- Browse results
Scenario 2: Find Failed Outbound
- Set Call Type to Outbound
- Look for calls with duration = 0
- Check hangup cause
Scenario 3: Listen to Recording
- Find call in list
- Click ▶️ play icon
- Recording plays in browser
Scenario 4: Analyze Call Quality
- View MOS Score column
- Check Packet Loss %
- Review Jitter values
Scenario 5: Export for Billing
- Set date range
- Apply filters
- Export to CSV
---
7. Limitations & Important Notes
Technical Notes
NOTE
Real-time: CDR records appear after call ends.NOTE
Recording Depends: Recording must be enabled for call.WARNING
Performance: Large date ranges may be slow.Data Retention
| Setting | Description | |
|---|---|---|
| CDR Retention | Configured per system | |
| Recording Retention | Separate storage policy |
Best Practices
- Limit Date Range: Use shortest needed range
- Use Filters: Narrow results before searching
- Save Filters: Create CDR Filters for common queries
- Regular Export: Archive important records
- Monitor Quality: Review MOS scores regularly
---
8. Troubleshooting Tips
Common Issues
| Symptom | Possible Cause | Solution | |
|---|---|---|---|
| No records | Wrong date range | Adjust dates | |
| Missing calls | Filter too restrictive | Clear filters | |
| Recording won't play | File deleted | Check retention | |
| Slow loading | Large date range | Reduce range | |
| Quality metrics N/A | Codec issue | Check RTP settings |
Diagnostic SQL
Recent CDR records: Call quality summary:---
9. Glossary
| Term | Definition | |
|---|---|---|
| CDR | Call Detail Record | |
| MOS | Mean Opinion Score (quality 1-5) | |
| Jitter | Variation in packet arrival time | |
| PDD | Post-Dial Delay | |
| Billsec | Billable seconds (answered time) | |
| Hangup Cause | Reason call ended | |
| A-Leg | Originating party | |
| B-Leg | Destination party |
Lua Script Status ℹ️
No Lua Handler Required
| Component | Status |
|---|---|
| Call Detail Records | ℹ️ Frontend reporting module - reads from CDR database |
---
Documentation last updated: January 2026