...
resolution
: Will take one of the values from “hourly” and “daily”. Hourly stats will give hour-wise cumulative stats of the selected attribute/s for last 24 hours; daily stats will accumulate all the stats day-wise for last 7 days.aggregateType
: Must be one of the “SUM”, “AVERAGE” or “COUNT”. This aggregation type will be used to aggregate all the selected attribute/sattributes
: List of selected attributescomparison
: This boolean flag would be true for comparison of the same attribute over this and the last week and would be false for comparison of different attributes over the same time period. The time period will depend on the value ofresolution.
filterAttributes
: A list of attributes on which the data will be filtered. This list would contain the names of the attributesfilterValues
: An array of arrays corresponding to the filter values. The array at first index will have values of the first filter and so on.- chartType: Its value is either "Line Chart" or "Bar Chart". if no value is provided (i.e: empty string) then it sends Line Chart by default.
Line Chart Query (Historical)
...
getHistoricalData (resolution: "hourly",
aggregateType: "count",
attributes: {val: ["currentStatecallsAbandoned"]},
comparison: "true",
filterAttributes: {val:["team", "skillGroup"]},
filterValues: {val: [[1, 2, 3], [4, 5, 6]],chartType:"Line Chart"})
{
name
series
}
...
Bar Chart also support the same input arguments as of line chart, only its output response is different. The expected result of bar chart query is as follow:Sample Query:
Sample Query:
getHistoricalData (resolution: "hourly",
aggregateType: "count",
attributes: {val: ["currentState"callsAbandoned","callsReceived","callsAnswered"]},
comparison: "true",
filterAttributes: {val:["team", "skillGroupqueue"]},
filterValues: {val: [[1, 2, 3], [4, 5, 6]],chartType:"Bar Chart"})
{
name
series
}
...