POST /files/unzip
This resource is used to extract a .zip file.
All elements of the .zip file folder tree will be recreated inside the device from the root.
You can choose where you want to extract the zip file using the query parameter path-to-extract. (See below for more details)
As to post any files, you need to post your zip file as a multipart/form-data.
If the extraction succeed you will receive a 204 No Content response.
FROM API REVISION 2.0
Fixed issue with the unzip that wasn't working with big files.
If this parameter is not in the request, the Application/Json will be chosen by default. JSON and XML are the most commonly used values.
There are multiple possible values (according the resource):
Located in : Header
Example values : accept:application/json
There are multiple possible values according the resource:
If this parameter is not present during the request, and error 415 Unsupported Media Type will be thrown.
Located in : Header
Example values : content-type:application/json
This parameter is used when you want to POST a zip file inside the controller and extract this zip file to a specific destination. The path can start with a '/' or not.
For example this two examples are valid and will produce the same:
If this parameter is not in the request The file will be extracted from the root.
Located in : Query
Example values : path-to-extract=/folder1/folder2
The Content-Length entity-header field indicates the size of the entity-body.
Located in : Header
Example values : content-length:526