Skip to content

Call Center API

The Call Center Recipient API enables you to configure recipients or users of the Call Center app and get information on the user status.

API calls

Click on each call to view the endpoint, method, and request example.

Parameters

The table shows the possible parameters and actions available for call center recipients API calls.

Key Description Type Min/Max/Default/Values
account_id Required. Hosted PBX VoIP account ID. string N/A
auth_token Required. Unique authentication string. string N/A
page_size Indicates the number of pages in the results. number N/A
status Indicates the status of the request. string N/A
request_id The request ID for this API call. string N/A
available Indicates if recipient is available. boolean N/A
avg-call-time The average amount of time the recipient has spent on a call (in seconds). integer N/A
login-time The unix timestamp of when the recipient logged in. timestamp N/A
total-calls Total number of calls that the recipient has handled. integer N/A
missed-calls Total number of calls that the recipient failed to handle for any reason integer N/A
availability-state The state of the recipient. string Ready, Away, Wrapup-Time, Call-Offer, On-A-Call, Not-Logged-In
queue-availability If a per-queue availability flag(s) have been set, they will be reported here as a list of queue-ID's. boolean values N/A
last-action-time The timestamp of the last time the recipient changed state. timestamp N/A
last-handled-time The timestamp of the last time the recipient was delivered a call. timestamp N/A
offered-call If there is a call currently being offered, this contains the Queue-ID, Session-ID, Caller-ID-Name, Caller-ID-Number, Queue-Enter-Time of the call string N/A
handling-call If there is a call currently being handled, this will contain the Queue-ID, Session-ID, Caller-ID-Name, Caller-ID-Number, Queue-Enter-Time of the call. N/A N/A
wrapup-time-seconds The time left, in seconds, until the recipient is out of wrapup (0 if they are not on wrap up). integer N/A
wrapup-cancel Ends the users current wrap-up time. N/A N/A
wrapup-extend Resets the recepients wrap-up time to the full amount. N/A N/A
node The node on which the process for this recipient is running. string N/A

List recipients

Returns a list of all configured recipients for an account.

Method and endpoint

GET /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/

Request

curl -v -X GET -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients

Response

    {
        "page_size":2,
        "data":[
            {"id":"{RECIPIENT_ID1}","name":"{RECIPIENT_NAME1}"},
            {"id":"{RECIPIENT_ID2}","name":"{RECIPIENT_NAME2}"}
        ],
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Get recipient status

Returns the current status of the recipient.

Method and endpoint

GET /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{USER_ID}/status

Request

curl -v -X GET -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{USER_ID}/status

Response

    {
        "data":{
            "available": {AVAILABLE},
            "availability_state": {AVAIL_STATE},
            "queue_availability": {QUEUE_AVAILABILITY},
            "offered_call": {OFFERED_CALL_INFO},
            "handling_call": {HANDLING_CALL_INFO},
            "wiretapping_recipient": {WIRETAPPING_RECIPIENT_ID},
            "wiretap_mode": {WIRETAP_MODE},
            "wrapup_time_seconds": {WRAPUP_TIME_SECONDS},
            "stats": {
                "total_calls": {TOTAL_CALLS},
                "missed_calls": {MISSED_CALLS},
                "avg_call_time": {AVG_CALL_TIME},
                "login_time": {LOGIN_TIME},
                "last_action_time": {LAST_ACTION_TIME},
                "last_handled_time": {LAST_HANDLED_TIME}
            },
            "node": {RUNNING_ON_NODE}
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Get recipient list status

Returns the current status of a list of recipients.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/status

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/status -d '{"data":{"recipient_ids":[{RECIP_ID_1},{RECIP_ID_2},{RECIP_ID_3}]}}'

Response

    {
        "data":{
            {RECIP_ID_1}: {
                "available": {AVAILABLE},
                "availability_state": {AVAIL_STATE},
                "offered_call": {OFFERED_CALL_INFO},
                "handling_call": {HANDLING_CALL_INFO},
                "wrapup_time_seconds": {WRAPUP_TIME_SECONDS},
                "stats": {
                    "total_calls": {TOTAL_CALLS},
                    "missed_calls": {MISSED_CALLS},
                    "avg_call_time": {AVG_CALL_TIME},
                    "login_time": {LOGIN_TIME},
                    "last_action_time": {LAST_ACTION_TIME},
                    "last_handled_time": {LAST_HANDLED_TIME}
                },
                "node": {RUNNING_ON_NODE}
            },
            {RECIP_ID_2}: {
                "available": {AVAILABLE},
                "availability_state": {AVAIL_STATE},
                "offered_call": {OFFERED_CALL_INFO},
                "handling_call": {HANDLING_CALL_INFO},
                "wrapup_time_seconds": {WRAPUP_TIME_SECONDS},
                "stats": (
                    "total_calls": {TOTAL_CALLS},
                    "missed_calls": {MISSED_CALLS},
                    "avg_call_time": {AVG_CALL_TIME},
                    "login_time": {LOGIN_TIME},
                    "last_action_time": {LAST_ACTION_TIME},
                    "last_handled_time": {LAST_HANDLED_TIME}
                },
                "node": {RUNNING_ON_NODE}
            },
            {RECIP_ID_3}: "not_logged_in"
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

NOTE: This will either return the same object as the /status API for a single recipient, or the value not_logged_in.

Login recipient

Logs a recipient into Call Center and starts the recipient session.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID}/

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID} -d '{"data":{"action":"login"}}'

Response

    {
        "data":{
            "action":"login"
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Logout recipient

Terminates the recipient session, and logs the recipient out of Call Center.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID}/

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID} -d '{"data":{"action":"logout"}}':

Response

    {
        "data":{
            "action":"logout"
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Set recipient status

Sets the recipient's status. The possible status values are login / logout / ready / away. The recipient must have a status of login before they can have a status of ready or away. The queue_id is OPTIONAL; if it is present, it sets the availability for that queue only.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID}/status

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{USER_ID}/status -d '{"data":{"status":"{STATUS}"}}'

Response

    {
        "data":{
            "status":"{STATUS}",
            "queue_id":{QUEUE_ID <OPTIONAL>}
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Extend wrap-up time

The wrapup_extend action will reset the recipient's wrap up time to the full amount. The amount varies based on the configuration of the queue that the previous call was handled from.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID}/

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID} -d '{"data":{"action":"wrapup_extend"}}'

Response

    {
        "data":{
            "action":"wrapup_extend"
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }

Cancel wrap-up time

The wrapup_cancel action will end the recipients current wrapup time.

Method and endpoint

POST /v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID}/

Request

curl -v -X POST -H "X-Auth-Token: {AUTH_TOKEN}" -H "Content-Type: application/json" http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/qubicle_recipients/{RECIPIENT_ID} -d '{"data":{"action":"wrapup_cancel"}}'

Response

    {
        "data":{
            "action":"wrapup_cancel"
        },
        "status":"success",
        "request_id":"{REQUEST_ID}",
        "auth_token":"{AUTH_TOKEN}"
    }