Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

UCCX Script download from Rest API

I have been facing the issue When I download the script from the rest api

I am doing this "http://uccx-server/adminapi/script/download/mum.aef" and I have been getting this response from the server.

<apiErrors>
<apiError>
<errorData>ServerError</errorData>
<errorMessage>Missing domain: pathname mum.aef</errorMessage>
<errorType/>
</apiError>
</apiErrors>
The file is existed in the root path. Even if I tired to download sub aef file facing the same issues.
Everyone's tags (1)
2 REPLIES
New Member

I have the exact same problem

I have a similar problem: using a PowerShell function, I am able to download prompts from the UCCx server but it does not work when it comes to:

  • Documents,
  • Scripts.

The function is global, e.g. I only pass the download type as a parameter ("prompt" or "script" or "document") so I am sure my URIs comply with the CCX dev guide.

If I try to download a document through a browser:

http://server_IP/adminapi/document/download/fr_FR/Printemps/FILE.xml

I get an HTTP 404 Not Found Error even though I can see the file in this folder.

If I try to download a script through a browser:

http://server_IP/adminapi/script/download/Site/Service.aef

I get an HTTP 500 Internal Server Error even though I can see the script in this folder.

Any idea?


Edit: If I collect a trace of the request / response, I can see that the UCCx server is sending the following error for a script:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<apiErrors>

<apiError>

<errorData>Internal Server Error</errorData>

<errorMessage>The server encountered an unexpected condition which prevented it from fulfilling the request</errorMessage>

<errorType>500</errorType>

</apiError>

</apiErrors>

And for a document:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<apiErrors>

<apiError>

<errorData>Not Found</errorData>

<errorMessage>Specified Resource does not exist</errorMessage>

<errorType>InstanceNotFound</errorType>

</apiError>

</apiErrors>

New Member

Ok so after many tests I was

Ok so after many tests I was able to successfully download a script.

From what I can tell, the URL needs somehow to be different from a prompt download even if the developers guide tells the contrary:

  • The "default" keyword in the developers guide URL MUST be written even though it is not the case for a prompt download.
  • The keyword MUST be preceded by a double slash: "//"
  • The path to the file has to be added after the keyword.

So for example if I want to download the Service.aef script mentioned above, the URL must be:

http://server_IP/adminapi/script/download//default/Site/Service.aef

Instead of:

http://server_IP/adminapi/script/download/Site/Service.aef

I think the developers guide needs to be updated to reflect this.

As for a document download, unfortunately it seems to be unavailable using the REST API.

Any comment appreciated on this!

186
Views
0
Helpful
2
Replies
CreatePlease to create content