What can be obtained from the integration of 1C: CRM 8 and Asterisk telephony


    For over a year we have been closely developing solutions for integrating telephony based on Asterisk and 1C programs. First of all, we experience decisions on ourselves, and I want to share experience on what can be gained from such integration.

    We use a terminal circuit for working with 1C: CRM. On each employee’s desk is an IP phone that is connected via a local area network to Askozia IP ATC , deployed with a terminal 1C server inside the VMware infrastructure in the nearest data center.

    Click to call




    The first thing we did was organize a dialing from 1C by sending a direct command to Asterisk with the internal number of the employee and the external number of the client. It looks very simple, the employee presses the phone number in the 1C: CRM database in the terminal session, the phone rings on the table, pick up the phone, the call went to the client. Conveniently, simply, implemented in 15 minutes, saved a lot of time for managers.
    Technically, it was an FTP connection and creating a call file with information about who should call whom. Later reworked using components for 1C.

    Display customer name for incoming call


    It is very convenient for an incoming call to see the name of the client’s company on the IP phone, rather than a bare number. To do this, we used an AGI script that, when an incoming call is made, calls to the 1C: Enterprise 8 server and from the 1C: CRM database takes the client’s name, transliterates it and inserts it into the Caller ID field. Implementation details in my last post . This is a very convenient feature, the call history on Asterisk literally spoke, instead of bare numbers - the names of customers.


    Customer card with an incoming call




    In order to get a client card for an incoming call, you need to make sure that during the call the Asterisk server pulls 1C: Enterprise in some way, and even the client session of the user whose phone is currently ringing.
    One of the most difficult tasks for us was to develop a client component for connecting 1C and Asterisk, which I wrote about in this post .
    To implement this function, we used the AJAM interface. Asterisk is a command interface that allows you to manage the telephone exchange and receive feedback from it.
    Based on this component, a 1C telephony panel was implemented, which is launched together with a 1C: CRM session for each user and interacts with Asterisk during a call.
    As a result, with an incoming call, we display information about the client, open the event document, which managers add to during the conversation. And in the hidden field of the Event document we record a unique call identifier, but more on that later :)

    Call History in 1C


    Creating events for incoming calls is a good practice when using CRM systems, but it is not always possible to do this promptly, and not all managers “like” to hammer calls in CRM, unless they are paid for the number of events :). We organized a small PHP script on the Asterisk side, which sends out CDR recordings in portions, and the 1C: Enterprise 8 server picks up the records as a routine and enters them into the information register, thus creating an identical copy of the Asterisk CDR database in 1C.


    Each table entry contains a unique call identifier, and we now know for sure whether the manager created an event for a specific call or not, but that’s not all ...

    Total recording of conversations and listening to them


    Asterisk has an excellent function for recording conversations, but without integration with the CRM system, it is a simple set of sound files, thousands of files, millions of useless unstructured files.


    Yes, they can be put into daddies, but to find all the calls of one client, especially if you called from different numbers, you can only use the integration with the CRM system.
    A small modification of dialplan asterisk, and in one of the CDR fields we store the name of the conversation recording file. As a result, inside 1C: Enterprise we get a call history table with links to the call recording and unique call identifiers, the same as those stored in the Event document that opened at the beginning of calls.


    This is a good tool for a manager and his supervisor.
    The manager can gradually enter information into the CRM system about customer requests, listening to the records of his conversations directly from the event document. The head can check whether all calls are processed by managers and whether a document is created for each call. Naturally, he can also listen to any conversation subordinate.
    On the other hand, in each client’s card you can make a bookmark in which conversations with the employees of this client will accumulate with the ability to quickly find and listen to the desired conversation. It is convenient and allows you to instantly find solutions to conflict situations. To be honest, we never used the recording of a conversation to resolve the conflict, but after mentioning the fact of the recording in the conversation with the conflicting party, further analysis of the situation goes much softer, regardless of whether the client was right :)

    Caller City Display




    We remember several city codes as a keepsake, but when calls started to arrive from different parts of the country, the idea came up to display the name of the city with an incoming call so that managers would adequately respond to questions about whether we could come and demonstrate our product in the city of Khabarovsk :)
    Implementation not complicated. From the site of Rossvyaz, they took the correspondence of numbers and cities, drove them into the information register, with an incoming call we determine the city and display it in the telephony panel.

    Caller company display on the map




    We know the city, we connect the Yandex map and through the API in 1C with an incoming call we display graphically the location of the client. If it is already in the database, then display right down to the street and the house. Convenient, but there are some nuances, the idea needs refinement.

    Display an arbitrary 1C report at the time of the call




    Even before picking up the handset, you can display a report on the counterparty, for example, a report on the history of settlements or show open customer orders, purchase history. For example, it is convenient for our accountant to see a list of documents that have not been returned, and the sales manager - for a list of unpaid bills.

    One-click faxing




    I hate faxes, but it happens that a client asks to send him a fax with a seal. How to do it from an integrated system? Not just, but quite possible. Asterisk can send faxes to the current conversation using the TIFF graphic format. 1C can form a printed form of a document with printing and save it in PDF format. Well, during the conversation we open the invoice document, click the send fax button, 1C saves the form in PDF format and sends it to the Asterisk server, simultaneously transferring the call to the fax sending service channel, informing Asterisk about the current conversation and the name of the sent PDF file. Asterisk starts the script to convert PDF to TIFF, then sends the TIFF file to the current conversation, and at the end of the transfer sends a message about the delivery result to 1C.

    Statistical processing of CDR by means of 1C data composition system


    Having accumulated a sufficiently large base of calls for a year of work, we tried to use the powerful analytical module of the 1C system to plot charts based on the CDR table loaded in 1C: Enterprise 8. Here is an example of a couple of reports that we got:

    Call statistics by day of the week:


    Call Distribution by Clock:


    Analysis of the use of outgoing channels:


    Smart call routing




    In 1M CRM system there is a specialized field that allows you to assign a client to a specific manager. This mechanism can be used for smart routing. How it works? At the start of the 1C: CRM system, it forms a list of its customers, or rather, the numbers of "their" customers and keeps them in memory. Each user of the system has its own list. With an incoming call, when a client dials a multi-channel number and prepares to hear a voice menu greeting (IVR), the telephony panel of each employee checks his list with the number of the caller, and if the number matches, he intercepts the call. It turns out that the call transfer only works if the telephony panel and the 1C session are active. If 1C is closed, then the user is not in place, therefore he is working on a standard route with a secretary and departments.
    For the client, this looks like an interesting way: he calls the common multi-channel number and immediately connects to the right employee, IVR does not even have time to utter the first sounds of greeting.

    Function to eavesdrop on a conversation and whisper to a colleague


    We spied on this idea with Switchvox.

    Asterisk has a great “supervisor” feature.


    How it works?
    The customer calls and gets to a newcomer who talks about our products, answers customer questions. As the head of the department, the topic of the conversation becomes interesting to me, and in one click I connect to the conversation in listener mode, the client asks about the price or discount that we are ready to offer, one click and I turn on the whisper mode, I tell my colleague: “10% if will buy for 100,000 rubles. " After which the newcomer, without interrupting the conversation, continues to discuss a deal with the client, taking into account my remark, which he only heard. If necessary, I can intervene in the conversation and organize a tripartite conference with a few clicks in the list of employees.

    Status management, call transfer from 1C


    On expensive IP phones, there is a BLF function that allows you to display the status of the IP phone of another employee. The color of the light bulb immediately clearly speaks, busy or free colleague.


    Since our 1C: CRM system is connected to Asterisk, we receive status information directly in 1C and can display it on the screen, as well as change the logic of the panel depending on the state.


    For example, if you click on an employee who is currently free, then a simple call to that employee will occur. If the employee is currently communicating with someone, the panel will offer to join the conversation or eavesdrop on him.
    Call transfer can also be intelligent and can take state into account. For example, I received a call from a client and want to transfer it to a colleague, I again click on an employee in the list, an advisory transfer is made to him, if I receive a second call during a conversation with a client , I again click on a colleague and the call is transferred without consulting . It is convenient and easy enough to understand. No bars or sprockets.
    It is planned to organize status management according to the work schedule, and depending on this, change the call route to a substitute colleague automatically.

    Conclusion


    There are many ideas, if I missed something, suggest, it will be interesting to discuss and implement.
    You can read more about our integration project 1C and Asterisk on the project website .

    Also popular now: