Genesys CTI User Forum > Genesys-related Development
Stats - Get Total Time by Reason Code
federom:
Hello All,
How can i get the total time spent by certain user in an specific Not Ready Reason code?
Any clue?
Thanks!
René:
Hi,
You have to define a filter and apply it to TotalTime in NotReady status statistic.
R.
federom:
Thanks Rene!
How do i define the filter ? Right now what i have is
[code]
req.StatisticObject = StatisticObject.Create();
req.StatisticObject.ObjectType = StatisticObjectType.Agent;
req.StatisticObject.TenantName = "Resources";
req.StatisticObject.ObjectId = "UserID";
req.StatisticMetric = StatisticMetric.Create();
req.StatisticMetric.StatisticType = "TotalNotReadyStatusTime";
req.ReferenceId = 2;
protocolManagment[statServerConfigName].Send(req);[/code]
Thanks!
cavagnaro:
Remember you have:
Metric applied to an object = Statistic
So on StatisticMetric you define filter too as you would do on CCPulse for example and there you go ;)
You can find more info on the PSDK doc that inside the Doc folder on the install path
federom:
[quote author=cavagnaro link=topic=7895.msg34493#msg34493 date=1373460637]
Remember you have:
Metric applied to an object = Statistic
So on StatisticMetric you define filter too as you would do on CCPulse for example and there you go ;)
You can find more info on the PSDK doc that inside the Doc folder on the install path
[/quote]
Thanks cavagnaro !
i have created a Filter in the stat Server as
Name = LunchTime
Value= ExtensionReasonCode="Lunch"
Then i did the call
[code]'RequestGetStatistic' ('1033')
message attributes:
StatisticObject = ComplexClass(StatisticObject):
TENANT_PASSWORD [str] = [output suppressed]
OBJECT [int] = 0 [Agent]
TENANT_ID [str] = "Resources"
OBJECT_ID [str] = "891536"
StatisticMetric = ComplexClass(StatisticMetric):
STATTYPE [str] = "TotalNotReadyStatusTime"
ACTION_FILTER [str] = "LunchTime"
REQ_ID [int] = 2
VOID_VALUE [bstr] = KVList:
'Filter' [str] = "LunchTime"
'EventInfo' ('2')
message attributes:
REQ_ID [int] = 2
USER_REQ_ID [int] = -1
TM_SERVER [int] = 1373470691
TM_LENGTH [int] = 190
LONG_VALUE [int] = 0
STRING_VALUE [str] = "0"
[/code]
But i think that the Value is not correct despite i dont receive an error response.
Navigation
[0] Message Index
[#] Next page
Go to full version