cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3064
Views
30
Helpful
8
Replies

UCCE Agent API create or delete agents

IsilAlkocoglu
Level 1
Level 1

Hi,

 

Right now UCCE Agent API only allows listing  and editing existing agents. Is there a way to create new agents or deleting the existing ones programatically? 

 

Thanks

8 Replies 8

dekwan
Cisco Employee
Cisco Employee

Hi,

 

Per documentation, I do not see an API to add and delete. But, the web admin UI has the ability to add and delete agents so using the browser's developer tools, I was able to see what happens when these actions are made via the UI.

 

When an agent is added, it uses the Agent API with a POST:

 

URLhttps://<server>/unifiedconfig/config/agent

 

Body (I only inputted mandatory fields): <?xml version="1.0" encoding="UTF-8"?> <agent> <peripheral /> <peripheralSet /> <person> <firstName>test2</firstName> <lastName>test2</lastName> <userName>test2</userName> <loginEnabled>true</loginEnabled> <ssoEnabled>false</ssoEnabled> <password /> <ecePerson>false</ecePerson> </person> <department /> <datacenter /> <agentDeskSettings /> <agentTeam /> <agentAttributes /> <skillGroups /> <defaultSkillGroup /> <supervisor>false</supervisor> <supervisorTeams /> </agent>

 

When an agent is deleted, it uses the Agent API with the id with a DELETE:

 

URL: https://<server>/unifiedconfig/config/agent/<id>

 

Now, I am not sure if this is a documentation bug or if these APIs are not publicly supported, so use this at your own discretion. 

 

Thanx,

Denise

Hi Denise,

 

Thank you so much for the reply. I will be trying out the requests asap, in the meantime we would like to check out the  web admin UI you mentioned. It doesn't seem to be cceadmin page as we don't see any agent adding option on that page. if it's another UI how can we find it?

 

Thanks

Hi,

 

Sorry, I forgot that UCCE doesn't have this web ui. I was using the web ui from PCCE. Either way, they share most of the same APIs so the API should work on UCCE too.

 

If you want to play around with the PCCE admin page, you can get a DevNet sandbox here: https://developer.cisco.com/docs/packaged-contact-center/#!sandbox 

 

Thanx,

Denise

Hi Denise,

 

I've just had the chance to try the API request and below is the error I'm getting:


0000000197: xxxxx: May 28 2021 13:20:43.323 +0300: %CCBU_ajp-bio-127.0.0.1-8009-exec-10-6-REST_API_INFO: User name: xxxxxx, service: agent, role: NonPCCEAdministrator, deployment type: ROUTERLOGGER8000AGENTS, access: UPDATE_ONLY
0000000198: xxxxx: May 28 2021 13:20:43.323 +0300: %CCBU_ajp-bio-127.0.0.1-8009-exec-10-6-REST_API_INFO: %[url=/unifiedconfig/config/agent/]: The specified URL is update-only (no create or delete) for the user xxxxx or user type Administrator

This results in a 405(method not allowed) error.

 

Is there a way we can create a PCCEAdministrator type user on UCCE or if the roles are written in a table, can we update the row accordingly to get create access?

 

Thanks

I do not believe this is possible on UCCE.

 

Although the UCCE 12.6 seems also has an extract about roles when creating / deleting on the Agent API - but I think this is a doc bug.

https://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cust_contact/contact_center/icm_enterprise/icm_enterprise_12_6_1/program/guide/ucce_b_cisco-ucce_developer_guide-12_6_1/ucce_b_cisco-ucce_developer_guide-12_6_1_chapter_0100.html

 

If you want access to PCCE API - you need to be deployed as PCCE.

 

https://developer.cisco.com/docs/packaged-contact-center/#!agent-api-agent-api/agent-api

PCCE Agent API does have create and delete ability. 

In the Role API, when you enable the ManageAgentAttribute or ReSkillAgents subfeature in the accessList parameter for a custom role then the Agent API is provided with Update Only Access instead of Full Access. With Update Only Access, you cannot create and delete an agent using Agent API

 

Gerry

I agree with @Gerry O'Rourke here. The docs gave me false hope, but sadly, looks like UCCE continues to not support POSTing agents, only packaged UCCE supports creating agents via POST requests. 

Hi,

 

UCCE and PCCE share the a lot of the same code base for the REST APIs, but I guess it isn't available for UCCE. I do not have access to a UCCE system so I cannot check myself, but since you are getting an error, I guess it is not available.

 

So since that didn't work, I guess it isn't possible on UCCE to programmatically add/delete agents.

 

THanx,

Denise

darkreverend
Level 1
Level 1

You have to build out a ccmp system to automate agent creation. I can not wrap my head around why Cisco continues to force this on their customers vs building out an add feature to the agent api.