> For the complete documentation index, see [llms.txt](https://sitasys-ag.gitbook.io/evalink-talos/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sitasys-ag.gitbook.io/evalink-talos/management-api/workflows.md).

# Manage workflows

## Introduction

Managed workflows allow you to define & manage your workflows globally and selectively link them to specific sites.

Global workflows are only used as a fallback option when there is no workflow defined on-site level for a specific.

## create a new workflow from a template

<mark style="color:green;">`POST`</mark> `https://talos-app.io/api/workflow-service/workflows/create-from-template`

Use this endpoint to create a new workflow from a new template.

#### Headers

| Name          | Type   | Description                              |
| ------------- | ------ | ---------------------------------------- |
| Authorization | string | Use "Bearer" followed by your API Token. |

#### Request Body

| Name               | Type   | Description                             |
| ------------------ | ------ | --------------------------------------- |
| userId             | string | The needed userId                       |
| workflowTemplateId | string | The Id of the template you will create. |
| alarmId            | string | The alarmId related to this template.   |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}

## list the workflow's template by companyId

<mark style="color:blue;">`GET`</mark> `https://talos-app.io/api/workflow-service/workflow-templates/search/findByCompanyId{companyId}`

Use this endpoint to get the templates by their companyId

#### Path Parameters

| Name      | Type   | Description                   |
| --------- | ------ | ----------------------------- |
| companyId | string | The companyId of the company. |

#### Headers

| Name          | Type   | Description                             |
| ------------- | ------ | --------------------------------------- |
| Authorization | string | Use "Bearer" followed by your API-Token |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}

## list the workflow by the alarmId

<mark style="color:blue;">`GET`</mark> `https://talos-app.io/api/workflow-service/workflows/search/findByAlarmId`

Use this endpoint to get workflows by their alarmId.&#x20;

#### Path Parameters

| Name          | Type   | Description                             |
| ------------- | ------ | --------------------------------------- |
| Authorization | string | Use "Bearer" followed by your API-Token |

#### Query Parameters

| Name    | Type   | Description                      |
| ------- | ------ | -------------------------------- |
| alarmId | string | The alarmId of the needed alarm. |

{% tabs %}
{% tab title="200 " %}

```
{
  "alarmAttachmentStrategy": "NEVER",
  "alarmId": "string",
  "automated": true,
  "companyId": "string",
  "createdDate": 0,
  "deviceGroupId": "string",
  "deviceId": "string",
  "editingUserId": "string",
  "entityStatus": "string",
  "id": "string",
  "links": {
    "empty": true
  },
  "outcome": "string",
  "outcomeList": "string",
  "parkedUntil": 0,
  "reportingMode": "EVENT_LOG_ONLY",
  "rootBlockId": "string",
  "shortId": "string",
  "workflowStatus": "ABORTED",
  "workflowTemplateId": "string",
  "workflowTemplateName": "string"
}
```

{% endtab %}
{% endtabs %}

## delete the workflow by its id

<mark style="color:red;">`DELETE`</mark> `https://talos-app.io/api/workflow-service/workflows/{id}`

Use this endpoint to delete a workflow using its id.

#### Path Parameters

| Name | Type   | Description   |
| ---- | ------ | ------------- |
| id   | string | The needed id |

#### Headers

| Name          | Type   | Description                             |
| ------------- | ------ | --------------------------------------- |
| Authorization | string | Use "Bearer" followed by your API-Token |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}

## update the workflow by its id

<mark style="color:purple;">`PATCH`</mark> `https://talos-app.io/api/workflow-service/workflows/{id}`

It updates the workflow by its Id.

#### Path Parameters

| Name | Type   | Description   |
| ---- | ------ | ------------- |
| id   | string | The needed Id |

#### Headers

| Name          | Type   | Description                            |
| ------------- | ------ | -------------------------------------- |
| Authorization | string | Use "Bearer" followed by the API-Token |

#### Request Body

| Name      | Type   | Description           |
| --------- | ------ | --------------------- |
| deviceId  | string | The Id of the device  |
| companyId | string | The Id of the company |
| alarmId   | string | The Id of the alarm   |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}

```
{
  "alarmAttachmentStrategy": "NEVER",
  "alarmId": "string",
  "automated": true,
  "companyId": "string",
  "createdDate": 0,
  "deviceGroupId": "string",
  "deviceId": "string",
  "editingUserId": "string",
  "id": "string",
  "outcome": "string",
  "outcomeList": "string",
  "parkedUntil": 0,
  "reportingMode": "EVENT_LOG_ONLY",
  "rootBlockId": "string",
  "shortId": "string",
  "workflowStatus": "ABORTED",
  "workflowTemplateId": "string",
  "workflowTemplateName": "string"
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://sitasys-ag.gitbook.io/evalink-talos/management-api/workflows.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
