Sticky agent in Call flow designer

Status
Not open for further replies.

AshishKushwaha

Gold Partner
Basic Certified
Joined
Apr 29, 2024
Messages
63
Reaction score
10
I am looking for documentation on creating a sticky agent using the 3CX Call Flow Designer. I have followed some steps found online and have also tried using ChatGPT, but I am still unable to create it. Can anyone assist me with this?
 
If you are looking for someone to develop a solution for you, we can help.
 
We built this often if you need assistance.
 
This is not an easy task if you're new with the CFD. You will need to query the 3CX CDRs to get the last extension that was connected to the caller's number, and that's not an easy task. So hiring a 3rd party to do this for you might be a good idea.
 
This is not an easy task if you're new with the CFD. You will need to query the 3CX CDRs to get the last extension that was connected to the caller's number, and that's not an easy task. So hiring a 3rd party to do this for you might be a good idea.
You can also use the CRM integration with some tricks to grab the last agent they talked to (like a contact property.)
 
You can also use the CRM integration with some tricks to grab the last agent they talked to (like a contact property.)
Yes, assuming you have a CRM integration in place, that could be an option, querying the CRM using a REST API might be easier.
 
  • Like
Reactions: Evolute IT
You can also use the CRM integration with some tricks to grab the last agent they talked to (like a contact property.)
Yes, I understand, but I still don't know how to start. If you have any documentation, could you provide it? Alternatively, if you could guide me on how to create it, I would greatly appreciate it.
 
Yes, I understand, but I still don't know how to start. If you have any documentation, could you provide it? Alternatively, if you could guide me on how to create it, I would greatly appreciate it.
First, you need to understand from where you will get this information. If you will query your CRM, then you need to check their REST API, and understand what you need to invoke in order to get the information. You can start playing with Postman, executing HTTP requests until you're sure what you need to do. Then, you can use the Web Service REST component from a CFD app to execute it in the context of an incoming call. This will need to be combined with the JSON / XML Parser component, because you will need to parse the JSON response returned by the REST API of your CRM.

If you instead need to read the CDRs generated by 3CX, you will need to use the Read / Write to File component to read the file. Then you will need to run a C# script to analyze it and get the information you need.

If you're new to the CFD, you should start by the basics, play with simple examples and watch video tutorials, before working on such a complex project. If this is overwhelming, you should hire a 3CX partner to develop this for you, like @ConceptsWeb or @VoIPTools.
 
Yes, I understand, but I still don't know how to start. If you have any documentation, could you provide it? Alternatively, if you could guide me on how to create it, I would greatly appreciate it.
It's too complex to just explain, but @edossantos_sipcaller did a great job at it. Otherwise, we could build it for you, but not for free obviously.
 
Here is one approach:
  1. Configure 3CX to create CDR files. I would recommend one file per phone call. The CDR file contains caller information (phone number) and a list of all the extensions that touched the call.

  2. In a separate automated service you develop, parse the CDR files and place the data into a database. (Consider using a filesystemwatcher). Keep in mind that you are not permitted to install a DBMS on the 3CX server so you will either need to provide remote access to the database from the 3CX server, or use a file-based database to store the data.

  3. Create a Call Flow Designer that:
    1. Captures the number of the person calling
    2. Looks up this number in the CDR database
    3. Confirms that the previous call took place recently (not a year ago)
    4. Checks whether the agent that took the previous call is available (Available, not on a phone call, is logged in to the queue, and phone is registered)
    5. Decides whether to route the call to the previous agent, or send to a default extension if the agent is not available
  4. Route inbound calls to the CFD.

  5. Periodically purge old records from the database to keep look-ups fast
Unfortunately, this is not a simple project. You will have to decide whether you have to skills needed to do all of these steps.
 
@VoIPTools
How to about deleting file-based database every night.. through cron job

which file-based database would you recommend for this must has to be lightweight and can be used on the 3CX host itself, fast as it will only store 1 day data only.
 
I have used both SQLite and LiteDB. Your needs are very simple so LiteDB is probably the lightest option. But SQLite has a lot more history and much more widely used.
 
Status
Not open for further replies.

Forum statistics

Threads
111,974
Messages
590,081
Members
164,899
Latest member
mazet