curl --request POST \
--url https://api.example.com/api/public/tools/create_flow_plan \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"flow": {
"root": {
"id": "<string>",
"delay": "<string>",
"payload": {},
"next": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
}
},
"on_false": "<unknown>"
},
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
},
"name": "<string>",
"options": {
"is_exclusion_check_required": true,
"use_hubspot_if_connected": true,
"is_click_tracking_enabled": true,
"is_open_tracking_enabled": true,
"is_enrich_phone_if_not_provided": true,
"push_call_tasks_only_if_phone_exists": true,
"ignore_personal_email_accounts": true,
"prompt": "<string>",
"is_push_to_hubspot_call_tasks": true,
"is_push_to_hubspot_manual_tasks": true,
"is_push_to_hubspot_approve_tasks": true,
"is_enrich_hubspot": true,
"is_enrich_prospects": true,
"is_enrich_companies": true,
"is_enrich_email_if_not_provided": true,
"is_track_emails_in_hubspot": true,
"only_enrich_phone_if_call_task_present": true,
"priority": 123
},
"aiQualification": {
"is_enabled": true,
"threshold": 123,
"prospect_criteria": "<string>",
"company_criteria": "<string>",
"disqualify_criteria": "<string>"
},
"candidates": [
{
"userId": "<string>",
"emailAccountIds": [
"<string>"
]
}
]
},
"audienceId": null,
"processingStrategy": null,
"publish": false,
"extendedResponse": false,
"awaitingLimit": 10
}
'import requests
url = "https://api.example.com/api/public/tools/create_flow_plan"
payload = {
"flow": {
"root": {
"id": "<string>",
"delay": "<string>",
"payload": {},
"next": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
}
},
"on_false": "<unknown>"
},
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
},
"name": "<string>",
"options": {
"is_exclusion_check_required": True,
"use_hubspot_if_connected": True,
"is_click_tracking_enabled": True,
"is_open_tracking_enabled": True,
"is_enrich_phone_if_not_provided": True,
"push_call_tasks_only_if_phone_exists": True,
"ignore_personal_email_accounts": True,
"prompt": "<string>",
"is_push_to_hubspot_call_tasks": True,
"is_push_to_hubspot_manual_tasks": True,
"is_push_to_hubspot_approve_tasks": True,
"is_enrich_hubspot": True,
"is_enrich_prospects": True,
"is_enrich_companies": True,
"is_enrich_email_if_not_provided": True,
"is_track_emails_in_hubspot": True,
"only_enrich_phone_if_call_task_present": True,
"priority": 123
},
"aiQualification": {
"is_enabled": True,
"threshold": 123,
"prospect_criteria": "<string>",
"company_criteria": "<string>",
"disqualify_criteria": "<string>"
},
"candidates": [
{
"userId": "<string>",
"emailAccountIds": ["<string>"]
}
]
},
"audienceId": None,
"processingStrategy": None,
"publish": False,
"extendedResponse": False,
"awaitingLimit": 10
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
flow: {
root: {
id: '<string>',
delay: '<string>',
payload: {},
next: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: '<unknown>',
on_false: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: '<unknown>',
on_false: '<unknown>'
}
},
on_false: '<unknown>'
},
expression: '<string>',
on_true: '<unknown>',
on_false: '<unknown>'
},
name: '<string>',
options: {
is_exclusion_check_required: true,
use_hubspot_if_connected: true,
is_click_tracking_enabled: true,
is_open_tracking_enabled: true,
is_enrich_phone_if_not_provided: true,
push_call_tasks_only_if_phone_exists: true,
ignore_personal_email_accounts: true,
prompt: '<string>',
is_push_to_hubspot_call_tasks: true,
is_push_to_hubspot_manual_tasks: true,
is_push_to_hubspot_approve_tasks: true,
is_enrich_hubspot: true,
is_enrich_prospects: true,
is_enrich_companies: true,
is_enrich_email_if_not_provided: true,
is_track_emails_in_hubspot: true,
only_enrich_phone_if_call_task_present: true,
priority: 123
},
aiQualification: {
is_enabled: true,
threshold: 123,
prospect_criteria: '<string>',
company_criteria: '<string>',
disqualify_criteria: '<string>'
},
candidates: [{userId: '<string>', emailAccountIds: ['<string>']}]
},
audienceId: null,
processingStrategy: null,
publish: false,
extendedResponse: false,
awaitingLimit: 10
})
};
fetch('https://api.example.com/api/public/tools/create_flow_plan', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/public/tools/create_flow_plan",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'flow' => [
'root' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => [
],
'next' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => '<unknown>'
]
],
'on_false' => '<unknown>'
],
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => '<unknown>'
],
'name' => '<string>',
'options' => [
'is_exclusion_check_required' => true,
'use_hubspot_if_connected' => true,
'is_click_tracking_enabled' => true,
'is_open_tracking_enabled' => true,
'is_enrich_phone_if_not_provided' => true,
'push_call_tasks_only_if_phone_exists' => true,
'ignore_personal_email_accounts' => true,
'prompt' => '<string>',
'is_push_to_hubspot_call_tasks' => true,
'is_push_to_hubspot_manual_tasks' => true,
'is_push_to_hubspot_approve_tasks' => true,
'is_enrich_hubspot' => true,
'is_enrich_prospects' => true,
'is_enrich_companies' => true,
'is_enrich_email_if_not_provided' => true,
'is_track_emails_in_hubspot' => true,
'only_enrich_phone_if_call_task_present' => true,
'priority' => 123
],
'aiQualification' => [
'is_enabled' => true,
'threshold' => 123,
'prospect_criteria' => '<string>',
'company_criteria' => '<string>',
'disqualify_criteria' => '<string>'
],
'candidates' => [
[
'userId' => '<string>',
'emailAccountIds' => [
'<string>'
]
]
]
],
'audienceId' => null,
'processingStrategy' => null,
'publish' => false,
'extendedResponse' => false,
'awaitingLimit' => 10
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/public/tools/create_flow_plan"
payload := strings.NewReader("{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/public/tools/create_flow_plan")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/public/tools/create_flow_plan")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}"
response = http.request(request)
puts response.read_body{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}Create Flow Plan
Create a reusable flow plan for an audience, list, segment, or multiple recipients.
Detailed usage guidance
- Call get_guide with topic=flow_plan_creation before this tool.
- flow.root is required; omitted options, AI qualification, and candidates use server defaults.
- Do not use this for actions on one specific prospect; call add_dynamic_action once per requested step instead.
- Do not use this when the user names an existing flow; enroll into that flow instead.
- If content uses variables, call get_flow_available_variables first.
curl --request POST \
--url https://api.example.com/api/public/tools/create_flow_plan \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"flow": {
"root": {
"id": "<string>",
"delay": "<string>",
"payload": {},
"next": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
}
},
"on_false": "<unknown>"
},
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
},
"name": "<string>",
"options": {
"is_exclusion_check_required": true,
"use_hubspot_if_connected": true,
"is_click_tracking_enabled": true,
"is_open_tracking_enabled": true,
"is_enrich_phone_if_not_provided": true,
"push_call_tasks_only_if_phone_exists": true,
"ignore_personal_email_accounts": true,
"prompt": "<string>",
"is_push_to_hubspot_call_tasks": true,
"is_push_to_hubspot_manual_tasks": true,
"is_push_to_hubspot_approve_tasks": true,
"is_enrich_hubspot": true,
"is_enrich_prospects": true,
"is_enrich_companies": true,
"is_enrich_email_if_not_provided": true,
"is_track_emails_in_hubspot": true,
"only_enrich_phone_if_call_task_present": true,
"priority": 123
},
"aiQualification": {
"is_enabled": true,
"threshold": 123,
"prospect_criteria": "<string>",
"company_criteria": "<string>",
"disqualify_criteria": "<string>"
},
"candidates": [
{
"userId": "<string>",
"emailAccountIds": [
"<string>"
]
}
]
},
"audienceId": null,
"processingStrategy": null,
"publish": false,
"extendedResponse": false,
"awaitingLimit": 10
}
'import requests
url = "https://api.example.com/api/public/tools/create_flow_plan"
payload = {
"flow": {
"root": {
"id": "<string>",
"delay": "<string>",
"payload": {},
"next": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": {
"id": "<string>",
"delay": "<string>",
"payload": "<unknown>",
"next": "<unknown>",
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
}
},
"on_false": "<unknown>"
},
"expression": "<string>",
"on_true": "<unknown>",
"on_false": "<unknown>"
},
"name": "<string>",
"options": {
"is_exclusion_check_required": True,
"use_hubspot_if_connected": True,
"is_click_tracking_enabled": True,
"is_open_tracking_enabled": True,
"is_enrich_phone_if_not_provided": True,
"push_call_tasks_only_if_phone_exists": True,
"ignore_personal_email_accounts": True,
"prompt": "<string>",
"is_push_to_hubspot_call_tasks": True,
"is_push_to_hubspot_manual_tasks": True,
"is_push_to_hubspot_approve_tasks": True,
"is_enrich_hubspot": True,
"is_enrich_prospects": True,
"is_enrich_companies": True,
"is_enrich_email_if_not_provided": True,
"is_track_emails_in_hubspot": True,
"only_enrich_phone_if_call_task_present": True,
"priority": 123
},
"aiQualification": {
"is_enabled": True,
"threshold": 123,
"prospect_criteria": "<string>",
"company_criteria": "<string>",
"disqualify_criteria": "<string>"
},
"candidates": [
{
"userId": "<string>",
"emailAccountIds": ["<string>"]
}
]
},
"audienceId": None,
"processingStrategy": None,
"publish": False,
"extendedResponse": False,
"awaitingLimit": 10
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
flow: {
root: {
id: '<string>',
delay: '<string>',
payload: {},
next: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: '<unknown>',
on_false: {
id: '<string>',
delay: '<string>',
payload: '<unknown>',
next: '<unknown>',
expression: '<string>',
on_true: '<unknown>',
on_false: '<unknown>'
}
},
on_false: '<unknown>'
},
expression: '<string>',
on_true: '<unknown>',
on_false: '<unknown>'
},
name: '<string>',
options: {
is_exclusion_check_required: true,
use_hubspot_if_connected: true,
is_click_tracking_enabled: true,
is_open_tracking_enabled: true,
is_enrich_phone_if_not_provided: true,
push_call_tasks_only_if_phone_exists: true,
ignore_personal_email_accounts: true,
prompt: '<string>',
is_push_to_hubspot_call_tasks: true,
is_push_to_hubspot_manual_tasks: true,
is_push_to_hubspot_approve_tasks: true,
is_enrich_hubspot: true,
is_enrich_prospects: true,
is_enrich_companies: true,
is_enrich_email_if_not_provided: true,
is_track_emails_in_hubspot: true,
only_enrich_phone_if_call_task_present: true,
priority: 123
},
aiQualification: {
is_enabled: true,
threshold: 123,
prospect_criteria: '<string>',
company_criteria: '<string>',
disqualify_criteria: '<string>'
},
candidates: [{userId: '<string>', emailAccountIds: ['<string>']}]
},
audienceId: null,
processingStrategy: null,
publish: false,
extendedResponse: false,
awaitingLimit: 10
})
};
fetch('https://api.example.com/api/public/tools/create_flow_plan', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/public/tools/create_flow_plan",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'flow' => [
'root' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => [
],
'next' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => [
'id' => '<string>',
'delay' => '<string>',
'payload' => '<unknown>',
'next' => '<unknown>',
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => '<unknown>'
]
],
'on_false' => '<unknown>'
],
'expression' => '<string>',
'on_true' => '<unknown>',
'on_false' => '<unknown>'
],
'name' => '<string>',
'options' => [
'is_exclusion_check_required' => true,
'use_hubspot_if_connected' => true,
'is_click_tracking_enabled' => true,
'is_open_tracking_enabled' => true,
'is_enrich_phone_if_not_provided' => true,
'push_call_tasks_only_if_phone_exists' => true,
'ignore_personal_email_accounts' => true,
'prompt' => '<string>',
'is_push_to_hubspot_call_tasks' => true,
'is_push_to_hubspot_manual_tasks' => true,
'is_push_to_hubspot_approve_tasks' => true,
'is_enrich_hubspot' => true,
'is_enrich_prospects' => true,
'is_enrich_companies' => true,
'is_enrich_email_if_not_provided' => true,
'is_track_emails_in_hubspot' => true,
'only_enrich_phone_if_call_task_present' => true,
'priority' => 123
],
'aiQualification' => [
'is_enabled' => true,
'threshold' => 123,
'prospect_criteria' => '<string>',
'company_criteria' => '<string>',
'disqualify_criteria' => '<string>'
],
'candidates' => [
[
'userId' => '<string>',
'emailAccountIds' => [
'<string>'
]
]
]
],
'audienceId' => null,
'processingStrategy' => null,
'publish' => false,
'extendedResponse' => false,
'awaitingLimit' => 10
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/public/tools/create_flow_plan"
payload := strings.NewReader("{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/public/tools/create_flow_plan")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/public/tools/create_flow_plan")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"flow\": {\n \"root\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": {},\n \"next\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": {\n \"id\": \"<string>\",\n \"delay\": \"<string>\",\n \"payload\": \"<unknown>\",\n \"next\": \"<unknown>\",\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n }\n },\n \"on_false\": \"<unknown>\"\n },\n \"expression\": \"<string>\",\n \"on_true\": \"<unknown>\",\n \"on_false\": \"<unknown>\"\n },\n \"name\": \"<string>\",\n \"options\": {\n \"is_exclusion_check_required\": true,\n \"use_hubspot_if_connected\": true,\n \"is_click_tracking_enabled\": true,\n \"is_open_tracking_enabled\": true,\n \"is_enrich_phone_if_not_provided\": true,\n \"push_call_tasks_only_if_phone_exists\": true,\n \"ignore_personal_email_accounts\": true,\n \"prompt\": \"<string>\",\n \"is_push_to_hubspot_call_tasks\": true,\n \"is_push_to_hubspot_manual_tasks\": true,\n \"is_push_to_hubspot_approve_tasks\": true,\n \"is_enrich_hubspot\": true,\n \"is_enrich_prospects\": true,\n \"is_enrich_companies\": true,\n \"is_enrich_email_if_not_provided\": true,\n \"is_track_emails_in_hubspot\": true,\n \"only_enrich_phone_if_call_task_present\": true,\n \"priority\": 123\n },\n \"aiQualification\": {\n \"is_enabled\": true,\n \"threshold\": 123,\n \"prospect_criteria\": \"<string>\",\n \"company_criteria\": \"<string>\",\n \"disqualify_criteria\": \"<string>\"\n },\n \"candidates\": [\n {\n \"userId\": \"<string>\",\n \"emailAccountIds\": [\n \"<string>\"\n ]\n }\n ]\n },\n \"audienceId\": null,\n \"processingStrategy\": null,\n \"publish\": false,\n \"extendedResponse\": false,\n \"awaitingLimit\": 10\n}"
response = http.request(request)
puts response.read_body{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"message": "<string>",
"traceId": "<string>"
}Authorizations
Body
Flow definition. A complete root is required. Options, AI qualification, and candidates are optional and use server defaults when omitted.
Show child attributes
Show child attributes
Optional existing audience id to attach to the new flow during creation. Use the exact id returned by list_audiences or create_audience.
Optional enrollment processing mode override.
- Use manual for Manual Mode, where contacts/signals wait for explicit enrollment.
- Use default for standard Auto-Enrollment, or new_members_only only when the user explicitly asks for new source members only.
Publish the flow immediately after creation when validation succeeds. If validation fails, the response returns the draft flow with validation errors and links.
Include operational data after creation: cost, enrollment counts, a limited awaiting-contact page, source status, and available enrollment actions. Defaults to false.
Maximum awaiting contacts to include when extendedResponse is true.
Response
Tool result.

