> ## Documentation Index
> Fetch the complete documentation index at: https://docs.theomnibot.io/llms.txt
> Use this file to discover all available pages before exploring further.

# List All Automation Flows via the ChatbotX REST API

> Retrieve a paginated list of all automation flows in your ChatbotX workspace, with optional keyword search to locate specific flows.

Flows are the visual automation building blocks of ChatbotX, defining how your chatbot responds to messages across every connected channel. Use this endpoint to retrieve all flows in your workspace. You can paginate through the results and filter by keyword to find a specific flow by name.

<Info>
  **GET** `/api/v1/flows`
</Info>

## Query Parameters

<ParamField query="page" type="integer">
  The page number to retrieve. Must be `1` or greater. Defaults to `1`.
</ParamField>

<ParamField query="perPage" type="integer">
  Number of flows to return per page. Must be `1` or greater.
</ParamField>

<ParamField query="keyword" type="string">
  Filter flows by name. Returns all flows whose name contains the provided keyword (case-insensitive).
</ParamField>

## Code Examples

<CodeGroup>
  ```bash cURL theme={null}
  curl --request GET \
    --url 'https://app.chatbotx.io/api/v1/flows?page=1&perPage=20' \
    --header 'Authorization: Bearer <token>'
  ```

  ```python Python theme={null}
  import requests

  url = "https://app.chatbotx.io/api/v1/flows"

  params = {"page": 1, "perPage": 20}
  headers = {"Authorization": "Bearer <token>"}

  response = requests.get(url, params=params, headers=headers)
  print(response.json())
  ```

  ```javascript JavaScript theme={null}
  const options = {
    method: 'GET',
    headers: { Authorization: 'Bearer <token>' }
  };

  fetch('https://app.chatbotx.io/api/v1/flows?page=1&perPage=20', options)
    .then(res => res.json())
    .then(res => console.log(res))
    .catch(err => console.error(err));
  ```
</CodeGroup>

## Response

Returns `200 OK` with a `data` array of flow objects.

### Response Fields

<ResponseField name="data" type="array" required>
  Array of flow objects belonging to the workspace.

  <Expandable title="data item fields">
    <ResponseField name="id" type="string" required>
      Unique identifier for the flow.
    </ResponseField>

    <ResponseField name="name" type="string" required>
      Display name of the flow.
    </ResponseField>

    <ResponseField name="status" type="string">
      Publication status of the flow, for example `active` or `draft`.
    </ResponseField>

    <ResponseField name="folderId" type="string | null">
      The folder this flow is organised into, or `null` if it is not in a folder.
    </ResponseField>

    <ResponseField name="workspaceId" type="string">
      The ID of the workspace this flow belongs to.
    </ResponseField>
  </Expandable>
</ResponseField>

### Example Response

```json theme={null}
{
  "data": [
    {
      "id": "301",
      "name": "Welcome New Subscriber",
      "status": "active",
      "folderId": null,
      "workspaceId": "42"
    },
    {
      "id": "302",
      "name": "Support Triage",
      "status": "draft",
      "folderId": "5",
      "workspaceId": "42"
    }
  ]
}
```
