FreePBX | Register | Issues | Wiki | Portal | Support

How to log button pressed in ivr response to CEL

asterisk
Tags: #<Tag:0x00007fcd23f89178>

(Dick Vandenberg) #1

We have 13 stores, each has its own DID and IVR. The IVRs all play the same options. Is there a way to log the IVR option (button) selected so that it can be easily queried using a MySql query?

Right now, our approach is to direct each button press to an exten that is unique to each store then drop the call into a queue for that store. At this point, we are not routing the calls to different places, we just want to capture the key presses for analysis.

So pressing 1 at store 5 goes to 50001 and pressing 2 at store 12 goes to 12002. This is a pain to parse in SQL.


(Dave Burgess) #2

Why is that a pain? You can select by modulus or substrings (for the button presses) and substrings (for the stores). It seems dead simple to me.


(Dick Vandenberg) #3

@cynjut Thanks, that is what I’m doing now (substrings) but is prone to error if another, unrelated exten ends in 1 or 2. I’d prefer to build on something that I can be sure won’t be subject to that type of misinterpretation.


#4

https://dev.mysql.com/doc/refman/8.0/en/regexp.html


(Tom Ray) #5

This is what the userfield is for in the CDRs. It tracks the DTMF entry the caller used.