Outgoing Webhook

Outgoing Webhook sends an HTTP request to the configured URL (destination server of Webhook) after the voice analysis of the call history is completed.
Engineers can use Webhook to integrate the call history details to the external systems.

Contents

How to integrate

  IMPORTANT

Confirmation of Challenge-Response

  •   When you Save the setting, add {'challenge':'hex_token'} to the setting and payload, and send a Challenge-Response confirmation request to the server set in [URL] (fixed IP address).
  •   The destination server must return a 'hex_token' value by a 200 response with a header of {'Content-Type':'text/plain'}.
  1. Log in to MiiTel Admin.
  2. Click Third Party Integration > Outgoing Webhook.
  3. Click Add new integration setting.

OutgoingWebhook1+.png

  1. You will set the following fields.

OutgoingWebhook2+.png

1Name: Enter the name of the setting (ex: a name that can recognize this integration)

2URL: Enter the URL (destination server of Webhook) 

3Additional headers: Enter the header you'd like to add (JSON format)

You will add the Bearer token or user authentication data for the BASIC authentication.
Ex: {”Authorization":"Bearer ACCESSTOKEN"}

  IMPORTANT

  •   You can't change 'User-Agent' and 'Content-Type'. They won't be reflected in this setting even if you set them.

4Additional payload: Enter the payload you'd like to add (JSON format)

5Source IP address: Check here if you want the source IP address to be fixed

  • MiiTel uses the following source IP addresses to send a request.
    • 18.177.83.94/32
    • 35.73.236.241/32
  • If you enable this, requests of all call histories for the past 10 minutes of the call history will be sent at the 0th, 10th, 20th, 30th, 40th, and 50th minute of every hour. 
  1. Click Save.

  NOTE

  •   If the confirmation can't be made with the challenge-response authentication, you will see the following error messages and won't be able to save the integration setting.
    • If you don't receive the correct challenge value from the server
      ErrorMessage1.png
    • If you don't receive a response for a certain amount of time
      ErrorMessage2.png

How to edit the integration

  1. Log in to MiiTel Admin.
  2. Click Third Party Integration > Outgoing Webhook.
  3. Click [ ellipsis-v-light__1_.svg ] on the integration setting > Edit.
  4. After you edit, click Save.

OutgoingWebhook3+.png

How to delete the integration

  1. Log in to MiiTel Admin.
  2. Click Third Party Integration > Outgoing Webhook.
  3. Click [ ellipsis-v-light__1_.svg ] on the integration setting > Delete.
  4. Click Delete.

OutgoingWebhook4+.png

When Outgoing Webhook sends the HTTP request

  • After the voice analysis of the call history is completed

HTTP request

Version

  • HTTP/1.1

Method

  • POST

Header

Key Description
content-type application/json; charset=utf-8
user-agent MiiTel-Webhook/v1

Payload

Key Description
call
Call history
  id



ID of the call history
The ID in the following URL (Call history in MiiTel Analytics)
https://<Company ID>.miitel.jp/app/calls/<Sequence ID>
  tenant_code
Company ID
  
details
Details of the call history
    id
ID of the call history
     dial_starts_at
Dial begin time
     dial_answered_at
Call begin time
     dial_ends_at
Call end time
       call_type


Call type
OUTGOING_CALL: Outgoing call
OUTGOING_TRANSFER: Transfer call
INCOMING_CALL: Incoming call
QUEUEING_CALL: Queueing call
EXTENSION: Calls to an extension number
EXTENSION_GROUP: Calls to extensions in a group 
EXTENSION_TRANSFER: Transfer calls to an extension number
EXTENSION_GROUP_TRANSFER: Transfer calls to extensions in a group

MONITORING: Monitoring
PREDICTIVE_DIAL: Predictive dialer
AUTOMATIC_TRANSFER: Automatic transfer
AUTOMATIC_RECORD: Voicemail
PLAY_SOUND: Play sound
READ_DTMF: IVR push number

     circuit_number
Circuit number
     circuit_name
Circuit name
    from_number
Phone number of the caller
Check "null" for the outgoing call and "circuit_number" for the start of the outgoing call
     to_number
Phone number of the called person
     previous_id
Sequence ID of the most recent action ("null" if there are no recent actions)
     analysis
Speech evaluation
      score
Overall score
      tlr

Talk : Listen ratio

       rally_count
Number of rallies
      overlap_count
Number of overlaps
      silence_count
Number of silences
    participants
Speaker
       id
ID of the speaker
      from_to

FROM: the person who made the call
TO: the person who received the call

      name
Speaker
MiiTel username
or the contact person name that is registered in Contacts ("null" if the person is not registered in Contacts)
      company_name
Account name
       analysis
Voice evaluation
        f0 Fundamental frequency
        speechrate Speech rate
        variance Intonation strength
        filler_count Number of fillers
        positive_score Emotion recognition (positive score)
Value: 0 - 1 (max: 1)
        negative_score Emotion recognition (negative score)
Value: 0 - 1 (max: 1)
    tags
Call memo
      created_by
MiiTel user who registered the call memo
      creator_type
TENANT_USER: Call memo
SYSTEM: Automatic call memo
      value
Call memo fields (value of the registered call memo)
    comments
Comment
      created_at
Registration date of the comment
      created_by
User who registered the comment
      value
Details of the comment
    keywords
Keyword appearance
      starts_at
The time when the keyword appeared (amount of time (sec) after the start of the call)
      participant_id
ID of the speaker who spoke the keyword (participant > id)
      value
Value of the keyword
    phrases
Speech recognition (Without fillers)
      participant_id
ID of the speaker (participant > id)
      raw
Speech recognition results of the speaker (original text)
         order Order number of the speech (0 -)
        phrase Speech recognition results (summary)
        phrase_nofiller

Speech recognition results (without fillers)

        start_at Start time of the speech (amount of time (sec) after the start of the call)
        end_at End time of the speech (amount of time (sec) after the start of the call)
        filler_num Number of characters in the speech recognition results (without fillers)
      summary Speech recognition (summary)
The key is the same as details > phrases > raw
    speech_recognition
Speech recognition
      raw
Speech recognition in order of the call history (original text)
      summary
Speech recognition in order of the call history (summary)

Request sample

Request sample (You can click this link to download the request sample.)

{
    "call": {
        "id": "99e2fdb7-845a-46de-8d94-882add220551",
        "tenant_code": "miitel-test",
        "details": [
            {
                "id": "99e2fdb7-845a-46de-8d94-882add220551",
                "dial_starts_at": "2022-12-21T22:31:56+00:00",
                "dial_answered_at": "2022-12-21T22:32:29+00:00",
                "dial_ends_at": "2022-12-21T22:33:22+00:00",
                "call_type": "OUTGOING_CALL",
                "circuit_number": "8330000000",
                "circuit_name": "8330000000",
                "from_number": null,
                "to_number": "4800000000",
                "previous_id": null,
                "analysis": {
                    "score": 29.67924528301887,
                    "tlr": 0.5575,
                    "rally_count": 1,
                    "overlap_count": 0,
                    "silence_count": 1
                },
                "participants": [
                    {
                        "id": "018536d0-9363-8e82-fcce-bc2a7098f830",
                        "from_to": "FROM",
                        "name": "Edgardo",
                        "company_name": null,
                        "analysis": {
                            "f0": 103.9616,
                            "speechrate": 11.0932,
                            "variance": 14.5887,
                            "filler_count": 0,
                            "positive_score": 0,
                            "negative_score": 0
                        }
                    },
                    {
                        "id": "018536d0-9363-768c-2a6b-e145d790bdb6",
                        "from_to": "TO",
                        "name": null,
                        "company_name": null,
                        "analysis": {
                            "f0": 182.7321,
                            "speechrate": 14.249,
                            "variance": 17.7925,
                            "filler_count": 0,
                            "positive_score": 0,
                            "negative_score": 0
                        }
                    }
                ],
                "tags": [
                    {
                        "created_by": "Edgardo",
                        "creator_type": "TENANT_USER",
                        "value": "Left Message"
                    }
                ],
                "comments": [],
                "keywords": [
                    {
                        "starts_at": 1,
                        "participant_id": "018536d0-9363-768c-2a6b-e145d790bdb6",
                        "value": "call"
                    },
                    {
                        "starts_at": 29,
                        "participant_id": "018536d0-9363-8e82-fcce-bc2a7098f830",
                        "value": "call"
                    }
                ],
                "phrases": [
                    {
                        "participant_id": "018536d0-9363-8e82-fcce-bc2a7098f830",
                        "raw": [
                            {
                                "order": 2,
                                "phrase": "Hello. My name is Eddie and I'm calling you from Midtown and this message is for Mark.",
                                "phrase_nofiller": "Hello. My name is Eddie and I'm calling you from Midtown and this mess",
                                "start_at": 18,
                                "end_at": 23.235,
                                "filler_num": 0
                            },
                            {
                                "order": 3,
                                "phrase": "I'm just calling in to follow up on an email that I sent to you earlier.",
                                "phrase_nofiller": "I'm just calling in to follow up on an email that I sent ",
                                "start_at": 23.695,
                                "end_at": 28.615,
                                "filler_num": 0
                            },
                            {
                                "order": 4,
                                "phrase": "And if you can, please call me at 8:33.",
                                "phrase_nofiller": "And if you can, please call me ",
                                "start_at": 29.275,
                                "end_at": 32.32,
                                "filler_num": 0
                            },
                            {
                                "order": 5,
                                "phrase": "000.",
                                "phrase_nofiller": "000.",
                                "start_at": 32.775,
                                "end_at": 34.06,
                                "filler_num": 0
                            },
                            {
                                "order": 6,
                                "phrase": "0000.",
                                "phrase_nofiller": "0000.",
                                "start_at": 34.39,
                                "end_at": 36.075,
                                "filler_num": 0
                            },
                            {
                                "order": 7,
                                "phrase": "That is 8334 m.",
                                "phrase_nofiller": "That is 8334",
                                "start_at": 36.62,
                                "end_at": 39.16,
                                "filler_num": 0
                            },
                            {
                                "order": 8,
                                "phrase": "Thanks. And I'm looking forward to speaking with you soon.",
                                "phrase_nofiller": "Thanks. And I'm looking forward to speaking with ",
                                "start_at": 39.535,
                                "end_at": 42.455,
                                "filler_num": 0
                            }
                        ],
                        "summary": [
                            {
                                "order": 2,
                                "phrase": "Hello. My name is Eddie and I'm calling you from Midtown and this message is for Mark.",
                                "phrase_nofiller": "Hello. My name is Eddie and I'm calling you from Midtown and this mess",
                                "start_at": 18,
                                "end_at": 23.235,
                                "filler_num": null
                            },
                            {
                                "order": 3,
                                "phrase": "I'm just calling in to follow up on an email that I sent to you earlier.",
                                "phrase_nofiller": "I'm just calling in to follow up on an email that I sent ",
                                "start_at": 23.695,
                                "end_at": 28.615,
                                "filler_num": null
                            }
                        ]
                    },
                    {
                        "participant_id": "018536d0-9363-768c-2a6b-e145d790bdb6",
                        "raw": [
                            {
                                "order": 0,
                                "phrase": "Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as possible. Thank you.",
                                "phrase_nofiller": "Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as p",
                                "start_at": 1.05,
                                "end_at": 8.14,
                                "filler_num": 0
                            },
                            {
                                "order": 1,
                                "phrase": "At the tone, please record your message. When you have finished recording, you may hang up or press one for more options.",
                                "phrase_nofiller": "At the tone, please record your message. When you have finished recording, you may hang up or press o",
                                "start_at": 10.7,
                                "end_at": 17.225,
                                "filler_num": 0
                            }
                        ],
                        "summary": [
                            {
                                "order": 0,
                                "phrase": "Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as possible. Thank you.",
                                "phrase_nofiller": "Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as p",
                                "start_at": 1.05,
                                "end_at": 8.14,
                                "filler_num": null
                            },
                            {
                                "order": 1,
                                "phrase": "At the tone, please record your message. When you have finished recording, you may hang up or press one for more options.",
                                "phrase_nofiller": "At the tone, please record your message. When you have finished recording, you may hang up or press o",
                                "start_at": 10.7,
                                "end_at": 17.225,
                                "filler_num": null
                            }
                        ]
                    }
                ],
                "speech_recognition": {
                    "raw": "0:01 (Customer) Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as p\n0:10 (Customer) At the tone, please record your message. When you have finished recording, you may hang up or press o\n0:18 (Operator) Hello. My name is Eddie and I'm calling you from Midtown and this mess\n0:23 (Operator) I'm just calling in to follow up on an email that I sent \n0:29 (Operator) And if you can, please call me \n0:32 (Operator) 000.\n0:34 (Operator) 0000.\n0:36 (Operator) That is 8334\n0:39 (Operator) Thanks. And I'm looking forward to speaking with ",
                    "summary": "0:01 (Customer) Hello, you've reached Arizona. Backyard custom, please leave a message. We will call you back as soon as p\n0:10 (Customer) At the tone, please record your message. When you have finished recording, you may hang up or press o\n0:18 (Operator) Hello. My name is Eddie and I'm calling you from Midtown and this mess\n0:23 (Operator) I'm just calling in to follow up on an email that I sent "
                }
            }
        ]
    },
    "params_key": "z&aH+&Kz8saC"
}

Was this article helpful?