> For the complete documentation index, see [llms.txt](https://docs.groundcover.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.groundcover.com/reference/remote-access-and-apis/api-examples/list-workflows.md).

# List Workflows

Get a list of all configured alert workflows with their complete definitions, provider integrations, execution status, and YAML configurations.

### Endpoint

**POST** `/api/workflows/list`

### Authentication

This endpoint requires API Key authentication via the Authorization header.

### Headers

| Header          | Required | Description                    |
| --------------- | -------- | ------------------------------ |
| `Authorization` | Yes      | Bearer token with your API key |
| `Content-Type`  | Yes      | Must be `application/json`     |
| `Accept`        | Yes      | Must be `application/json`     |

### Request Body

This endpoint does not require a request body for the POST method.

**Field Descriptions**

| Field                    | Type        | Description                                                    |
| ------------------------ | ----------- | -------------------------------------------------------------- |
| `workflows`              | array       | Array of workflow objects                                      |
| `id`                     | string      | Unique workflow identifier (UUID)                              |
| `name`                   | string      | Workflow name                                                  |
| `description`            | string      | Workflow description                                           |
| `created_by`             | string      | Email of the workflow creator                                  |
| `creation_time`          | string      | Workflow creation timestamp (ISO 8601)                         |
| `triggers`               | array       | Array of trigger configurations                                |
| `triggers[].type`        | string      | Trigger type (e.g., `"alert"`)                                 |
| `interval`               | number      | Execution interval (typically 0 for alert-triggered workflows) |
| `last_execution_time`    | string/null | Last execution timestamp                                       |
| `last_execution_status`  | string/null | Last execution status (`"success"`, `"error"`, etc.)           |
| `providers`              | array       | Array of integration provider configurations                   |
| `providers[].type`       | string      | Provider type (see provider types below)                       |
| `providers[].id`         | string/null | Provider configuration ID                                      |
| `providers[].name`       | string      | Provider display name                                          |
| `providers[].installed`  | boolean     | Whether provider is installed and configured                   |
| `workflow_raw_id`        | string      | Raw workflow identifier                                        |
| `workflow_raw`           | string      | Complete YAML workflow definition                              |
| `revision`               | number      | Workflow version number                                        |
| `last_updated`           | string      | Last update timestamp (ISO 8601)                               |
| `invalid`                | boolean     | Whether workflow configuration is invalid                      |
| `last_execution_started` | string/null | When last execution started                                    |

### Examples

#### Basic Request

Get all workflows:

```bash
curl -L \
  --request POST \
  --url 'https://api.groundcover.com/api/workflows/list' \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Accept: */*'
```

#### Response Example

```json
{
  "workflows": [
    {
      "id": "12345678-1234-1234-1234-123456789abc",
      "name": "ms-teams-alerts-workflow",
      "description": "Sends an API to MS Teams alerts endpoint",
      "created_by": "user@company.com",
      "creation_time": "2025-07-02T09:42:13.334103Z",
      "triggers": [
        {
          "type": "alert"
        }
      ],
      "interval": 0,
      "last_execution_time": null,
      "last_execution_status": null,
      "providers": [
        {
          "type": "webhook",
          "id": "provider123456789abcdef",
          "name": "teams-integration",
          "installed": true
        },
        {
          "type": "webhook",
          "id": null,
          "name": "backup-teams-integration",
          "installed": false
        }
      ],
      "workflow_raw_id": "teams-webhook",
      "workflow_raw": "id: teams-webhook\ndescription: Sends an API to MS Teams alerts endpoint\ntriggers:\n- type: alert\n  filters:\n  - key: annotations.ms-teams-alerts-workflow\n    value: enabled\nname: ms-teams-alerts-workflow\n...",
      "revision": 11,
      "last_updated": "2025-07-03T08:57:09.881806Z",
      "invalid": false,
      "last_execution_started": null
    },
    {
      "id": "87654321-4321-4321-4321-987654321def",
      "name": "webhook-alerts-workflow",
      "description": "Workflow for sending alerts to custom webhook",
      "created_by": "admin@company.com",
      "creation_time": "2025-06-19T12:49:37.630392Z",
      "triggers": [
        {
          "type": "alert"
        }
      ],
      "interval": 0,
      "last_execution_time": null,
      "last_execution_status": null,
      "providers": [
        {
          "type": "webhook",
          "id": "webhook987654321fedcba",
          "name": "custom-webhook",
          "installed": true
        }
      ],
      "workflow_raw_id": "webhook-alerts",
      "workflow_raw": "id: webhook-alerts\ndescription: Workflow for sending alerts to custom webhook\n...",
      "revision": 2,
      "last_updated": "2025-06-19T12:51:24.643393Z",
      "invalid": false,
      "last_execution_started": null
    }
  ]
}
```


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.groundcover.com/reference/remote-access-and-apis/api-examples/list-workflows.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
