Skip to main content
POST
/
workflows
/
{id}
/
duplicate
Duplicate a workflow
curl --request POST \
  --url https://api.dialnexa.com/v1/workflows/{id}/duplicate \
  --header 'Authorization: Bearer <token>'
{
  "id": "wf_abc123",
  "organization_id": "org_xyz",
  "title": "Lead Nurture Sequence",
  "description": "Contacts cold leads three times before marking as unresponsive.",
  "status": "active",
  "created_at": "2024-03-01T09:00:00.000Z",
  "updated_at": "2024-03-02T11:00:00.000Z"
}
Creates a complete copy of a workflow, every node, every edge, every per-node configuration, in draft status. The duplicate is independent from the original: changes you make to it do not affect the live workflow, and leads enrolled in the original are not carried over to the duplicate. The duplicate keeps the original’s name with a (Copy) suffix by default. Rename it with Update Workflow before activating.

When to use this

  • Safe iteration: duplicate a working workflow, edit the copy, A/B test the change, then promote the copy when it outperforms the original.
  • Variant per campaign: start from a proven workflow structure for a new outreach with different prompts, agents, or wait times.
  • Backup before risky edits: duplicate before a major structural change so you can fall back to the snapshot if needed.
  • Cross-team reuse: share a known-good workflow design between teams without exposing the original.
A duplicate does not include lead enrollments. After the copy is created, enroll the leads you want to test through Add Lead to Workflow. When the copy is ready, Activate Workflow to go live.

What gets copied

  • All nodes (with their node_type, label, config, and position_x/position_y).
  • All edges (with their from_node_id, to_node_id, and label).
  • Workflow metadata such as name and description.
What does not get copied:
  • Enrolled leads.
  • Historical call logs.
  • The original workflow’s status: the duplicate always starts as draft.

Path parameters

ParameterDescription
idThe source workflow ID, for example wfl_m3v7zb9rk2px.

Errors

  • 404 Not Found is returned when the source workflow does not exist.

Request

curl -X POST "https://api.dialnexa.com/v1/workflows/wfl_m3v7zb9rk2px/duplicate" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response

{
  "id": "wfl_n9p3kt7xv5mz",
  "name": "30-Day Lead Nurture (Copy)",
  "status": "draft",
  "node_count": 5,
  "edge_count": 6,
  "enrolled_leads": 0,
  "created_at": "2024-05-15T08:00:00.000Z"
}

Authorizations

Authorization
string
header
required

Pass your API key as a Bearer token in the Authorization header.

Path Parameters

id
string
required

Response

201 - application/json

Duplicated workflow created in draft status.

id
string
Example:

"wf_abc123"

organization_id
string
Example:

"org_xyz"

title
string
Example:

"Lead Nurture Sequence"

description
string | null
Example:

"Contacts cold leads three times before marking as unresponsive."

status
enum<string>

Workflow lifecycle status. Responses can include running for older workflow records; treat it like active. Use active in new create or update requests.

Available options:
draft,
active,
running,
paused,
completed,
cancelled
Example:

"active"

created_at
string<date-time>
Example:

"2024-03-01T09:00:00.000Z"

updated_at
string<date-time>
Example:

"2024-03-02T11:00:00.000Z"