Skip to main content

Update Workflow

This endpoint allows you to update an existing workflow by its unique identifier (ID). if system couldn't find workflow by name system produce 404 not found.

Endpoint: /api/v1/workflows

Method: PUT

Request Body

Media Type: application/json

Body:

{
"id": "string",
"name": "string",
"steps": [
{
"delegate": "enum",
"timeOutInSeconds": 0,
"params": {
"additionalProp1": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
},
"additionalProp2": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
},
"additionalProp3": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
}
}
}
]
}

id (required): id of workflow to update. name (required): The name of workflow. steps: not empty delegate: this parameter means workflow step types timeOutInSeconds: Timeout when the started process step will become failed id no one changes the status to complete params: Parameters dictionary

Responses

200 (OK) The request was successful, and the server has updated the workflow with the provided information.

Body:

{
"message": "string",
"timestamp": "2024-03-29T12:11:40.769Z",
"data": {
"name": "string",
"steps": [
{
"delegate": "GATEKEEPER",
"timeOutInSeconds": 0,
"params": {
"additionalProp1": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
},
"additionalProp2": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
},
"additionalProp3": {
"strValue": "string",
"longValue": "number",
"doubleValue": "number",
"type": "enum"
}
}
}
],
"id": "string"
},
"version": "string"
}

401 (Unauthorized) This response is returned if the request is not authorized.

Body:

{
"message": "Unauthorized request",
"timestamp": "2023-09-28T15:37:14.222Z",
"data": "string",
"version": "string"
}

404 (Not Found) This response is returned if the required resources are not found.

Body:

{
"message": "Not Found",
"timestamp": "2023-09-28T15:37:14.222Z",
"data": "string",
"version": "string"
}

412 (Precondition Failed) This response is returned if a precondition is not met.

Body:

{
"message": "Precondition failed",
"timestamp": "2023-09-28T15:37:14.222Z",
"data": {
"additionalProp1": {},
"additionalProp2": {},
"additionalProp3": {}
},
"version": "string"
}

500 (Internal Server Error) This response is returned if an unexpected internal server error occurs.

Body:

{
"message": "Internal Server Error",
"timestamp": "2023-09-28T15:37:14.223Z",
"data": "string",
"version": "string"
}