Is this situation possible?

Andi335

Bronze Partner
Joined
Feb 12, 2025
Messages
1
Reaction score
0
I have the following situation in 3cx: there is a single phone number and 5 extensions: 102,103,104,105,106. when 105 calls a phone number and that person doesn't answer, if he calls back on that single phone number (0123456789 for instance) it should redirect the call to extension 105. How can i make this work?
 
This is possible with an CFA.
 
Yes, a CFD app can route inbound calls according to this. The app would have to read the CDRs, and determine if there was a recent outbound call to that number, and then route the call to the extension that did it.
 
Yes, a CFD app can route inbound calls according to this. The app would have to read the CDRs, and determine if there was a recent outbound call to that number, and then route the call to the extension that did it.
Or use a CRM to store and retrieve the information.
 
I want to set expectations about the complexity of this task. I'm not in the habit of critiquing one of the smartest programmers I know, however, while @edossantos_sipcaller offers a valid solution, querying the CDR records directly is not at all straightforward.

First, you would need to get a list of CDR files, open each file one at a time, parse the data, evaluate the call chain field (list of extensions that touched the call) and repeat for every CDR file (if CDR is configured for one file per call). This also suggests that you cannot delete any CDR files for a specified amount of time (how far back in history you want to go). This approach is complex and would require time and resources for every single call.

The suggestion by @ConceptsWeb has the potential to be more efficient given that the data is collected automatically and saved in a database as each call takes place, however, this means your CFD application needs to know how to authenticate to the CRM and GET the required data. Perhaps the "CRM" is just a simple database with the necessary APIs? This entire solution is also complicated.

The third approach is perhaps the most complex solution -- subscribe to the 3CX real-time call events and save the data yourself in a database and then have the CFD query this database..

While the three of us are capable programmers (@edossantos_sipcaller, @ConceptsWeb, and @VoIPTools), we have to recognize that none of the above options are out-of-the-box solutions. All the proposed solutions require a fairly capable programmer and are not something most 3CX Admins can do, let alone a typical 3CX customer.
 
Our CRM solution isn't as complex as it sounds.

Like, not at all.

We've done way more complicated than that lol
 

Forum statistics

Threads
111,872
Messages
589,493
Members
164,718
Latest member
appservices@bergmanbrothe