0

I wonder if there is a way to send the cdr data from kamailio server to an API endpoint.

I have a kamailio server with acc and dialog modules to produce cdr records.

I don't want to log the CDR in a database backend after the call terminates. I would rather prefer to send a POST request to local nodejs API that does the call rating logic using the http_async_client.

Is there a way to access the cdr data after the BYE transaction in the kamailio script ? I don't find the variable where the cdr data is stored.

Thank you

Anis Bedhiafi
  • 185
  • 1
  • 5
  • 22

1 Answers1

0

If you are using defualt config, I would try to send HTTP request when FLT_ACC* flag is set at least this would be my starting point.

os11k
  • 1,210
  • 2
  • 13
  • 26
  • I don't want to send individual Accounting Transactions to API. I want to send the final CDR. I even tried to query table acc_cdrs in event_route[dialog:end] by passing callid to retrieve cdr info and then send it over HTTP, but it seems that the event [dialog:end] is triggered before insertion in database – Anis Bedhiafi Oct 04 '20 at 11:43