Knowledge Base > Comnica Contact Center > Developer and general information > API documentation
Support
contact
Content
Comnica Contact Center
System updates
Comnica SmartSMS
Mass SmartSMS
API documentation

Multiple clients has requested the development or access to API interface to solve different problems. However, this type of interface does not exist as of yet. So to have interim solution, we would allow access for these companies to use our interface between the backend and frontend of Comnica. The companies would have to accept these terms of use:

  • This is not a solution for a classic API, this interface was not created to function as a public interface for any programs to use.
  • We do not have extensive documentation for this interface.
  • There is no version schema for this interface, and it could change at any time without any notice, however we would like to be proactive in giving notice beforehand to the companies using the interface.
  • Development of the interface is not a priority. Therefore requests are not accepted for this interface.

We have created this manual for the companies who accept these terms and whom would like start to use it.  This manual summarizes how to access different requested services using this API solution.

General information for usage

The interface communicates over HTTPS in JSON messages. Essentially we use POST requests. Requestable endpoints can be found under the domain of the company in their directory:  https://companyname.comnica.cc/api

Format of the payload

Generally speaking, every backend endpoint expects the following JSON format:

{
    "rq_sent":"2019-10-07 09:37:49.700+0000"/* A request elküldésének timestampje a kliens szerint */
    "payload":{}                             /* A tényleges kérés */
}

Henceforth when detailing requests, we would only describe the format of the payload. In case the payload is empty, then the requester needs to the send an empty JSON object (“{}”)

General response format

{
    "res_sent":"2019-10-07 09:37:49.971653+0000"/* A szerver szerint a válasz kiküldésének timestampje */
    "rq_rcvd""2019-10-07 09:37:49.926506+0000"/* A szerver ekkor kapta meg a kérést */
    "payload":{}                                  /* A tényleges válasz */
}

Every response given to a successful request get a HTTP: 200 statuscode in the format above.

Henceforth when detailing responses, we would only describe the format of the payload. In case the payload is empty, then the requester needs to the send an empty JSON object (“{}”)

Errors

400 Bad Request

The reponse is in the format of a JSON and it is packaged in a wrapper already discussed at the description of the general reponse. The payload has the following format:

{
    "errors": [
        {
            "code""BAD_DATA",
            "parameters": {
                "username""Foo"
            },
            "field_name"null,
            "global"true
        },
        {
            "code""ALREADY_EXISTS",
            "parameters": {
                "thing""Teszt Projekt"
            },
            "field_name": name,
            "global"false
        }
    ]
}

The errors array contains the description of the error. The actual error could relate to a defined field of the request (in this case, global=false and field_name key points to the field which caused the error or it could be general as well, (in which case global =true and field_name is missing). The code key contains the actual error code. The possible list of error codes depends on the type of request.

401 Authentication required

The response exceptionally a simple text (“Authorization required”).

This reponse is given if the username or the password is invalid or the token is expired.

403 Permission denied

The response is JSON and it does not contain the regular wrapper for responses.

This response is given if the username/password or token is valid, but the user has no authorisation for the requested operation.

404 Resource not found

The response is JSON and it does not include the general wrapper.

This is the error message, if a not existing endpoint is requested. It is important to note, the the method of the request has to be correct as well. So if we define an endpoint as POST however if we request it as GET we would get this error message as well.

Signing in

Before the start of every session, it it mandatory for a session to request a session token. For a session token, a pair of valid username and password with HTTP Basic authentication should be given.

The sesseiontoken is valid for 4 hours, and the 4 hours restart with every succesfull request. The request sent with an expired token generate a reponse with an error code 401. In this case a new session token needs to be requested.

Request & Response

Request

/new_session

Request payload empty.

Response

{
    "user_id":31,
    "permissions": [
        "login",
        "change_password",
        ...
    ],
    "session_key":"XXXYYYZZZ",
    "is_support":false,
    "name":"Some User",
    "is_admin":false,
    "username":"somebody"
}

From this package the session key is relevant, the rest is only used by the frontend of admin page.

For every other request an HTTP Basic authentication has to be made with a “session username” and “session_key” given in the response above. 

General list queries

Part of the endpoints could be used to  request entities (e.g. records, worklog entries) in a table like lists with parameterizable columns and filters. The format of such requests are based on same scheme, the authorized list of columns and and filters are dependent on the goal of the actual request.

Typically, for every listing enpoint has a exporting endpoint counterpart, which (apart from a couple differences listed below) uses the same request convetion. The convention is that if the listing endpoint’s name is /foo/list, which gives a JSON response, than there is also a /foo/export which offers the same list as a downloadable option in the format of XLS or CVS.

Request

The payload is required to have two arrays which are named columns and filters. The columns shows the list of the required columns (the presentable arguments), and filters includes the filters to be applied on the data.  Typically, every columns could have a filter, but the list of columns and filters does not have to be identical, so it is possible to create a request which presents X, Y, Z columns, but it filters for A, B , C columns at the same time.

The request could also include an optional key, which is called limit and it has a numerical value. If limit is N, then in the reponse only the first N rows will appear. The default limit is 50.

In the default setting, the order of the rows in a response are not defined, which means that the first N rows are not defined either. This could be amended by adding an explicit order key to any columns in the specification of columns. The value of this order key could be asc or desc in this case the response will be ordered by the ascending or descending and also by the specified column.

Columns and filters are given types in an array, and the column’s type determines the format of the filter. The following types can be available:

“boolean”, “string”, “integer”, “number”, “date”, “datetime”, “time”, “multiselect”, “select”

If a filter becomes active if a filterterm is given as condition key. The formats of filterterm could be the following:

  • string the condition has to be string and has to match the backend’s style, and it provides the filteres rows as a response.
  • boolean the condition could be true or false.
  • multiselect the condition could be an array containing numbers (numeric ids). In order to find out which ids are we filtering, we have to consider the name and goal of the column also we could use the filterdata mechanism detailed below
  • select the condition is one number (numeric id)
  • a date/time/datetime filter determines the timeframe. The condition is an object which includes type and value keys. If the value of the type is absolute then the value has to be an object, in which from and to determines the start and begining of required timeframe. If the value of the type is relative then the value  is a string which determines a relative timeperiod:
    The possible values are:
  • “today”
  • “yesterday”
  • “last week”
  • “this week”
  • “last month”
  • “this month”
  • “last year”
  • “this year”

 

  • number/integer filters have other compulsory fields:
    • display_format, its values could be : timerawpercentage
    • is_range,  boolean
    • minimum és maximum, which are the allowed range of numbers
    • this filter is an object which depeding on the value of is range either is true than it has to have from and to keys or it’s value is false and it has to have value.

 

Example:

{
   "limit" : 5,
   "columns" : [
      {
         "name" "project"
      },
      {
         "name" "hidden"
      }
   ],
   "filters" : [
      {
         "condition" false,
         "name" "hidden",
         "type" "boolean"
      }
   ]
}

Response

Response

The response contains the result of the qurey in a data array.  Every element of the array is an object, in which the keys relates to the columns which are given in the columns part of the query. Additionally most probably there wil be a id data field attached to every object, this helps with the identification of the of the queried entities.

Moreover the in the response a config object appears as well, which could include the have_more boolean. This boolean will tells us if the response shows all the available rows according the filters. For instance if the filters would have filtered 70 rows but in the request we have specified a 50 limit, than have_more will have the true value, so we would should know that the result is not complete, and filters could be changed and/or the limit coulbe be increase so that we would have all the available rows in our response.

Example:

{
      "config" : {
         "have_more" true
      },
      "data" : [
         {
            "hidden" false,
            "project" "Teszt Project Chavez exter-marriage",
            "id" : 1
         },
         {
            "id" : 2,
            "hidden" false,
            "project" "Teszt Project collar-shaping junk-bottle"
         },
         {
            "hidden" false,
            "project" "Teszt Project chondrosarcoma suburbanize",
            "id" : 4
         },
         {
            "id" : 5,
            "project" "Teszt Project borer NCCL",
            "hidden" false
         },
         {
            "hidden" false,
            "project" "Teszt Project anthography hue",
            "id" : 6
         }
      ]
   }

 

Export

Export

The /foo/export variant in addition to the above detailed requests, has an additional compulsory key, which name is dowload and its value could be ‘cvs’ or ‘xls’ which defines the downloadable file’s type.

The arrays of columns and filters are compulsory and they have to include the same column specifications as the /foo/list  request. The limit key is permitted with the difference, if it is missing than the response will include every queried rows.

The response will be dowloaded in the requested file type (CSV or XLS.) .

Filterdata

/search/filterdata

With this endpoint, numerical identifiers and related names can be queried by the select and multiselect filter conditions.

Request

In the payload object only the below mentioned (one or more) keys could appear. Essentially, the values that of these objects are empty objects, however, in a couple of instances multiple parameters could be given which could modify the condition of a search.

  • “calldirection”: outgoing or incoming, the direction of a call.
  • “callreason_types”:  the reason of the end of a call
  • “communication_method”: audio vs. video
  • “emails”: the email addresses of users of the system:
    • optional parameters:
      • all: boolean – if true: it will list of the inactive users besides the active ones.
      • project_id: number – it will only list the users assiged to project which’s id was used in the query.
  • “files”: files uploaded as attachments
  • “global_roles”: levels of access of users
  • “operatorstates”: the different states of the agents could be in
  • “project_roles”: levels of access of the users assigned to the specific project
  • “projectdata_column”: the names of the columns which appear in the records of a specific project.
    • compulsory parameter:
      • project_id: list the columns of that specific project
  • “projects”: the names of the projects
    • opcionális parameters:
      • all: boolean – if true, list the inactive projects additionally.
      • type: [outgoing_voice, incoming_voice, incoming_video] – only lists these type of projects.
  • “queues”: names of the queues,
    • optional parameters:
      • all: boolean
  • “robinson_lists”: the Robinson lists
    • optional  parameters:
      • all: boolean – if true, list the inactive projects additionally.
  • “scripts”: scripts belonging to the specific project
    • compulsory parameter:
      • project_id: lists the name of the scripts of the this project.
    • optional arguments:
      • all: boolean – if true, list the inactive scripts as well.
  • “termination_categories”: categories of terminations (success, fail, neutral, reached)
  • “terminations”: the actual terminations
    • optional arguments:
      • all: boolean – if true, list the inactive terminations as well.
      • project_id: number – only lists the terminations assigned to this project
      • termination_category_id: number – only lists the terminations which are in the selected termination category
      • hide_redial: it would not list records with REDIAL terminations
  • “usernames”:  user names of the users who are assigned to the system
    • optional  arguments:
      • all: boolean – if true, list the inactive users as well.
      • project_id: number – only lists the users assigned to the spcific project
  • “users”: the names registered for the users in the system
    • optional arguments:
      • all: boolean – if true, list the inactive users as well.
      • project_id: number – only lists the users assigned to the spcific project
  • “video_projects”: name of the video projects

Example:

{
    "users":{"all":true},
    "projects":{},
    "operatorstates":{},
    "video_projects":{}
}

Response

The response object includes the keys defines in the request, which all has their own arrays. The elements of the array include the ids and names of some of the different entities, and they always include the ids and names of the keys.

Example

{
      "video_projects":[
         {
            "id"1,
            "name""demo"
         }
      ]
      "operatorstates" : [
         {
            "id" 13,
            "name" "Állapotváltást kér"
         },
         {
            "id" 3,
            "name" "Beszélget"
         },
         {
            "id" 7,
            "name" "Ebédel"
         },
         {
            "id" 10,
            "name" "Előmunka"
         },
         {
            "id" 15,
            "name" "Hívási sor váltás"
         },
         {
            "id" 6,
            "name" "Kézi hívás"
         },
         {
            "id" 12,
            "name" "Ki akar lépni"
         },
         {
            "id" 16,
            "name" "My custom state"
         },
         {
            "id" 17,
            "name" "My custom state 2"
         },
         {
            "id" 8,
            "name" "Oktatáson van"
         },
         {
            "id" 14,
            "name" "Operátori beszélgetés"
         },
         {
            "id" 4,
            "name" "Regisztrál"
         },
         {
            "id" 2,
            "name" "Szünetet tart"
         },
         {
            "id" 1,
            "name" "Ügyfélre vár"
         },
         {
            "id" 5,
            "name" "Visszahívásra vár"
         }
      ],
      "projects" : [
         {
            "id" 41,
            "name" "_______"
         },
         {
            "id" 23,
            "name" "bejovo"
         },
         {
            "id" 42,
            "name" "dd                f"
         },
         {
            "id" 40,
            "name" "Operátor próba"
         },
         {
            "id" 27,
            "name" "Kampány másolás"
         },
         {
            "id" 28,
            "name" "Kampány másolás 2"
         },
         {
            "id" 29,
            "name" "Nottaken"
         },
         {
            "id" 39,
            "name" "Szkriptszerkesztés"
         },
         {
            "id" 37,
            "name" "Szkriptszerkesztés3"
         },
         {
            "id" 38,
            "name" "Szkriptszerkesztés4"
         },
         {
            "id" 22,
            "name" "Telesales"
         },
         {
            "id" 34,
            "name" "Tranzakció alapú időzített E-mail küldés"
         },
         {
            "id" 33,
            "name" "Tranzakció alapú időzített SMS küldés"
         },
         {
            "id" 25,
            "name" "Try"
         },
         {
            "id" 26,
            "name" "Try2"
         },
         {
            "id" 1,
            "name" "Tudásbázis"
         },
         {
            "id" 35,
            "name" "Ügyfélszolgálat feladat II. kör"
         },
         {
            "id" 21,
            "name" "Ügyfélszolgálat feladat I. kör"
         },
         {
            "id" 30,
            "name" "webugyteszt"
         }
      ],
      "users" : [
         {
            "id" 18,
            "name" "Admin"
         },
         {
            "id" 42,
            "name" "Admin1"
         },
         {
            "id" 22,
            "name" "Operátor1"
         },
         {
            "id" 26,
            "name" "Operátor11"
         },
         {
            "id" 40,
            "name" "Operátor3"
         },
         {
            "id" 33,
            "name" "Medialetolto"
         },
         {
            "id" 44,
            "name" "Operátor"
         },
         {
            "id" 21,
            "name" "Operátor 123"
         },
         {
            "id" 23,
            "name" "Operátor 11"
         },
         {
            "id" 19,
            "name" "Operátor 12"
         },
         {
            "id" 24,
            "name" "Operátor 22"
         },
         {
            "id" 43,
            "name" "Operátor 456"
         },
         {
            "id" 41,
            "name" "Jó"
         }
      ]
   }

Detailed worklog statistics

/stat/worklog_detailed/list

This is the endpoint serves to query the agents detailed time spent in the web client.

For the filter condition and data in the responses, there are couple things worth considering the following:

The agents who uses Comnica client is in one of the agent states at all times. There are a couple different agent states like Talking, Waiting for Customer, Paused. The system defines a couple of necessary agent states, however new agent states could be added on the admin page. In addition the agent is signed into multiple queues while using Comnica client, they can change between these queues. The system register every change in the agent states, or if the agent changes queues. The system registers every state-change, and every queue change, which means the during the use of the system, the system itself creates a detailed log, which contains information on which agent spend how much time in which queue, or agent state and with exact timestamps. The detailed worklog statistics, in reality actually is the queriable version of this log file. The rows of the results are the entries of this log. The required columns and filterconditions, could be given as it is detailed in the general list queries part and the information of the meaning of the possible filter types could be found there.

There is a mandatory filtercondition with this statistics, which name is interval and its type is datetime. With this filter we could query specifically requested duration, absolute intervals and with begiining and endpoints or relative references.

Further columns and filters

  • user_name
    • If it appears among the columns, then every row of the result will include the username.
    • if it appears among the filters than only the logs of the users appear who are specified in the filterconditions. Multiselect type filter, could specify the ids of users in an array, as users filterdata.
  • description
    • If it appears in the columns, every row will have the name of the agent’s state
    • if it appears among the filters than only the logs of the agent states appear who are specified in the filterconditions. Multiselect type filter, could specify the ids of agent states in an array, you could see it at operatorstates filterdata.
  • counts_as_work
    • If it appears in the columns, every row will have the information it the entry counts as work or not (every agent state is defined to be counted as work or not
    • if it appears among the filters than only thoes entries appear which counts as work.  Boolean type filter it could have the condition true or false.
  • status_begin
    • If it appears among the columns the every row of the result will have the begining of the entry.
    • There is no conditionfileter for this column, for more information see the interval filter.
  • status_end
    • If it appears among the columns the every row of the result will have the end of the entry.
    • There is no conditionfileter for this column, for more information see the interval filter.
  • duration
    • If it appears among the columns the every row of the result will have the duration of of the entry (how much time did the agent spent in the queried state)
    • If it appears among the filters than entries which have the same duration as the queried durations.v It is a number type filter, so with the help maximum and minimum keys, we could specify the required number array in minutes.
  • project_name
    • If it appears among the columns the every row of the result will have the information to which project is the user is signed into
    • if it appears among the filters than only the logs of the specified projects appear in the lists. Multiselect type filter, could specify the ids of the queried projects in an array, you could see more  at projects filterdata.
  • queue_name
    • If it appears among the columns the every row of the result will have the information to which queues is the user is signed into
    • if it appears among the filters than only the logs of the specified queues appear in the lists specified in the filterconditions. Multiselect type filter, could specify the ids of the queried queues in an array, you could see more at queues filterdata.

Response

  • {
          "config" : {
             "have_more" false
          },
          "data" : [
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.02511,
                "id" : 2656,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 11:32:11.88445+02",
                "status_end" "2019-10-14 11:32:12.90956+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.02598,
                "id" : 2659,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:12.85681+02",
                "status_end" "2019-10-14 13:04:13.88279+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Előmunka",
                "duration" : 1.69876,
                "id" : 2661,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:22.81521+02",
                "status_end" "2019-10-14 13:04:24.51397+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01377,
                "id" : 2662,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:24.51397+02",
                "status_end" "2019-10-14 13:04:25.52774+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Beszélget",
                "duration" : 3.58388,
                "id" : 2664,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:32.13318+02",
                "status_end" "2019-10-14 13:04:35.71706+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01884,
                "id" : 2674,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:18:30.85001+02",
                "status_end" "2019-10-14 14:18:31.86885+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01853,
                "id" : 2678,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:29:30.96704+02",
                "status_end" "2019-10-14 14:29:31.98557+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Előmunka",
                "duration" : 656.19123,
                "id" : 2680,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 14:29:32.79901+02",
                "status_end" "2019-10-14 14:40:28.99024+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 2.01933,
                "id" : 2681,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:40:28.99024+02",
                "status_end" "2019-10-14 14:40:31.00957+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 0.01216,
                "id" : 2683,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:40:35.98446+02",
                "status_end" "2019-10-14 14:40:35.99662+02",
                "user_name" "Nagy Napóleon"
             }
          ]
       }

     

Request

  • In the example belows, you could find all the possible columns, filter types, and expected filter conditions. We do not have to spcify every column or filter, in reality it is useful to specify every column with this statistics.
    {
          "columns" : [
             {
                "name" "user_name"
             },
             {
                "name" "description"
             },
             {
                "name" "counts_as_work"
             },
             {
                "name" "status_begin"
             },
             {
                "name" "status_end"
             },
             {
                "name" "duration"
             },
             {
                "name" "project_name"
             },
             {
                "name" "queue_name"
             }
          ],
          "filters" : [
             {
                "condition" : [
                   17,
                   22,
                   25,
                   44,
                   35,
                   37
                ],
                "name" "user_name",
                "type" "multiselect"
             },
             {
                "condition" : [
                   13,
                   3,
                   7,
                   10
                ],
                "name" "description",
                "type" "multiselect"
             },
             {
                "condition" true,
                "name" "counts_as_work",
                "type" "boolean"
             },
             {
                "condition" : {
                   "type" "relative",
                   "value" "this week"
                },
                "name" "interval",
                "type" "datetime"
             },
             {
                "condition" : {
                   "from" : 0,
                   "to" : 3706
                },
                "display_format" "time",
                "is_range" true,
                "maximum" : 7200,
                "minimum" : 0,
                "name" "duration",
                "type" "integer"
             },
             {
                "condition" : [
                   35,
                   21,
                   22
                ],
                "name" "project_name",
                "type" "multiselect"
             }
          ],
          "limit" : 50
       }

    Response

    {
          "config" : {
             "have_more" false
          },
          "data" : [
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.02511,
                "id" : 2656,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 11:32:11.88445+02",
                "status_end" "2019-10-14 11:32:12.90956+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.02598,
                "id" : 2659,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:12.85681+02",
                "status_end" "2019-10-14 13:04:13.88279+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Előmunka",
                "duration" : 1.69876,
                "id" : 2661,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:22.81521+02",
                "status_end" "2019-10-14 13:04:24.51397+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01377,
                "id" : 2662,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:24.51397+02",
                "status_end" "2019-10-14 13:04:25.52774+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Beszélget",
                "duration" : 3.58388,
                "id" : 2664,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 13:04:32.13318+02",
                "status_end" "2019-10-14 13:04:35.71706+02",
                "user_name" "Kovács Géza"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01884,
                "id" : 2674,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:18:30.85001+02",
                "status_end" "2019-10-14 14:18:31.86885+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 1.01853,
                "id" : 2678,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:29:30.96704+02",
                "status_end" "2019-10-14 14:29:31.98557+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Előmunka",
                "duration" : 656.19123,
                "id" : 2680,
                "project_name" "Ügyfélszolgálat feladat II. kör",
                "queue_name" "Ügyfélszolgálat feladat II. kör",
                "status_begin" "2019-10-14 14:29:32.79901+02",
                "status_end" "2019-10-14 14:40:28.99024+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 2.01933,
                "id" : 2681,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:40:28.99024+02",
                "status_end" "2019-10-14 14:40:31.00957+02",
                "user_name" "Nagy Napóleon"
             },
             {
                "counts_as_work" true,
                "description" "Állapotváltást kér",
                "duration" : 0.01216,
                "id" : 2683,
                "project_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "queue_name" "Telesales, Ügyfélszolgálat feladat II. kör, Ügyfélszolgálat feladat I. kör",
                "status_begin" "2019-10-14 14:40:35.98446+02",
                "status_end" "2019-10-14 14:40:35.99662+02",
                "user_name" "Nagy Napóleon"
             }
          ]
       }

     

Detailed worklog statistics by agents.

/stat/worklog_by_users/list

This endpoint lists the durations spent in the system grouped by agents. 

Response

  • All numerical values ​​(time spent in a given state) are in seconds.

    {
       "config" : {
          "have_more" false
       },
       "data" : [
          {
             "Beszélget" : 926,
             "Ebédel" : 0,
             "Előmunka" : 15985,
             "Hívási sor váltás" : 0,
             "Ki akar lépni" : 4,
             "Kézi hívás" : 59,
             "Oktatáson van" : 0,
             "Operátori beszélgetés" : 0,
             "Regisztrál" : 430,
             "Szünetet tart" : 5702,
             "Visszahívásra vár" : 0,
             "id" "21",
             "sum_all" : 23232,
             "sum_counts_as_work" : 17530,
             "user" "XXX YYY",
             "Állapotváltást kér" : 92,
             "Ügyfélre vár" : 34
          },
          {
             "Beszélget" : 1215,
             "Ebédel" : 0,
             "Előmunka" : 53411,
             "Hívási sor váltás" : 0,
             "Ki akar lépni" : 32,
             "Kézi hívás" : 92,
             "Oktatáson van" : 0,
             "Operátori beszélgetés" : 0,
             "Regisztrál" : 1101,
             "Szünetet tart" : 24571,
             "Visszahívásra vár" : 0,
             "id" "sum",
             "sum_all" : 80987,
             "sum_counts_as_work" : 56416,
             "user" "∑",
             "Állapotváltást kér" : 234,
             "Ügyfélre vár" : 331
          }
       ]
    }

Request

  • With this requests in addition to the predefined columns and their filters, the names of a couple of agent states could appear in the columnlists. The predefined columns are:
    • user: name of the user
    • sum_all: all the time spent in the system by the specified user.
    • sum_counts_as_work: the from the period queried only those durations are defined which counts as work

    In addition the array of filters have to hae duration filter called interval as well.

     

    {
       "columns" : [                          /* a lekért oszlopok */
          {
             "name" "user",
             "order" "asc"                 /* növekvő sorrend ezen oszlopok alapján */
          },
          {
             "name" "sum_all"
          },
          {
             "name" "sum_counts_as_work"
          },
          {
             "name" "Ügyfélre vár"
          },
          {
             "name" "Beszélget"
          },
          {
             "name" "Regisztrál"
          },
          {
             "name" "Visszahívásra vár"
          },
          {
             "name" "Kézi hívás"
          },
          {
             "name" "Előmunka"
          },
          {
             "name" "Ki akar lépni"
          },
          {
             "name" "Állapotváltást kér"
          },
          {
             "name" "Operátori beszélgetés"
          },
          {
             "name" "Hívási sor váltás"
          },
          {
             "name" "Szünetet tart"
          },
          {
             "name" "Ebédel"
          },
          {
             "name" "Oktatáson van"
          }
       ],
       "filters" : [
          {
             "condition" : {
                "type" "relative",
                "value" "last month"
             },
             "name" "interval",
             "type" "datetime"
          }
       ],
       "limit" : 50          
    }

Integrating external systems

For the benefit of our clients who would like to connect their own programs with Comnica CC we have created integration endpoints. The criterion for these endpoints that the data would be returned in usable format and it would not require extensive after care.

Integrations Endpoint:

CC record download

Path: /integration/cc/record/load/v1

Request payload:

"id": 42 }

the only field is the id, which is the identifier of the record.

CC record load response

{
    "comments": [
        {
            "comment""Example comment 1",
            "created_at""2019-11-19 16:21:17+01",
            "id": 13,
            "user_id": 0
        },
        {
            "comment""Example comment 2",
            "created_at""2019-11-19 16:22:57+01",
            "id": 14,
            "user_id": 0
        }
    ],
    "contacts": [
        {
            "active"true,
            "contact""3611234567",
            "id": 141,
            "name""",
            "priority": 1,
            "type""phone"
        },
        {
            "active"true,
            "contact""3619876543",
            "id": 142,
            "name""",
            "priority": 2,
            "type""phone"
        }
    ],
    "custom_data": {
        "aaa""äää",
        "bbb""ßßß",
        "phone""3611234567"
    },
    "system_columns": {
        "callback_to_user_id"null,
        "dial_from"null,
        "dial_to"null,
        "id": 72,
        "is_redial"false,
        "manual_redial"false,
        "next_call"null,
        "priority": 1,
        "project_id": 9,
        "termination_id"null,
        "tries_since_last_contact"null
    }
}

Details:

  • comments: the comments of the record in array, duration, timestamp, is and user id fields
  • contacts: the contacts belonging to a record in an array: active, phone, id, contact name, priority, and type
  • custom_data: the script fileds belonging to a record
  • system_columns: the system fields od a record; callback to user, is it callback, callable duration, time of the next call, priority, project_id, termination id, number of tries since the last contact

Creating CC records

Path: /integration/cc/record/save/v1

Request payload:

{
    "comments": [
        {
            "comment""Example comment 1",
            "created_at""2019-11-19 16:21:17+01"
        },
        {
            "comment""Example comment 2",
            "created_at""2019-11-19 16:22:57+01"
        }
    ],
    "contacts": [
        {
            "active"true,
            "contact""3611234567",
            "name""",
            "preferred"true,
            "priority": 1,
            "source_column""phone",
            "type""phone"
        },
        {
            "active"true,
            "contact""3619876543",
            "name""",
            "preferred"false,
            "priority": 2,
            "source_column""phone2",
            "type""phone"
        }
    ],
    "custom_data": {
        "aaa""äää",
        "bbb""ßßß",
        "phone""3611234567"
    },
    "system_columns": {
        "callback_to_user_id"null,
        "dial_from"null,
        "dial_to"null,
        "manual_redial"null,
        "next_call"null,
        "priority": 1,
        "project_id": 9
    }
}

Details:

    • comments: the comments of the record in array, duration, timestamp,
    • contacts: the contacts belonging to a record in an array; active, phone, contact’s name, preferred (from this we will have the preferred contact_id from which we initiate the call), priority (between 1 and 9 with 9 is the highest), source column(this is whown to the agent, so they know what type of number they are calling), contact type (usually phone )
    • custom_data: datafields belonging to the record A choice type of field and its values are always given in an array even is it only has 1 value
    • system_columns: the system fields od a record; callback to user, is it callback, callable duration, time of the next call, priority, project_id, termination id, number of tries since the last contact)

Response payload:

"id"42 }

Updating CC records

Path: /integration/cc/record/update/v1

Request payload:

{
    "id": 42,
    "custom_data": {
        "aaa""äää",
        "bbb""ßßß",
        "phone""3611234567"
    },
    "system_columns": {
        "callback_to_user_id"null,
        "manual_redial"null,
        "next_call"null,
        "termination_id": 9
    }
}

Response payload:

"id"42 }

CC bulk operation on records

Path: /integration/cc/record/bulk_modify/v1

Method: POST

The request is basically the same as ListRequest above, with a couple of extra parameters. With the filters, we set the type of records we want to work with, and then configure the bulk action with the action, subaction and params parameters. Example based on the list above: we take all the terminated records with code 356 and modify them to termination code 458.

{
    "payload": {
        "action""change_termination",
        "filters": [
            {
                "condition"280,
                "name""project",
                "type""select"
            },
            {
                "condition": {
                    "type""absolute",
                    "value": {
                        "from""2019-11-25 00:00:00+00:00",
                        "to""2019-12-01 23:59:59+00:00"
                    }
                },
                "name""upload",
                "type""datetime"
            },
            {
                "condition": [
                    356
                ],
                "name""terminating_code",
                "type""multiselect"
            }
        ],
        "params": {
            "condition"458
        }
    },
    "rq_sent""2022-05-31 16:53:55.841+0000"
}

Request fields in addition to listrequest parameters:

  • action: the operation, its possible values are “change_termination”, “change_callback”, “change_data”
  • subaction: sometimes the operation has sub-variants.
    • in case of change_callback action: “change_to_manual_callback”, “change_to_auto_callback”, “change_callback_user”, “remove_callback”
  • params: other arguments required by the operation and sub-operation, such as the termination code or the name and new value of the field to be rewritten
  • dry_run: it does not perform the operation, it just returns with the number of records found

Response:

{
    "payload": {
        "count"11
    },
    "res_sent""2022-05-31 18:53:56.438751+0200",
    "rq_rcvd""2022-05-31 18:53:56.037511+0200"
}

Changing termination (action: change_termination)

The content of the params part is a value with a single “condition” key, according to the desired value.

Overwrite field value (action: change_data)

The content of the params part is the field name and value:

{
   ...
   "params": {
      "field""szuletesi_hely",
      "value""Budapest"
   }
}

Changing callbacks (action: change_callback)

The payload varies depending on the subactions:

  • change_to_manual_callback: Setting a callback assigned to a user; required parameters are user_id and next_call (the time of the call)
  • change_to_auto_callback: A bit of a misnomer, this sets up a common list callback, so it’s not assigned to a user_id; required parameter is next_call
  • change_callback_user: Everything will remain, but the management of the records will be given to another user; required parameter is user_id
  • remove_callback: Cancellation of recall; no extra parameters

CC record download

Path: /integration/cc/record/list/v1

Request payload:

{
    "payload": {
        "columns": [
            {"name""record_id"},
            {"name""upload""order""desc"},
            {"name""terminated"},
            {"name""terminating_code"},
            {"name""phone"},
            {"name""phone_comment"}
        ],
        "filters": [
            {"condition": 280, "name""project""type""select"},
            {
                "condition": {
                    "type""absolute",
                    "value": {
                        "from""2019-11-25 00:00:00+00",
                        "to""2019-12-01 23:59:59+00"
                    }
                },
                "name""upload",
                "type""datetime"
            }
        ],
        "limit": 50
    },
    "rq_sent""2022-05-31 16:04:57.879+0000"
}

 

Filters:

  • project: type=select, mandatory— id of the project.
  • record_id: type=string
  • upload: type=datetime — timestamp of the upload
  • terminated: type=boolean — is it terminated?
  • terminating_code: type=multiselect, filterdata=terminations — terminating code
  • termination_category: type=multiselect, filterdata=termination_categories — termination category
  • next_call: type=datetime — timestamp of the next call
  • callback_to_user: type=multiselect, filterdata=users — filtering based on user assigned to callback
  • is_redial: type=boolean — is it a callback?
  • manual_redial: type=boolean —manual, explicitly set callback or automatic retry
  • last_comment: type=string — last comment
  • last_agent_work_at: type=datetime — time of last operator work
  • updated_at: type=datetime — last modification time
  • inserted_at: type=datetime — the time the record was entered into the system
  • last_agent: type=multiselect, filterdata=users — the agent who last worked with the record
  • last_call_at: type=datetime — the time of the last call
  • as well as the data fields that can be collected with the project field lister, which are filled with data when the database is uploaded or when the script is filled out.

Response payload:

{
    "payload": {
        "config": {
            "have_more"false
        },
        "data": [
            {
                "phone""3655555123",
                "id": 14396,
                "upload""2019-11-27 10:57:17.801476+00",
                "terminated"true,
                "phone_comment""",
                "record_id": 14396,
                "terminating_code""bye"
            },
            {
                "upload""2019-11-27 10:57:17.801476+00",
                "phone""3655555987",
                "id": 14397,
                "record_id": 14397,
                "terminated"false,
                "phone_comment"""
            },
            ...
        ]
    },
    "rq_rcvd""2022-05-31 18:04:58.128130+0200",
    "res_sent""2022-05-31 18:04:58.386605+0200"
}

CC project datafields query

Path: /integration/cc/project/fields/list/v1

Request payload:

"project_id"9 }

Response payload:

[
   {
      "datatype" "phone",
      "name" "phone",
      "type" "input",
      "is_contact" true,
      "id" 153
   },
   {
      "type" "input",
      "is_contact" true,
      "id" 154,
      "datatype" "phone",
      "name" "phone2"
   },
   {
      "is_contact" false,
      "type" "input",
      "id" 155,
      "datatype" "string",
      "name" "aaa"
   },
   {
      "name" "bbb",
      "datatype" "string",
      "id" 156,
      "type" "input",
      "is_contact" false
   },
   {
      "datatype" "number",
      "name" "num",
      "type" "input",
      "is_contact" false,
      "id" 157
   },
   {
      "is_contact" false,
      "type" "input",
      "id" 158,
      "datatype" "date",
      "name" "birthday"
   },
   {
      "datatype" "datetime",
      "name" "appointment",
      "type" "input",
      "is_contact" false,
      "id" 159
   },
   {
      "selection" "single",
      "is_contact" false,
      "name" "flavour",
      "datatype" "string",
      "content" : [
         {
            "savoury" "Savoury"
         },
         {
            "sweet" "Sweet"
         }
      ],
      "id" 160,
      "type" "choice"
   },
   {
      "type" "choice",
      "id" 161,
      "content" : [
         {
            "black" "Black"
         },
         {
            "white" "White"
         },
         {
            "red" "Red"
         },
         {
            "grue" "Grue"
         },
         {
            "yellow" "Yellow"
         }
      ],
      "datatype" "string",
      "name" "colour",
      "is_contact" false,
      "selection" "multi"
   }
]

Details:

  • num named it has to contain a number;
  • birthday column in which the format (YYYY-MM-DD);
  • appointment, in which the time of day (YYYY-MM-DD HH24:MI:SS[.UUUUUU][ZZZZ] — fraction seconds and timezone is optional, but it could happen that 24 hour format is also accepted. ;
  • flavour, is a list where a concrete value should be chosen from a determined list. Single choice option could be created through the script,
  • colour, list which had multiple choice, also could be created through the script.

CC soundfile download

Path: /recording/<callid>/download

Method: GET

Auth: basic

It downloads the soundfile related to the call id.

Datafield queries for video project

Queries of datafields of video project

Path: /video/project/column/list

Request payload:

{
    "rq_sent""2020-09-01 00:00:00+00",
    "payload": {
        "project_id"1
    }
}

Response payload:

{
  "rq_rcvd""2020-09-22 16:47:15.706141+0200",
  "res_sent""2020-09-22 16:47:15.821405+0200",
  "payload": [
    {
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "output_only"false,
      "name""identifying_company",
      "datatype""string",
      "type""input",
      "id"165,
      "editable"false
    },
    {
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "output_only"false,
      "name""name",
      "datatype""string",
      "type""input",
      "editable"true,
      "id"166
    },
    {
      "output_only"false,
      "name""birth_name",
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "type""input",
      "editable"true,
      "id"167,
      "datatype""string"
    },
    {
      "name""birth_place",
      "output_only"false,
      "mandatory_at_input"true,
      "mandatory_at_output"true,
      "id"168,
      "editable"true,
      "type""input",
      "datatype""string"
    },
    {
      "output_only"false,
      "name""birth_date",
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "type""input",
      "editable"true,
      "id"169,
      "datatype""date"
    },
    {
      "datatype""string",
      "type""input",
      "id"170,
      "editable"true,
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "output_only"false,
      "name""mothers_maiden_name"
    },
    {
      "datatype""string",
      "editable"true,
      "id"171,
      "type""input",
      "mandatory_at_input"true,
      "mandatory_at_output"true,
      "name""permanent_zip",
      "output_only"false
    },
    {
      "mandatory_at_input"true,
      "mandatory_at_output"true,
      "name""permanent_country",
      "output_only"false,
      "datatype""string",
      "id"172,
      "editable"true,
      "type""input"
    },
    {
      "type""input",
      "id"173,
      "editable"true,
      "datatype""string",
      "name""permanent_city",
      "output_only"false,
      "mandatory_at_output"true,
      "mandatory_at_input"true
    },
    {
      "id"174,
      "editable"true,
      "type""input",
      "datatype""string",
      "output_only"false,
      "name""permanent_street",
      "mandatory_at_input"true,
      "mandatory_at_output"true
    },
    {
      "name""temporary_zip",
      "output_only"false,
      "mandatory_at_input"true,
      "mandatory_at_output"true,
      "editable"true,
      "id"175,
      "type""input",
      "datatype""string"
    },
    {
      "output_only"false,
      "name""temporary_country",
      "mandatory_at_input"true,
      "mandatory_at_output"true,
      "editable"true,
      "id"176,
      "type""input",
      "datatype""string"
    },
    {
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "output_only"false,
      "name""temporary_cit",
      "datatype""string",
      "type""input",
      "id"177,
      "editable"true
    },
    {
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "name""temporary_street",
      "output_only"false,
      "datatype""string",
      "type""input",
      "editable"true,
      "id"178
    },
    {
      "type""input",
      "id"179,
      "editable"true,
      "datatype""string",
      "name""email",
      "output_only"false,
      "mandatory_at_output"true,
      "mandatory_at_input"true
    },
    {
      "output_only"false,
      "name""phone",
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "type""input",
      "editable"true,
      "id"180,
      "datatype""string"
    },
    {
      "datatype""string",
      "content": [
        {
          "label""útlevél",
          "value""passport"
        },
        {
          "value""license",
          "label""jogosítvány"
        },
        {
          "label""személyi igazolvány",
          "value""identity card"
        }
      ],
      "type""choice",
      "id"181,
      "editable"true,
      "mandatory_at_output"true,
      "mandatory_at_input"false,
      "selection""single",
      "name""id_card_type",
      "output_only"true
    },
    {
      "type""input",
      "editable"true,
      "id"182,
      "datatype""string",
      "name""id_card_number",
      "output_only"true,
      "mandatory_at_output"true,
      "mandatory_at_input"false
    },
    {
      "datatype""string",
      "type""input",
      "editable"true,
      "id"183,
      "mandatory_at_output"true,
      "mandatory_at_input"false,
      "output_only"true,
      "name""address_card_number"
    },
    {
      "datatype""string",
      "id"184,
      "editable"true,
      "type""input",
      "mandatory_at_input"false,
      "mandatory_at_output"true,
      "output_only"false,
      "name""nationality"
    },
    {
      "output_only"true,
      "name""public_figure",
      "selection""single",
      "mandatory_at_input"false,
      "mandatory_at_output"true,
      "editable"true,
      "id"185,
      "type""choice",
      "content": [
        {
          "value""customer",
          "label""célszemély"
        },
        {
          "value""family member",
          "label""családtag"
        }
      ],
      "datatype""string"
    },
    {
      "type""input",
      "editable"false,
      "id"186,
      "datatype""string",
      "name""external_id",
      "output_only"false,
      "mandatory_at_output"true,
      "mandatory_at_input"false
    },
    {
      "mandatory_at_output"true,
      "mandatory_at_input"true,
      "output_only"false,
      "name""simplified_identification",
      "datatype""boolean",
      "type""input",
      "editable"false,
      "id"187
    },
    {
      "type""input",
      "editable"false,
      "id"188,
      "datatype""date",
      "output_only"false,
      "name""preferred_time",
      "mandatory_at_output"true,
      "mandatory_at_input"false
    },
    {
      "type""input",
      "id"189,
      "editable"true,
      "datatype""boolean",
      "output_only"true,
      "name""statements_accepted",
      "mandatory_at_output"true,
      "mandatory_at_input"false
    },
    {
      "datatype""boolean",
      "id"190,
      "editable"true,
      "type""input",
      "mandatory_at_input"false,
      "mandatory_at_output"true,
      "output_only"true,
      "name""recordings_confirmed"
    },
    {
      "datatype""boolean",
      "id"191,
      "editable"true,
      "type""input",
      "mandatory_at_input"false,
      "mandatory_at_output"true,
      "name""data_check_completed",
      "output_only"true
    }
  ]
}

Details:

in the response the payload includes the columns which are in the project. In the response, the payload element contains the columns in the campaign. The properties of the columns:

  • name: the name
  • datatype: datatype
  • id: identifier used in the system
  • type: type of the field
  • content (in case of choice type): included elements
  • editable: is it editable
  • output_only: in case of adding data to a project, it cannot be modified with record modification. It only appears when the record is queried.
  • mandatory_at_input: it appears mandatorily when record is queried
  • mandatory_at_output: it appears mandatorily when record is queried

Creating a video record

Path: /video/projectdata/create

Request payload:

{
    "rq_sent""2020-09-01 00:00:00+00",
    "payload": {
        "video_project_id": 1,
        "data": {
            "identifying_company""Comnica",
            "name""Teszt Elke",
            "birth_name""Tesztelő Elke",
            "birth_place""Csömör",
            "birth_date""2000-01-01",
            "mothers_maiden_name""Kulcsos Katalin",
            "permanent_zip""1119",
            "permanent_country""Magyarország",
            "permanent_city""Budapest",
            "permanent_street""Mohai út 38.",
            "temporary_zip""1119",
            "temporary_country""Magyarország",
            "temporary_city""Budapest",
            "temporary_street""Mohai út 38.",
            "email""support@comnica.cc",
            "phone""3612550991",
            "simplified_identification"true
        }
    }
}

Details:

    • video_project_id: the identifier os the video project (See more in fillerdata)
    • data: the date stored in the record
      • keys: columnnames
      • values: values stored in the columns

    The columns given in the columns are mandatory elements. A missing column or specifying them without value could result in faulty creation

    Additional columns, which does not appear in data could be given if they exist. The types of datafields of the records could be queried in the chapter about queries of datafields of video project.

 

Response payload:

{
  "payload": {
    "url""video url, amin kersztül az ügyfél be tud lépni a rendszerbe",
    "video_projectdata_id"42
  },
  "res_sent""2020-01-01 00:00:00+00",
  "rq_rcvd""2020-01-01 00:00:00+00"
}

Webhooks

Comnica can respond to certain events by calling a remote URL. At that address, some HTTP server must listen and accept POST requests with a JSON body. Comnica’s system only sends one request for each event and does not monitor the response received from the set endpoint, and accordingly does not retry the warning related to the given event.

Format

  • The body of the webhook call is a UTF-8 encoded JSON string. It has three keys.
    • event: the event that caused the call, such as cc.record.save, is always populated
    • event_reason: a kind of discriminator within that event, such as operator.termination, can be null
    • payload: object, with all the data that seems necessary and sufficient. The value is at least {}.
    {
      "event""i12n.record.state.change",
      "event_reason"null,
      "payload": {
        "record_id": 42,
        "previous_state""active",
        "new_state""reviewing"
      }
    }

Setup

  • For each CC (telephone) and identification (video, NRTI) project, 1 webhook URL can be assigned separately, for example https://api.example.com:8080/comnica-webhook-receiver/
  • There are no other configuration options for now.

Saving CC record

    • event: cc.record.save
    • event_reason:
      • site.edit — edited on the admin interface
      • operator.save — the record was saved in the Client
      • operator.termination — the record was saved and closed in the Client
    • payload:
      • record_id — id of the record
      • termination_id — id of the termination or null
      • terminating_code — name of the termination or null

Identify state change

    • event: i12n.record.state.change
    • event_reason:
      • null — usually
      • timeout — the record was ready for the client to begin authentication, but did not do so within the time limit
      • timeout_before_ready — the record was not made usable within the time limit
      • review_timeout — the record was not checked within the time limit
    • payload:
      • record_id — id of the record
      • previous_state — previous agent state
      • new_state — new agent state

Duplication filtering in case of date upload using API

Endpoint: api/integration/cc/record/save/v1 (uploading records)

Change:

  • if we call the endpoint unchanged, there is no duplication
  • if the following key:value pairs are included in the payload, normal duplication occurs:
    "options": { "check_duplicates": "basic" }
    
  • if the following key:value pairs are included in the payload, then there is a strict duplication rate:
    "options": { "check_duplicates": "strict" }