Import Resource

Import Resource

Imports a resource in a given category. The resource binary content should be available as multi-part content (see RFC-2387 for details). Details of working with multi-part resources depend on the used client's HTTP/REST library. For example, in Spring it will look like:

Sample client code:
-------------------
String url = "https://localhost:8281/vco/api/resources/";
MultiValueMap parts = new LinkedMultiValueMap ();
Resource r = new FileSystemResource("D:/path/to/some.vsoconf");
parts.put("file", Arrays.asList(r));
parts.put("categoryId", "828080808080808080808080808080807F818080013217004819830adebdb10ea");
new RestTemplate().postForLocation(url, parts);
-------------------

Request
URI
POST
https:///vco/api/resources
COPY
Query Parameters
string
Optional

Request Body
importAction of type(s) application/x-www-form-urlencoded
Optional
{
    "file": "string"
}
Responses
202

Resource successfully imported

Operation doesn't return any data structure

400

Request is not valid (validation error)

Operation doesn't return any data structure

401

User is not authorized

Operation doesn't return any data structure

404

Cannot find resource category with the specified name

Operation doesn't return any data structure