Skip to main content Skip to docs navigation
Check

Contact Center Services API

On this page

Contact Center Services API Overview

1      Introduction

CCS exposes some of its functionality over a publicly accessible API, implemented using REST architecture and exposes some of its events (call, presence etc.,) over a publicly accessible WebSocket.

2      ACCESS

CCS Events are accessed at:

·         wss://<CCS_DOMAIN>/6/v2/sock

over SSL/TLS, and CCS APIs are accessed at:

·         https://<CCS_DOMAIN>/6/v2/api/

using https.

2.1   Security

Access to the CCS API and WebSocket is based on https and wss over SSL/TLS.

2.1.1    API

An authentication protocol is used for the REST-based API.

2.1.2    WebSocket

WebSocket connections are authenticated using an authentication protocol.

Every client after successful establishment of WebSocket connection must send the “connect” request below. The connection is authenticated using the “connect” message. After successful validation the WebSocket is allowed further to access the events. If the connection is not validated, it is closed from the server side.

{

   “request”:”connect”,

   “token”: <Token>

}

2.2   Authorization

Authorization for accessing API functionality or receiving particular events through WebSockets is based on the permissions assigned to the user/extension in CCS. Permissions are assigned in groups called “Roles”.

After the client is authenticated, CCS checks for permissions to access that particular API or event and if permitted, the processing of the request takes place. With insufficient permissions an error response is sent back to the client.

 


 

3      PerMIssions

Permission

Permits

API

General permission for accessing the REST based API. Combination of this permission with other roles (Tenant Admin etc.) assigned to the user will give the user the authorization to use the API to GET, PUT and DELETE on those resources.

Agent Control

This permission along with the API permission will enable the user to do the agent related actions like State Change, etc.

Call Control

This permission along with the API permission will give authorization for the user to do the call related actions like stop and start suppression, kill call etc.

Agent Events

Receiving Websocket events for agent presence changes like Idle, Busy etc.,

Call Events

Receiving Websocket events for calls

Inbound Queue Events

Receiving Websocket events for inbound queues

 


 

 

4      API

4.1   List All Products

4.1.1    Permissions Required

API, Tenant Edit

 

4.1.2    Request:

GET /products/

Ex: /products/

 

4.1.3    Headers:

Content-Type: application/json

 

 

4.1.4    Response:

Code

Response

200

{

  "total": "62",

  "success": true,

  "items": [

    {

      "uuid": "az123456-d7ef-4638-9cff-ef6aaba3e77f",

      "notes": "R7.3 Feature",

      "name": "+AG"

    },

    {

      "uuid": "az123456-e76e-440c-8d9a-970015b8b533",

      "notes": "",

      "name": "AllPermissions-Product"

    },

    {

      "uuid": "az123456-c58d-48c1-90b9-4b3c65c22875",

      "notes": "",

      "name": "Jerin_product"

    },

    {

      "uuid": "az123456-b08e-467d-87e0-8763bce63892",

      "notes": "R6.3 Version",

      "name": "CCA,EM ph"

    }

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.2   List All Roles

4.2.1    Permissions Required

API, Tenant Edit

 

4.2.2    Request:

GET /roles/

Ex: /roles/

 

4.2.3    Headers:

Content-Type: application/json

 

 

4.2.4    Response:

Code

Response

200

{

  "total": "3",

  "success": true,

  "items": [

    {

      "uuid": "az123456-a5f9-488c-9bb6-e947f3f33d2b",

      "name": "Tenant Admin"

    },

    {

      "uuid": "az123456-9817-4964-86ff-d2c4f11b67d0",

      "name": "Telco Admin"

    },

    {

      "uuid": "az123456-ef95-44b7-afc8-54ce4cdb67f1",

      "name": "API"

    }

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

 

 

4.3   List All Tenants

4.3.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.3.2    Request:

GET /tenants

Ex: /tenants

 

4.3.3    Headers:

Content-Type: application/json

 

 

4.3.4    Response:

Code

Response

200

{

  "total": "1",

  "success": true,

  "items": [

    {

      "uuid": "az123456-53d6-48e2-85cd-f8d6bde10fd9",

      "telco_id": {

        "uuid": "az123456-eee4-46f5-baf9-a9d661bfa92a",

        "name": "Broadview"

      },

      "status": "enable",

      "silhouette_id": {

        "uuid": "az123456-bd5e-480c-aeca-fb726cde928f",

        "name": "nvlab180-1"

      },

      "sil_tenant_url": "/ccsl06",

      "sil_tenant_name": "CCSLab15",

      "sil_tenant_id": "500900355",

      "sil_authentication": true,

      "product_name": "Call Center Services",

      "product_id": [

        {

          "uuid": "az123456-7a90-4e41-a91d-19c8e35e81ef",

          "notes": "",

          "name": "Campaign"

        },

        {

          "uuid": "az123456-8cd5-4f06-9b23-af8c1283c4c6",

          "notes": "",

          "name": "ECR,ACP"

        }

      ],

      "modified_on": "2021-03-12 07:23:02 AM",

      "modified_by": [],

      "cross_reference": [],

      "created_on": "2020-04-17 01:48:02 AM",

      "created_by": "root"

    }

    ]

    }

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.4   View Tenant Details

4.4.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.4.2    Request:

GET /tenants/<tenant_uuid>

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae

 

4.4.3    Headers:

Content-Type: application/json

 

 

4.4.4    Response:

Code

Response

200

{

  "success": true,

  "sil_tenant_name": "CCSLab15",

  "site_ip_address": "58.00.231.32",

  "nightly_call_details": true,

  "rec_down_limit": "100",

  "rec_extn_limit": "10",

  "telco_id": {

    "uuid": "az123456-eee4-46f5-baf9-a9d661bfa92a",

    "name": "Broadview"

  },

  "chat_licenses_count": 5,

  "multimedia_licenses_count": 5,

  "group_agent_count": 5,

  "cdr_retention": "365",

  "uuid": "az123456-53d6-48e2-85cd-f8d6bde10fd9",

  "chat_licenses": "6",

  "multimedia_licenses": "6",

  "max_queues_count": 29,

  "monitor_ext_limit": "3",

  "sid": "500900355",

  "max_agents_count": 8,

  "max_agents": "100",

  "timezone": "US/Eastern",

  "product_id": [

    {

      "uuid": "az123456-7a90-4e41-a91d-19c8e35e81ef",

      "notes": "",

      "name": "Campaign"

    },

    {

      "uuid": "az123456-8cd5-4f06-9b23-af8c1283c4c6",

      "notes": "",

      "name": "ECR,ACP"

    }

  ],

  "sil_auth_editable": true,

  "ve_ivr": "true",

  "modified_on": "2021-03-12 07:23:02 AM",

  "created_on": "2020-04-17 01:48:02 AM",

  "sil_tenant_url": "/ccsl06",

  "rec_extn_count": 7,

  "sil_crplatform_enabled": true,

  "library_limit": "600",

  "status": "enable",

  "sil_authentication": true,

  "default_gateway_id": {

    "uuid": "az123456-ca8a-42e3-a432-ecc0c4479daa",

    "name": "Metaswitch"

  },

  "default_signin_method": "Phone",

  "sftp_export": false,

  "rec_retention": "30",

  "sil_tenant_id": "500900355",

  "monitor_ext_count": 2,

  "created_by": "root",

  "campaign_size": "99",

  "group_agent_limit": "1",

  "default_outgoing_clid": "2677318044",

  "rec_quality": "mono",

  "cleanup_sftp": false,

  "max_queues": "45",

  "service_extension": "536",

  "sftp_dir_configured": true,

  "name": "CCSLab15",

  "product_name": "Call Center Services",

  "silhouette_id": {

    "uuid": "az123456-bd5e-480c-aeca-fb726cde928f",

    "name": "nvlab180-1"

  }

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.5   List Tenant Roles

4.5.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.5.2    Request:

GET /tenants/<tenant_uuid>/roles

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/roles

 

4.5.3    Headers:

Content-Type: application/json

 

 

4.5.4    Response:

Code

Response

200

{

  "total": "2",

  "success": true,

  "items": [

    {

      "uuid": "az123456-ac4e-4caf-922b-52ef715da6c7",

      "name": "US1398 (Voice Help)"

    },

    {

      "uuid": "az123456-c173-43ae-b0f8-139e8eccab5f",

      "name": "US1398 (Chat Help)"

    }

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.6   List Tenant Acds

4.6.1    Permissions Required

API, Voice IQs View/Voice OQs View/Conditional Routes View/VRQs View

 

4.6.2    Request:

GET /acds

GET /tenants/<tenant_uuid>/acds

 

4.6.3    Headers:

Content-Type: application/json

 

 

4.6.4    Response:

Code

Response

200

{

  "total": 2,

  "success": true,

  "items": [

    [

      {

        "uuid": "az123456-0817-40a5-86aa-0f43becbd6f6",

        "type": "voice_queues",

        "tenant_id": "81bf95ea-53d6-48e2-85cd-f8d6bde10fd9",

        "name": "Q3878",

        "extension": "387",

        "alternate_extensions": []

      },

      {

        "uuid": "az123456-d988-4239-ab9c-c393eeb2d217",

        "type": "voice_queues",

        "tenant_id": "81bf95ea-53d6-48e2-85cd-f8d6bde10fd9",

        "name": "Q386",

        "extension": "386",

        "alternate_extensions": []

      }    ]

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}



 

4.7   List Tenant Presence Options

4.7.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.7.2    Request:

GET /tenants/<tenant_uuid>/presence_options

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/presence_options

 

4.7.3    Headers:

Content-Type: application/json

 

 

4.7.4    Response:

Code

Response

200

{

  "total": "3",

  "success": true,

  "items": [

    {

      "uuid": "az123456-a751-4bcd-a8d8-8c1c9d48186e",

      "type": "sign_out",

      "name": "Holiday In Bahamas"

    },

    {

      "uuid": "az123456-2aa9-4aa3-aa9d-cc8513e95a6d",

      "type": "sign_out",

      "name": "Sign Out"

    },

    {

      "uuid": "az123456-6227-4ddc-9204-bd3cb9496e23",

      "type": "away",

      "name": "Coffee Break"

    }

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.8   List Tenant Extensions

4.8.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.8.2    Request:

GET /tenants/<tenant_uuid>/extensions (for telco user)

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/presence_options

GET /extensions (for tenant level user)

Ex: /extensions

 

4.8.3    Headers:

Content-Type: application/json

 

 

4.8.4    Response:

Code

Response

200

{

  "total": "3",

  "success": true,

  "items": [

    {

      "uuid": "az123456-7c49-49a8-80fc-ae173a422a36",

      "lastname": "Nath",

      "firstname": "Reese",

      "extension": "114"

    },

    {

      "uuid": "az123456-57be-4919-aa73-b2e6341fe461",

      "lastname": "Patel",

      "firstname": "Sonny",

      "extension": "113"

    },

    {

      "uuid": "az123456-7bee-4351-bcd6-ecc2d8620b83",

      "lastname": "Masters",

      "firstname": "Rob",

      "extension": "112"

    }

  ]

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.9   Tenant SMS/MMS Count

4.9.1    Permissions Required

API, Tenants View/Tenant Edit

 

4.9.2    Request:

GET /tenants/<tenant_uuid>/text_count (for telco user)

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/text_count

 

4.9.3    Headers:

Content-Type: application/json

 

 

4.9.4    Response:

Code

Response

200

{
  "success": true,
  "items": {
    "tenant_sid": "500900440",
    "tenant_name": "vlab180_palmitos  - palmito's",
    "tenant_id": "bac783da-43fe-4070-bf76-55a3d856417f",
    "sms_stats": {
      "out_sms": 4,
      "out_mms": 1,
      "in_sms": 3,
      "in_mms": 1
    }
  }
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.10   Tenant SMS/MMS Reset Count

4.10.1 Permissions Required

API, Tenants View/Tenant Edit

 

4.10.2 Request:

POST /tenants/<tenant_uuid>/text_count (for telco user)

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/text_count

 

4.10.3 Headers:

Content-Type: application/json

 

 

4.10.4 Request Body:

{"request": "reset_counter"}

 

Ex: {"request": "reset_counter"}

 

4.10.5 Response:

Code

Response

200

{
  "success": true
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.11   Add Tenant Product

4.11.1 Permissions Required

API, Tenant Edit

 

4.11.2 Request:

POST /tenants/<tenant_uuid>

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae

 

4.11.3 Headers:

Content-Type: application/json

 

 

4.11.4 Request Body:

{"request": "add_product", "product": <product_uuid_string>}

 

Ex: {"request": "add_product", "product": "c4389d99-1434-42ca-98ab-b5803b9b608d"}

 

 

4.11.5 Response:

Code

Response

200

{

  "success": true,

  "uuid": "az123456-1434-42ca-98ab-b5803b9b608d" 

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.12   Delete Tenant Product

4.12.1 Permissions Required

API, Tenant Edit

 

4.12.2 Request:

POST /tenants/<tenant_uuid>

 

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae

 

4.12.3 Headers:

Content-Type: application/json

 

 

4.12.4 Request Body:

{"request": "delete_product", "product": <product_uuid_string>}

 

Ex: {"request": "delete_product", "product": "az123456-1434-42ca-98ab-b5803b9b608d"}

 

 

4.12.5 Response:

Code

Response

200

{

  "success": true,

  "uuid": "az123456-1434-42ca-98ab-b5803b9b608d" 

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.13   Update Tenant Limits and Licenses

4.13.1 Permissions Required

API, Tenant Edit

 

4.13.2 Request:

PUT /tenants/<tenant_uuid>

 

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae

 

4.13.3 Headers:

Content-Type: application/json

 

 

4.13.4 Request Body:

{

  “product_name”: <NewName>,

  “rec_extn_limit”: <RecordingExtensionsLimit>,

  “monitor_ext_limit”: <MonitorExtensionsLimit>,

  “max_queues”: <MaximumNumberOfQueues>,

  “max_agents” : <MaximumNumberOfAgents>,

  “group_agent_limit”: <GroupAgentLimit>,

  “chat_licenses”: <ChatLicenses>,

  “multimedia_licenses”:<MultiMediaLicenses>,

  “agent_billing”: "Named"/”Concurrent"

}

 

Ex:{

  “product_name”: “New Product”,

  “rec_extn_limit”: “10”,

  “monitor_ext_limit”: “3”,

  “max_queues”:”100”,

  “max_agents” : “100”

  “group_agent_limit”: “0”,

  “chat_licenses”:  “6”,

  “multimedia_licenses:”6”,

  “agent_billing”: “Concurrent”

}

 

 

 

4.13.5 Response:

Code

Response

200

{

  "success": true,

  "uuid": "az123456-1434-42ca-98ab-b5803b9b608d" 

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.14   Update Extension (PUT)

4.14.1 Permissions Required

API, Tenant Edit

 

4.14.2 Request:

PUT /tenants/<tenant_uuid/extensions/<extension_uuid/

Ex: /tenants/327241fd-1234-46fe-9276-cc65dac6feae/extensions/az123456-7c49-49a8-80fc-ae173a422a36

 

4.14.3 Headers:

Content-Type: application/json

 

 

4.14.4 Request Body:

{

 "is_agent": "true/false",

 "recording_type": "None"/"Mandatory"/"On Demand",

 "monitor": "true"/"false",

 "max_chats": "0 to 6",

 “ is_multimedia_enabled”:”true”/”false”

}

 

Ex: {"is_agent": "true",

         "recording_type": "None",

         "monitor": "false",

         "max_chats": "3",

         “is_multimedia_enabled”:”true”

    }

 

 

 

4.14.5 Response:

Code

Response

200

{

  "success": true

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.15   Get Agent State (By TelcoUser)

4.15.1 Permissions Required

API, Agent Control

 

4.15.2 Request:

GET /tenants/<TenanID>/extensions/<ExtensionUUId>/agent_state

 

Ex:  /tenants/c255052e-c560-4340-b73e-675eabc3aed3/extensions/az123456-5cca-4ff1-874e-dc1c92d6de64/agent_state

 

4.15.3 Headers:

Content-Type: application/json

 

 

 

4.15.4 Response:

Code

Response

200

{

  "success": true,

  "queue_state": {

    "state": "None",

    "queue": "",

    "duration": "0"

  },

  "phone_state": {

    "state": "Idle",

    "duration": "117:11:18"

  },

  "consecutive_missed": 0,

  "agent_state": {

    "state": {

      "type": "ready",

      "name": "Ready"

    },

    "duration": "117:56:46"

  }

}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.16   Update Agent State (By TelcoUser)

4.16.1 Permissions Required

API, Agent Control

 

4.16.2 Request:

POST /tenants/<TenanID>/extensions/<ExtensionUUId>

 

Ex:  /tenants/c255052e-c560-4340-b73e-675eabc3aed3/extensions/az123456-5cca-4ff1-874e-dc1c92d6de64

 

4.16.3 Headers:

Content-Type: application/json

 

 

4.16.4 Request Body:

{

  “request”: “updateAgentState”,

   “name”: “Ready” | "<name of a specific away or signout state>"

}

 

Ex:{

  “request”: “updateAgentState”,

  “name”: “Lunch Break”,

}

 

 

 

4.16.5 Response:

Code

Response

200

{"success": true}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

4.17   Update Agent State (self)

4.17.1 Permissions Required

API, Agent Control

 

4.17.2 Request:

POST /agent_state

 

Ex: /agent_state

 

4.17.3 Headers:

Content-Type: application/json

 

 

4.17.4 Request Body:

{

  “request”: “updateAgentState”,

   “name”: “Ready” | "<name of a specific away or signout state>"

}

 

Ex:{

  “request”: “updateAgentState”,

  “name”: “Lunch Break”,

}

 

 

 

4.17.5 Response:

Code

Response

200

{"success": true}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.18   Update Agent State (By TenantAdmin)

4.18.1 Permissions Required

API, Agent Control

 

4.18.2 Request:

POST /extensions/<ExtensionUUId>

 

Ex: /extensions/ az123456-30b7-4b06-9d87-7607033e2712

 

 

4.18.3 Headers:

Content-Type: application/json

 

 

4.18.4 Request Body:

{

  “request”: “updateAgentState”,

   “name”: “Ready” | "<name of a specific away or signout state>"

}

 

Ex:{

  “request”: “updateAgentState”,

  “name”: “Lunch Break”,

}

 

 

 

4.18.5 Response:

Code

Response

200

{"success": true}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

 

 

 

 

4.19   List Calls

4.19.1 Permissions Required

API, Calls Listing View (Only for tenant level users)

 

4.19.2 Request:

GET /calls

4.19.3 Headers:

Content-Type: application/json

 

 

4.19.4 Response:

 

Code

 

Response

 

 

200

 

{
"total":
"1",
"success":
true,
"items": [
{
"wait_time":
"00:00:02",
"vrq_ques_ans": [],
"time":
"2019-02-26T01:35:11",
"recordings": [
{
"stop_time":
"2019-02-26T01:37:50",
"start_time":
"2019-02-26T01:35:14",
"markers":
"",
"filename":
"0BS9DD02LEMUI.mp3",
"extension":
"100",
"duration":
"00:02:36"
}
],
"outcome":
"Answered",
"is_recorded":
"true",
"id":
"0BS9DD02LEMUI",
"hold_time":
" ",
"fe_xfr":
"",
"duration":
"00:02:39",
"direction":
"in",
"commit_account_code":
"",
"calling": {
"number":
"9735552100",
"name":
"WHIPPANY NJ"
},
"called": {
"number":
"302",
"name":
"Test Queue 2"
},
"call_source": {},
"call_details": [
{
"type":
"inbound",
"timestamp":
"2019-02-26T01:35:11",
"event":
"Inbound call from WHIPPANY NJ 9735552100 to Test Queue 2 - 302"
},
{
"type":
"called",
"timestamp":
"2019-02-26T01:35:11",
"event":
"Called Tommy Kandukuri - 100"
},
{
"type":
"answered",
"timestamp":
"2019-02-26T01:35:14",
"event":
"Answered by 100 - Tommy Kandukuri"
},
{
"type":
"disconnected",
"timestamp":
"2019-02-26T01:37:50",
"event":
"Disconnected by near-end"
}
],
"call_destination": {
"type":
"phone",
"number":
"100",
"name":
"Tommy Kandukuri"
}}]}

 

 

400

 

{"success": true, "reason": <ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

 

500

 

{"success": true,"reason":"Internal Server Error"}

 

4.20   Listing of single call

4.20.1 Permissions Required

API, Calls View (Only for tenant level users)

 

4.20.2 Request:

GET /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.20.3 Headers:

Content-Type: application/json

 

 

4.20.4 Response:

Note: There are some different fields in the “progress” response and the “answered” response.

 

 

Code

 

Response

 

 

200 (Progress)

{
"success":
true,
{
  "wait_time":
" ",
  "type":
"in_ecr",
  "time":
"2019-02-26T01:18:38",
  "success":
true,
  "outcome":
"Progress",
  "is_suppressed":
false,
  "is_recording":
true,
  "is_recorded":
"",
  "id":
"0BS9D0BNZ3LCP",
  "hold_time":
" ",
  "fe_xfr":
"",
  "duration":
"",
  "direction":
"in",
  "commit_account_code":
"",
  "calling": {
    "number":
"9735552100",
    "name":
"WHIPPANY     NJ"
  },
  "caller_uuid":
"az123456-398e-11e9-8229-637a779022ac",
  "callee_uuid":
"az123456-398e-11e9-8236-637a779022ac",
  "called": {
    "number":
"2677318903",
    "name":
" "
  },
  "call_source": {},
  "call_details": [
    {
      "type":
"inbound",
      "timestamp":
"2019-02-26T01:18:38",
      "event":
"Inbound call from WHIPPANY     NJ 9735552100 to   2675558903"
    },
    {
      "type":
"answered",
      "timestamp":
"2019-02-26T01:18:44",
      "event":
"Answered by 100 - Tommy Kandukuri"
    }
  ],
  "call_destination": {
    "type":
"phone",
    "number":
"100",
    "name":
"Tommy Kandukuri"
  },
  "being_marked":
false
}}

200 (Answered)

{
"success":
true,
{
"wait_time":
"00:00:02",
"vrq_ques_ans": [],
"time":
"2019-02-26T01:35:11",
"recordings": [
{
"stop_time":
"2019-02-26T01:37:50",
"start_time":
"2019-02-26T01:35:14",
"markers":
"",
"filename":
"0BS9DD02LEMUI.mp3",
"extension":
"100",
"duration":
"00:02:36"
}
],
"outcome":
"Answered",
"is_recorded":
"true",
"id":
"0BS9DD02LEMUI",
"hold_time":
" ",
"fe_xfr":
"",
"duration":
"00:02:39",
"direction":
"in",
"commit_account_code":
"",
"calling": {
"number":
"9735552100",
"name":
"WHIPPANY NJ"
},
"called": {
"number":
"302",
"name":
"Test Queue 2"
},
"call_source": {},
"call_details": [
{
"type":
"inbound",
"timestamp":
"2019-02-26T01:35:11",
"event":
"Inbound call from WHIPPANY NJ 9735552100 to Test Queue 2 - 302"
},
{
"type":
"called",
"timestamp":
"2019-02-26T01:35:11",
"event":
"Called Tommy Kandukuri - 100"
},
{
"type":
"answered",
"timestamp":
"2019-02-26T01:35:14",
"event":
"Answered by 100 - Tommy Kandukuri"
},
{
"type":
"disconnected",
"timestamp":
"2019-02-26T01:37:50",
"event":
"Disconnected by near-end"
}
],
"call_destination": {
"type":
"phone",
"number":
"100",
"name":
"Tommy Kandukuri"
}}

 

 

400

 

{"success": true, "reason": <ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

 

500

 

{"success": true,"reason":"Internal Server Error"}

 

4.21   Search for a specific call

4.21.1 Permissions Required

API, Calls View (Only for tenant level users)

                                                                                    

4.21.2 Request:

GET /calls/filter?calling_number=<calling_number>&called_number=<called_number>

&from_datetime=<FromDateTimeInJson>&to_datetime=<ToDateTimeInJson>&time_z=UTC

 

 

Ex:  /calls/filter?calling_number=501&called_number=101&from_datetime=2021-10-07T07:22:21&to_datetime=2021-10-07T07:22:24&time_z=UTC

 

 

4.21.3 Headers:

Content-Type: application/json

 

 

4.21.4 Response:

Note: There are some different fields in the “progress” response and the “answered” response.

 

 

Code

 

Response

 

200

{
  "success": true,
  "call_details": {
    "time": "2021-10-07T03:22:21+04:00",
    "outcome": "Answered",
    "id": "0CESZSU7BL2ZE",
    "fe_xfr": {},
    "duration": "00:02:54",
    "calling": {
      "number": "9735558880",
      "name": "WINDSTREAM"
    }
  }
}

 

 

400

 

 

{"success": true, "reason": <ReasonString>}

 

 

401

{"status":401,"reason":"Unauthorized"}

 

500

 

{"success": true,"reason":"Internal Server Error"}

 

4.22   Start Suppression

4.22.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.22.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.22.3 Headers:

Content-Type: application/json

 

 

4.22.4 Request Body:

{"request": "startSuppression"}

 

4.22.5 Response:

 

 

Code

 

Response

 

 

200

 

{
"success":
true,
}

 

 

400

 

{"success": true, "reason": <ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

 

500

 

{"success": true,"reason":"Internal Server Error"}

 

 

4.23   Stop Suppression

4.23.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.23.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.23.3 Headers:

Content-Type: application/json

 

 

4.23.4 Request Body:

{"request": "stopSuppression"}

 

4.23.5 Response:

Code

Response

200

{
"success":
true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.24   Kill Call

4.24.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.24.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.24.3 Headers:

Content-Type: application/json

 

 

4.24.4 Request Body:

{"request": "kill"}

 

4.24.5 Response:

Code

Response

200

{
"success": true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.25   Wait Transfer

4.25.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.25.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.25.3 Headers:

Content-Type: application/json

 

 

4.25.4 Request Body:

{"request": "wait_transfer", "target": <extension_string/acd_extension_string/number_string>}

 

Ex: {"request": "wait_transfer", "target": "102"}

    {"request": "wait_transfer", "target": "19735552109"}

 

 

 

4.25.5 Response:

Code

Response

200

{
"success": true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.26   Wait Redirect

4.26.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.26.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.26.3 Headers:

Content-Type: application/json

 

 

4.26.4 Request Body:

{"request": "wait_redirect", "target": <acd_uuid_string>}

 

Ex: {"request": "wait_redirect", "target": "az123456-f645-47b6-bd71-e9f493ff8ac9"}

 

 

 

4.26.5 Response:

Code

Response

200

{
"success": true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.27   Wait Kill

4.27.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.27.2 Request:

POST /calls/<call_id_string>

 

Ex: /calls/0BS9DD02LEMUI

 

4.27.3 Headers:

Content-Type: application/json

 

 

4.27.4 Request Body:

{"request": "wait_kill"}

 

 

4.27.5 Response:

Code

Response

200

{
"success": true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 

4.28   Make a outbound call (click to call)

4.28.1 Permissions Required

API, Call Control (Only for tenant level users)

 

4.28.2 Request:

POST /tenants/<tenant_id >/extensions/<extension_uuid>

 

Ex: /tenants/c255052e-c560-4340-b73e-675eabc3aed3/extensions/az123456-5cca-4ff1-874e-dc1c92d6de64

 

4.28.3 Headers:

Content-Type: application/json

 

 

4.28.4 Request Body:

{

 "request":"dial",

 "target":<TargetNumber>,

 "outbound_queue_uuid":<Outbound_Queue_UUID>

}

 

Ex:

{

"request":"dial",

"target":"819735552106",

"outbound_queue_uuid":"az123456-c0ed-42b7-8e8c-d50c4991828c"

}

 

4.28.5 Response:

Code

Response

200

{
"success": true,
}

400

{"success":false,"reason":<ReasonString>}

401

{"status":401,"reason":"Unauthorized"}

500

{"success": true,"reason":"Internal Server Error"}

 


 

5      Events

As the parameters in each event received are different, the events and their parameters (with sample data) are attached as an excel sheet.

 

Terminology:

Domain: IP/URL of the ccsDomain to connect to execute the API or listen to events

Tenant Domain: URL parameter of the specific tenant in the CCS

Request Headers: Request headers that need to be sent along with the REST API Request.

Request Body: JSON body that needs to be sent with PUT or POST request of the REST API

Response Headers: The response headers from the server

Response Body: Response to the API request in case of apitest.html. A list of the events received on Websocket in case of wstest.html.

Submit sends the pending request, API or Websocket.

Clear clears the Response Body of prior responses with responses to focus on new ones.