Create Workflow
Creates new workflow.
When a request is sent to this endpoint with "application/octet-stream" or "multipart/form-data" as the value for the Content-Type header this operation is equivalent to "Import/upload a workflow":
Imports a workflow in a given category. The workflow 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 HTTP/REST library. For example, in Spring it will look like:
Sample client code:-------------------String url = "https://localhost:8281/vco/api/workflows/";MultiValueMapparts = new LinkedMultiValueMap ();Resource r = new FileSystemResource("D:/path/to/some.workflow");parts.put("file", Arrays.asList(r));parts.put("categoryId", "");new RestTemplate().postForLocation(url, parts); -------------------
uniqueName
{
"relations": {
"startIndex": 0,
"count": 0,
"total": 0,
"link": [
{
"rel": "string",
"type": "string",
"attributes": [
{
"name": "string",
"displayName": "string",
"value": "string",
"displayValue": "string"
}
],
"href": "string"
}
]
},
"id": "string",
"name": "string",
"version": "string",
"description": "string",
"href": "string",
"schema-workflow": {
"description": "string",
"position": {
"y": "number",
"x": "number"
},
"input": {
"param": [
{
"description": "string",
"name": "string",
"type": "string"
}
]
},
"output": {
"param": [
{
"description": "string",
"name": "string",
"type": "string"
}
]
},
"attrib": [
{
"name": "string",
"type": "Example types are: SecureString, MimeAttachment, Regexp, Array/VC:VirtualMachine, boolean, string and etc.",
"description": "string",
"scope": "string",
"updated": false,
"encrypt-value": false
}
],
"presentation": {
"desc": "string",
"p-step": [
{
"title": "string",
"desc": "string",
"p-group": [
{
"title": "string",
"desc": "string",
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-group": [
{
"title": "string",
"desc": "string",
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
},
"schemaLocation": "string",
"id": "string",
"version": "string",
"restartMode": 0,
"resumeFromFailedMode": 0,
"display-name": "string",
"category-id": "string",
"ref-types": "string",
"error-handler": [
{
"position": {
"y": "number",
"x": "number"
},
"name": "string",
"throw-bind-name": "string"
}
],
"workflow-item": [
{
"description": "string",
"position": {
"y": "number",
"x": "number"
},
"runtime": "string",
"script": {
"encoded": false,
"text": "string"
},
"conditions": {
"condition": [
{
"name": "string",
"type": "string",
"comparator": "string",
"label": "string",
"text": "string"
}
]
},
"condition": [
{
"name": "string",
"type": "string",
"comparator": "string",
"label": "string",
"text": "string"
}
],
"reference": {
"id": "string",
"type": "string"
},
"presentation": {
"desc": "string",
"p-step": [
{
"title": "string",
"desc": "string",
"p-group": [
{
"title": "string",
"desc": "string",
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-group": [
{
"title": "string",
"desc": "string",
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-param": [
{
"desc": "string",
"name": "string",
"pqual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
}
],
"p-qual": [
{
"kind": "string",
"name": "string",
"type": "string",
"text": "string"
}
]
},
"name": "string",
"type": "string",
"color": "string",
"interaction": "string",
"comparator": 0,
"environment": {
"id": "string",
"name": "string"
},
"display-name": "string",
"in-binding": {
"bind": [
{
"description": "string",
"name": "string",
"type": "string",
"export-name": "string"
}
]
},
"out-binding": {
"bind": [
{
"description": "string",
"name": "string",
"type": "string",
"export-name": "string"
}
]
},
"iteration-catch-block": {
"script": {
"encoded": false,
"text": "string"
}
},
"workflow-subelements-list": {
"workflow-subelement": [
{
"name": "string",
"linked-workflow-id": "string",
"display-name": "string",
"in-binding": {
"bind": [
{
"description": "string",
"name": "string",
"type": "string",
"export-name": "string"
}
]
},
"out-binding": {
"bind": [
{
"description": "string",
"name": "string",
"type": "string",
"export-name": "string"
}
]
}
}
]
},
"out-name": "string",
"alt-out-name": "string",
"catch-name": "string",
"throw-bind-name": "string",
"end-mode": "string",
"script-module": "string",
"business-status": "string",
"prototype-id": "string",
"content-mode": "string",
"launched-workflow-id": "string",
"linked-workflow-id": "string",
"validation-message": "string"
}
],
"workflow-note": [
{
"description": "string",
"x": "number",
"y": "number",
"w": "number",
"h": "number",
"color": "string"
}
],
"root-name": "string",
"object-name": "string",
"icon-id": "string",
"api-version": "string",
"allowed-operations": "string",
"editor-version": "string"
},
"inputParameters": [
{
"name": "string",
"type": "Example types are: SecureString, MimeAttachment, Regexp, Array/VC:VirtualMachine, boolean, string and etc.",
"description": "string",
"scope": "string",
"updated": false,
"encrypt-value": false
}
],
"outputParameters": [
{
"name": "string",
"type": "Example types are: SecureString, MimeAttachment, Regexp, Array/VC:VirtualMachine, boolean, string and etc.",
"description": "string",
"scope": "string",
"updated": false,
"encrypt-value": false
}
],
"customized-icon": false,
"category-id": "string"
}
relations
id
name
version
description
href
schema-workflow
inputParameters
outputParameters
customized-icon
category-id
Workflow successfully created
"WsWorkflow Object"
relations
id
name
version
description
href
schema-workflow
inputParameters
outputParameters
customized-icon
category-id
The request is invalid
"WsWorkflow Object"
relations
id
name
version
description
href
schema-workflow
inputParameters
outputParameters
customized-icon
category-id
The user is not authorized
"WsWorkflow Object"
relations
id
name
version
description
href
schema-workflow
inputParameters
outputParameters
customized-icon
category-id
curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{}' https://{api_host}/vco/api/workflows