CDR queries

I know that manager (AMI) notify events from CDR, but i don’t know how to read directly data from it (as the GetConfig API to read a config content file).

How can I perform queries on CDR ?


I may be mistaken, but I don’t believe AMI reads CDR.

[quote]The Asterisk Manager Interface (AMI) allows a client program to connect to an Asterisk instance and issue commands or read events over a TCP/IP stream. Integrators will find this particularly useful when trying to track the state of a telephony client inside Asterisk, and directing that client based on custom (and possibly dynamic) rules.

CDR is Call Detail Records…and those are logged in /var/log/asterisk/cdr-csv directory. Provided you have it enabled in the cdr.conf file. Or you could have them going to a database.