> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.brevo.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.brevo.com/_mcp/server.

# Get an automation workflow

GET https://api.brevo.com/v3/automation/workflows/{workflowId}

Returns how an automation workflow is built: its name, status, `editor_url` (the link that opens it in the Brevo automation editor), re-entry, and its triggers and steps in order, with their settings under the same names as `POST /automation/workflows` takes. It also returns `version`, which `PUT /automation/workflows/{workflowId}` needs.

Step IDs are the ones Brevo assigned, not the labels sent at creation. Secrets are never returned: webhook `auth` and `headers` are left out, and a webhook `url` reads back as its origin only (`https://host`), because its path and query can hold a secret. Settings that are not stored are left out, and a trigger with `incomplete: true` (a custom event with no event picked, or a list trigger with no list) starts nothing. A `go_to_step` reads back with `next: null` and `go_to_step.step`; a `start_another_workflow` with the target's `workflow_name` and `step_name`; a `percentage_split` as `split.variants` and as `percentage_split`. Each email step's `message` has the `template_name` and `subject` of the email it sends.

To edit a workflow, call this with `format=request`: `request` is the body to edit and send to `PUT /automation/workflows/{workflowId}`, with the integer IDs of the existing triggers and steps.

The read view also returns steps set in the Brevo editor that the API cannot create, such as conditions and WhatsApp messages; their `type` is listed in the schema.

Reference: https://developers.brevo.com/reference/get-workflow

## Authentication

- `api-key` header (required) — The API key should be passed in the request headers as `api-key` for authentication.
- `Authorization` header (bearer token, required) — OAuth 2.0 client_credentials (machine-to-machine) grant. Exchange your app's client_id/client_secret for a short-lived Bearer token.

## Request

### Path parameters

- `workflowId` (long, required) — ID of the automation workflow

### Query parameters

- `format` (enum, optional) — `request` returns the workflow as an editable body for `PUT /automation/workflows/{workflowId}` (`version`, `request`, `templates`, `unsupported`, `preserved`) instead of the read view.
  - Allowed values: `request`

## Response

### 200

The workflow; with `format=request`, as an editable body

- `Automation_getWorkflow_Response_200`
  - automationWorkflowDefinition: automationWorkflowDefinition
  - automationWorkflowEditable: automationWorkflowEditable

## Errors

### 401 Unauthorized Error

Authentication failed

- `message` (string, required) — Readable message associated to the failure
- `code` (string, optional) — Error code displayed in case of a failure

### 403 Forbidden Error

The API key or OAuth token is not allowed to read automations: the OAuth token lacks the `automation:read` scope, or the API key is restricted.

- `message` (string, required) — Readable message associated to the failure
- `code` (string, optional) — Error code displayed in case of a failure

### 404 Not Found Error

No automation with this ID in the account

- `message` (string, required) — Readable message associated to the failure
- `code` (string, optional) — Error code displayed in case of a failure

## Types

### automationWorkflowDefinition

An automation workflow as `GET /automation/workflows/{workflowId}` returns it

- `id` (long, required) — ID of the automation
- `name` (string, required) — Name of the automation
- `version` (string, required) — Identifies the current content of the automation; `PUT /automation/workflows/{workflowId}` needs it
- `status` (enum, required) — active, pause, or inactive (a draft or a stopped automation)
  - Allowed values: `active`, `pause`, `inactive`
- `triggers` (list of AutomationWorkflowDefinitionTriggersItems, required) — Entry triggers, each with `id`, `type`, `source` and `reentry` `{"allowed", "delay"}`, plus the trigger's settings with the same names as in `POST /automation/workflows`, when they are stored: `lists` \[`{"id", "name"}`], `segment` `{"id", "name"}`, `schedule` `{"time", "timezone", "interval", "day_of_week", ...}`, `attribute`, `when` and `offset` `{"duration", "unit"}` for anniversary, `event_name` for a custom event. A custom event trigger has type `custom_event`, whatever editor made it. A setting that is not stored is left out.
- `steps` (list of AutomationWorkflowDefinitionStepsItems, required) — Steps in path order, each with `id`, `type` and `next` (the following step id, or null). A delay reads back as `wait` `{"mode", "duration"}`; an email, SMS, WhatsApp or push message as `message` `{"channel", "template_id"}`, and an email `message` also has `template_name` and `subject`, the name and subject of the template the step sends (its copy; left out when the template is missing), and `source_template_id` when known. Conditions and splits carry their branches, and their own `next` is null. A `percentage_split` reads back both as `split.variants` and as a `percentage_split` object, in the shape create and update take. The settings of a step are in the object named after its type, with the same names as in `POST /automation/workflows`, when they are stored: `add_to_list` and `remove_from_list` `{"lists"}`, `update_contact_attribute` `{"attribute", "action", "type", "value", "index", "date_mode", "operation"}`, `call_webhook` `{"url", "include_contact_attributes", "include_event_data"}`, `send_sms` `{"sender", "content" or "template_id", "sms_type", "send_window", "event_data", ...}`, `send_email` `{"tags", "frequency_cap", "send_window", "cc", "bcc", "event_data"}` next to its `message`, `blocklist_contact` `{"scope", "senders"}`, `delete_contact` `{}`, `start_another_workflow` `{"workflow_id", "step_id", "workflow_name", "step_name"}` and `go_to_step` `{"step"}`. Webhook auth and headers are never returned, and a webhook `url` reads back as its origin only (`https://host`): its path and query can hold a secret. A setting that is not stored is left out.
- `description` (string, optional) — Internal description of the automation, when it has one
- `editor` (string, optional) — Editor the automation was built with
- `editor_url` (string, optional) — Link that opens the automation in the Brevo automation editor; left out when not available

### automationWorkflowEditable

An automation workflow as an editable body, returned with `format=request`

- `version` (string, required) — The workflow's current version, also inside `request`
- `request` (map from string to any, required) — The body of `PUT /automation/workflows/{workflowId}`, with `version`, ready to edit. It keeps each send\_email step's source `template_id`, so sending it back unchanged keeps the step's copy of the template.
- `templates` (map from string to AutomationWorkflowEditableTemplates, required) — For each send_email step, keyed by its id in `request`: the email it sends
- `unsupported` (list of AutomationWorkflowEditableUnsupportedItems, required) — Parts of the workflow the API cannot express. When not empty, the workflow can only be edited in the Brevo automation editor.
- `preserved` (AutomationWorkflowEditablePreserved, required) — Stored settings that `request` does not show and that an update keeps

### AutomationWorkflowDefinitionTriggersItems

- `id` (integer, optional) — Trigger id. Send it back as the trigger's `id` in `PUT /automation/workflows/{workflowId}` to keep the trigger.
- `type` (string, optional) — Trigger type; `custom_event` for a custom event, whatever editor made it
- `source` (string, optional) — Where the event comes from, for example custom
- `reentry` (AutomationWorkflowDefinitionTriggersItemsReentry, optional) — Whether a contact can enter the automation again. The same for every trigger of the workflow.
- `event_name` (string, optional) — custom_event only. The custom event's name.
- `lists` (list of map from string to any, optional) — Lists that start the automation, each `{"id", "name"}`
- `segment` (map from string to any, optional) — The segment `{"id", "name"}`
- `schedule` (map from string to any, optional) — When the trigger runs, as written to `POST /automation/workflows` (day_of_week is ISO, 1=Monday ... 7=Sunday)
- `attribute` (string, optional) — anniversary only. The date attribute.
- `when` (string, optional) — anniversary only. same_day, before_the_date or after_the_date.
- `offset` (map from string to any, optional) — anniversary only. `{"duration", "unit"}`.
- `incomplete` (boolean, optional) — True when the trigger was saved in the editor without its required choice (a custom event with no event, a list trigger with no list). It starts nothing, and the workflow cannot be edited through the API until it is completed in the editor.

### AutomationWorkflowDefinitionStepsItems

- `id` (integer, required) — Step id assigned by Brevo
- `type` (string, required) — Step type. Besides the types `POST /automation/workflows` accepts, the read view returns the types set in the Brevo editor: wait_until_event, conditional_split, smart_split, send_whatsapp, send_push, notify_by_email, send_one_to_one_email, assign_user, update_company_attribute, create_task, create_deal, duplicate_deal, update_deal_attribute, and `other` for any other type. More types may be added.
- `next` (integer, required, nullable) — Id of the step that runs after this one; null at the end of a path, and for a step that branches

### AutomationWorkflowEditableTemplates

- `template_id` (long, optional) — The template the step sends (its copy)
- `name` (string, optional) — Left out when the template is missing
- `subject` (string, optional) — Left out when the template is missing
- `source_template_id` (integer, optional) — The template it was copied from, when known

### AutomationWorkflowEditableUnsupportedItems

- `kind` (string, optional) — trigger, step, condition or workflow
- `id` (integer, optional)
- `type` (string, optional)
- `reason` (string, optional)

### AutomationWorkflowEditablePreserved

Stored settings that `request` does not show and that an update keeps

- `conditions` (list of AutomationWorkflowEditablePreservedConditionsItems, optional) — Exit and reset conditions of the workflow
- `settings` (list of AutomationWorkflowEditablePreservedSettingsItems, optional) — For each trigger or step of `request`, the stored settings it does not show

### AutomationWorkflowDefinitionTriggersItemsReentry

Whether a contact can enter the automation again. The same for every trigger of the workflow.

- `allowed` (boolean, optional) — False: each contact runs the workflow at most once, ever
- `delay` (string, optional) — Minimum time before a contact can enter again, ISO 8601; left out when none

### AutomationWorkflowEditablePreservedConditionsItems

- `kind` (enum, optional)
  - Allowed values: `exit`, `reset`
- `id` (integer, optional)
- `type` (string, optional) — The condition's stored event name

### AutomationWorkflowEditablePreservedSettingsItems

- `path` (string, optional) — Path of the trigger or step in `request`, for example steps[2]
- `id` (integer, optional)
- `fields` (list of string, optional)

## Examples

**Response**

```json
{
  "description": "string",
  "editor": "string",
  "editor_url": "string",
  "id": 1,
  "name": "string",
  "status": "active",
  "steps": [
    {
      "id": 1,
      "next": 1,
      "type": "string"
    }
  ],
  "triggers": [
    {
      "attribute": "string",
      "event_name": "string",
      "id": 1,
      "incomplete": true,
      "lists": [
        {}
      ],
      "offset": {},
      "reentry": {
        "allowed": true,
        "delay": "string"
      },
      "schedule": {},
      "segment": {},
      "source": "string",
      "type": "string",
      "when": "string"
    }
  ],
  "version": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.brevo.com/v3/automation/workflows/1"

headers = {"api-key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.brevo.com/v3/automation/workflows/1';
const options = {method: 'GET', headers: {'api-key': '<api-key>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.brevo.com/v3/automation/workflows/1"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("api-key", "<api-key>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.brevo.com/v3/automation/workflows/1")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["api-key"] = '<api-key>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.brevo.com/v3/automation/workflows/1")
  .header("api-key", "<api-key>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.brevo.com/v3/automation/workflows/1', [
  'headers' => [
    'api-key' => '<api-key>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.brevo.com/v3/automation/workflows/1");
var request = new RestRequest(Method.GET);
request.AddHeader("api-key", "<api-key>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["api-key": "<api-key>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.brevo.com/v3/automation/workflows/1")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```