Jump to: navigation, search

Capacity API

The Capacity Service enables you to define the number of scheduled callbacks that are allowed for Callback for a given time slot in the week. Then, your Callback service refers to your Capacity service and to your Office Hours service to adjust the agent availability and the number of scheduled callbacks.

You can define exceptions for dates where less or more agents are available, and you can define as many Capacity services that you need to match your Callback services. This way, you can address the agent workload according to the real resources that are available.

Configuration

Here is an example of GMS configuration:

[service.Capacity]
_capacity=[Mon, Tue, Wed, Thu, Fri, Sat, Sun]
_capacity_1={"1":{"0000":1,"0100":3}}
_capacity_2={"2":{"0100":3}}
_capacity_3={"3":{"1000":6,"1100":6,"1200":6,"1300":6,"1400":6,"1500":6,"1600":6,"1700":6,"1800":6,"1900":6,"2000":6,"2100":6,"2200":6,"2300":6,"0000":6,"0100":6,"0200":6,"0300":6,"0400":6,"0500":6,"0600":6,"0700":6,"0800":6,"0900":6}}
_capacity_4={"4":{"1100":3,"0100":3}}
_capacity_5={"5":{"0100":3}}
_capacity_6={"6":{"0100":3}}
_capacity_7={"7":{"0000":1,"0100":3}}
_capacity_add={}
_service=capacity
_timezone=UTC
_type=builtin
Important
You can also configure a capacity service in the Service Management UI.


API

When you add a capacity service through the Configured Services interface, you can access the capacity service by its execution name and retrieve content through the API.

In order to find the available capacity, the query provides a date and time range. The response object provides a list of time periods and available capacity for each period. Here is a list of input parameters:

GET /genesys/1/service/{capacity-execution-name}?start=<date and time>&end=<date and time>&timezone=<timezone>
Name Description Required
start yes Start date and time in ISO-8601 format without a timezone component; for example: 2015-03-17T09:15:00.000
end yes End date and time in ISO-8601 format without a timezone component; for example: 2015-03-17T12:45:00.000
timezone yes Timezone used for "start" and "end" parameters; for example: America/Los_Angeles

For example, the following request will provide the following results:

GET /genesys/1/service/Capacity?start=2016-10-05T15:00:00.000Z&number-of-days=2 HTTP/1.1
> Host: 127.0.0.1:8080
> User-Agent: curl/7.50.3
> Accept: */*
>
< HTTP/1.1 200 OK
< Set-Cookie: JSESSIONID=1opza084c3vszo631xnrtqw38;Path=/genesys;HttpOnly
< Expires: Thu, 01 Jan 1970 00:00:00 GMT
< Content-Type: application/json;charset=UTF-8
< Transfer-Encoding: chunked
<
{
  "error": null,
  "slots": [
    {
      "utcTime": "2016-10-05T15:00:00.000Z",
      "localTime": "2016-10-05T15:00:00.000Z",
      "durationMin": 540,
      "capacity": 6
    },
    {
      "utcTime": "2016-10-06T01:00:00.000Z",
      "localTime": "2016-10-06T01:00:00.000Z",
      "durationMin": 60,
      "capacity": 3
    },
    {
      "utcTime": "2016-10-06T11:00:00.000Z",
      "localTime": "2016-10-06T11:00:00.000Z",
      "durationMin": 60,
      "capacity": 3
    }
  ],
  "timezone": "UTC"
}
This page was last edited on January 4, 2018, at 09:55.
Comments or questions about this documentation? Contact us for support!