---
title: "Execute a stored workflow for visible contacts"
description: "Requires verified identity, workspace binding and complete contact visibility validation before dispatch. Released callers may omit requestId and retain legacy single-request and response semantics, including partial-success/manual-duplicate limits. Legacy validation uses 200-row ownership reads and at most 25 visibility checks concurrently; total request latency remains a release gate. Requests with a UUID requestId are limited to 500 contacts and use 24-hour per-contact task keys. New browsers negotiate and use batch-execute-v2; no POST failure is retried through the legacy endpoint."
---

> Documentation Index
> Fetch the complete documentation index at: https://developer.channelautomations.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Channel Automation API › Actions

`POST /api/unified-workflow/batch-execute`

Requires verified identity, workspace binding and complete contact visibility validation before dispatch. Released callers may omit requestId and retain legacy single-request and response semantics, including partial-success/manual-duplicate limits. Legacy validation uses 200-row ownership reads and at most 25 visibility checks concurrently; total request latency remains a release gate. Requests with a UUID requestId are limited to 500 contacts and use 24-hour per-contact task keys. New browsers negotiate and use batch-execute-v2; no POST failure is retried through the legacy endpoint.

## Authentication

Requires one of the following:

- `BearerAuth`, http, header `Authorization`, format `JWT`
- `BackendTriggerAuth`, apiKey, in header, header `X-Trigger-Secret`

## Header parameters

- `X-Workspace-Id` (`post/api/unified-workflow/batch-execute.header.X-Workspace-Id`; string, required)

## Request body

_Required._

- `workflowId` (`post/api/unified-workflow/batch-execute.workflowId`; string, required)
  - format `uuid`
- `workspaceId` (`post/api/unified-workflow/batch-execute.workspaceId`; string, required)
- `contactIds` (`post/api/unified-workflow/batch-execute.contactIds`; array<string>, required)
  - format `uuid`
- `requestId` (`post/api/unified-workflow/batch-execute.requestId`; string, optional) — Optional legacy compatibility; when present reuse for retries and submit at most 500 contacts
  - format `uuid`
- `isTest` (`post/api/unified-workflow/batch-execute.isTest`; boolean, optional)

## Example request

```json
{
  "workflowId": "43c4fa9b-0cbc-4b57-a121-9d7d46a3eaa4",
  "workspaceId": "string",
  "contactIds": [
    "497f6eca-6276-4993-bfeb-53cbbbba6f08"
  ],
  "requestId": "d385ab22-0f51-4b97-9ecd-b8ff3fd4fcb6",
  "isTest": true
}
```

## Code samples

### cURL

```bash
curl --request POST \
  --url https://api.channelautomation.com/api/unified-workflow/batch-execute \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-Workspace-Id: string' \
  --data '
{
  "workflowId": "43c4fa9b-0cbc-4b57-a121-9d7d46a3eaa4",
  "workspaceId": "string",
  "contactIds": [
    "497f6eca-6276-4993-bfeb-53cbbbba6f08"
  ],
  "requestId": "d385ab22-0f51-4b97-9ecd-b8ff3fd4fcb6",
  "isTest": true
}
'
```

### TypeScript

```typescript
const url = 'https://api.channelautomation.com/api/unified-workflow/batch-execute';
const options = {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'X-Workspace-Id': 'string',
    Authorization: 'Bearer <token>'
  },
  body: JSON.stringify({
    workflowId: '43c4fa9b-0cbc-4b57-a121-9d7d46a3eaa4',
    workspaceId: 'string',
    contactIds: ['497f6eca-6276-4993-bfeb-53cbbbba6f08'],
    requestId: 'd385ab22-0f51-4b97-9ecd-b8ff3fd4fcb6',
    isTest: true
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.channelautomation.com/api/unified-workflow/batch-execute"

payload = {
    "workflowId": "43c4fa9b-0cbc-4b57-a121-9d7d46a3eaa4",
    "workspaceId": "string",
    "contactIds": ["497f6eca-6276-4993-bfeb-53cbbbba6f08"],
    "requestId": "d385ab22-0f51-4b97-9ecd-b8ff3fd4fcb6",
    "isTest": True
}
headers = {
    "Content-Type": "application/json",
    "X-Workspace-Id": "string",
    "Authorization": "Bearer <token>"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 200

Existing successful result

### 400

Invalid resource input or workflow override

### 401

Missing or invalid caller identity

### 403

Workspace conflict or contact visibility denied

### 404

Resource not found in the selected workspace

### 502

No submissions confirmed; retry with the same requestId

### 503

Identity


Source: https://developer.channelautomations.com/api/post-api-unified-workflow-batch-execute/index.md
