Skip to main content
NICE CXone Expert

We will be closed on Wednesday, December 25th in observance of Christmas

Expert Success Center

archive/files/{fileid}/{filename} (GET)

Overview

Retrieve file attachment content

  • REST Method: GET
  • Method Access: public

Uri Parameters

Name Type Description
filename string "=" followed by a double uri-encoded file name
fileid int identifies a file by ID

Query Parameters

Name Type Description
authenticate bool? Force authentication for request (default: false)

Return Codes

Name Value Description
OK 200 The request completed successfully
Bad Request 400 Invalid input parameter or request body
Forbidden 403 Administrator access is required
Not Found 404 Requested file could not be found in the archive

Message Format

None

Implementation Notes

This feature is identical to GET:archive/files/{fileid}; refer to this feature for more information.  The {filename} uri parameter is not used and is intended for informational purposes only.

Curl Code Sample: Retrieve an Archived File

This feature is identical to the one described here, but allows a user to append an arbitrary filename to the end of the path. The purpose of this is to extend file download support to some browsers that use the last value in the path as the downloaded file name.

Sample Code

If the user wants to download an archived file as "foo.abc"

curl -u admin:password -i http://mindtouch.address/@api/deki/archive/files/1/=foo.abc

Implementation notes 

curl flags

-u
Provides external user authentication.
-i
Outputs the HTTP response headers. Useful for debugging.

Permissions

ADMIN permission is required to execute above command.

Response

Note that a file, not an XML document, is returned. So if an image or any non-text file is requested, a bunch of junk will very possibly be returned to the console.

Archived Files

To view a list of archived files, follow the instructions here.

 

  • Was this article helpful?