Genesys CTI User Forum
Genesys CTI User Forum => Genesys CTI Technical Discussion => Topic started by: Dimitry on June 01, 2017, 12:58:44 PM
-
Hi,
I am using the platform SDK to retrieve the configuration information . I am able to apply the filter for a particular used and able to retrieve the ConfObjectCollection. The SkillDBID of the agent is show in the response.
Now I want to pass the SkillDBID as an input and get the Skill name.
How could I do that ?? Any help please.
-
Try using the Config Object Model (COM) Application block it will do all the hard work for you..
[code]CfgPersonQuery query= new CfgPersonQuery();
query.UserName = "Pete";
query.TenantDbid = 1;
CfgPerson person = confService.RetrieveObject<CfgPerson>(query);
foreach (CfgSkillLevel level in person.AgentInfo.SkillLevels)
{
if (level.Skill.Name == "CustomerService")
{
.......[/code]
-
Thanks Pete
I tried the same in Java.
CfgPersonQuery query= new CfgPersonQuery();
query.setUserName("XXXXX");
CfgPerson person = confService.retrieveObject(query);
It still returns me Skill DBID and not skill name.
-
You can get the skillname using the code below:
[code] CfgAgentInfo agentInfo = person.getAgentInfo();
if (null != agentInfo) {
Collection<CfgSkillLevel> skills = agentInfo.getSkillLevels();
if (null != skills) {
for (CfgSkillLevel skill : skills) {
log.debug(skill.getSkill().getName() + " : " + skill.getLevel());
}
}
}[/code]