3CX. SMDR/CDR data format and connection settings
This data is being extracted with help of the "Advanced PBX Data Logger" software only. It may not applicable for other software titles.
Enable CDR
To enable CDR, access the 3CX Management console. Go to "Settings > CDR", choose "Generate CDR". Select the "Active Socket" output type.

Configuring the CDR fields
Our software is configured for the following STRUCTURE and the position of the CDR data
historyid
callid
duration
time-start
time-answered
time-end
reason-terminated
from-no
to-no
from-dn
to-dn
dial-no
reason-changed
final-number
final-dn
bill-code
bill-rate
bill-cost
bill-name
chain
from-type
to-type
final-type
from-dispname
to-dispname
final-dispname
More info about the CDR format and settings you may find here.
Configuring Advanced PBX Data Logger as a TCP server
Advanced PBX Data Logger should be configured to the TCP server mode and listen on 0.0.0.0:2002 (see below). The IP address 0.0.0.0 allows receiving data from all network connections on your computer. The port number should match the value from the SMDR settings in your 3CX.
1. Add a new configuration with the TCP data source (if you didn't it before).

2. Configure the TCP settings as shown below.
Selecting the correct parser for 3CX
Data items
Description | Data type | Column name |
Record No | string | FLAG4 |
Call ID | string | FLAG1 |
Call duration | datetime | CALL_DURATION |
Call duration (s) | integer | CALL_DURATION_S |
Call time | datetime | CALL_TIME |
Ring | datetime | RING |
Terminated | string | FLAG5 |
Call type | string | DIRECTION |
Extension | string | EXT |
Trunk | string | TRUNK |
Called phone | string | CALLER_PHONE |
Extension name | string | EXT_NAME |
Dialed phone | string | DIALED_PHONE |
Call charge | float | COST |
Caller name | string | FLAG2 |
Change reason | string | FLAG6 |
Chain (full) | string | CHAIN |
Chain | string | FLAG3 |
Display name (from) | string | DISPNAME_FROM |
Display name (to) | string | DISPNAME_TO |
Display name (final) | string | DISPNAME_FINAL |
Missed queue calls | string | MISSED_QUEUE |
Interested in reports for PBX usage?
We offer the PBX Reports utility with various manual, scheduled and email reports, built-in web-server, and other features. Look here
Want PBX call logs in a database?
This is the standard feature. The logger captures exports SMDR or CDR data in real-time to your database. Follow this link
Note: Products and companies mentioned here are used only for definition and identification purposes and can be trademarks and/or registered trademarks of the respective companies.