05-31-2016 09:32 AM - edited 03-14-2019 04:10 PM
Hi. We use skills to determine which CSQ our agents are assigned to. We regularly add and remove skills depending upon our particular needs for different times of the week. For example, during the week, we have dedicated people on our billing line but on the weekends, some people need to pull double-duty and answer both billing and technical support.
At the moment, the supervisor needs to manually add and remove skills (to add and remove agents from different CSQs). I would like to automate this process. We have a schedule that I can make machine-actionable but I can't seem to find a way to programmatically add/remove skills. I know what tables the skills mappings are stored in but a) I'm not sure it's cool just to mess with those tables and b) the user I use -- uccxhruser -- doesn't have write privs to those tables.
Does anyone have any thoughts on this?
Thanks
Solved! Go to Solution.
05-31-2016 02:41 PM
Depending on your version you can use built in REST API to make these changes. Check out Cisco dev links:
https://developer.cisco.com/site/uccxapi/overview/
05-31-2016 02:48 PM
Indeed, I believe the REST API was opened on CCX 9.0, but I don't recall exactly. If you are on anything older this will not be an option, but might be a reason for an upgrade :-)
05-31-2016 02:41 PM
Depending on your version you can use built in REST API to make these changes. Check out Cisco dev links:
https://developer.cisco.com/site/uccxapi/overview/
05-31-2016 02:46 PM
Thank you. I'll track down that lead. I've been doing everything with just database queries so far. This opens up possibilities.
05-31-2016 02:48 PM
Indeed, I believe the REST API was opened on CCX 9.0, but I don't recall exactly. If you are on anything older this will not be an option, but might be a reason for an upgrade :-)
05-31-2016 02:49 PM
We're on 10.x so this should be a good place to start.
06-01-2016 06:23 PM
As it turns out, there does not appear to be a way to add skills to resource mappings in the 10.6 API. It's strange because you can do a lot of other things (e.g. add a skill in general). My next step is to look at the Finesse APIs.
06-02-2016 06:36 AM
Unless I'm missing something, it seems like you can't even determine who is ready and not --stuff that you can easily do with the database queries.
06-07-2016 06:40 AM
So, I ultimately got this working which was particularly pleasing after Cisco support told me it was impossible (yes, I know that the TAC doesn't support developer questions).
Anyway, the answer was to pull down the JSON structure associated with an individual "resource", e.g.
https://UCCXHOST/adminapi/resource/USER
Alter the JSON to what you want (adding and removing skills) and sending it back as a PUT.
BUT, beware, there appears to be a bug with their JSON parser in that the order of the data elements matters. I've called that in. According to the JSON RFC, order shouldn't matter.
05-16-2018 07:55 AM
Would you be able to elaborate on which order this needs to be in? I am currently having this same issue - I can find that I can PUT this into a REST web browser plugin fine - with my JSON with a PUT; But as soon as I introduce this to my python script - it errors out with...
name [null] is not a valid","errorMessage":"Not a valid link uri","errorType":"InvalidInput"}]}
10-29-2019 09:04 AM
I also have been tasked with getting this done. Being this is a rather old thread wonder if I can give it a bump!
12-05-2019 05:56 AM
I developed a way to bulk update skills. It has some caveats but I created it to suit my needs. I took a very backward approach that worked to format the JSON for the upload, and used pandas and an csv to hold the data.
12-05-2019 06:28 AM
I figured this out as well using Python and XML. don't care to much for Java script.
Let me know if you would like to see the code.
12-05-2019 10:25 AM
sflanagan,
I would like to see the code please. I have been working on a few similar things.
12-05-2019 11:14 AM
I PM'd you a question. the short answer is sure. Its not finished yet. but if you have a GitHub account. PM me the account.
Thanks,
Stephen
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide