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

# Duplicate Journey

> Create a draft copy of an SMS welcome journey.

Copies the journey trigger, priority, steps, and start step into a new journey named with a ` (Copy)` suffix. If appending the suffix to the source name would exceed the 255-character name limit, the source name is truncated so the resulting name fits within 255 characters. The copy always starts as a draft. Steps and their references are validated again.

Declares the `journeys.write` scope. Authenticate with `X-Api-Key`; see [Authentication](/api-reference/authentication).

Duplicating a draft still requires an unrestricted live key under the [API key requirements](/api-reference/v2/journeys/create-journey#api-key-requirements). No request body is required.

## Path Parameters

<ParamField path="journey_id" type="string" required>
  Journey ID returned by create or list. Use a valid journey ID; malformed IDs currently return an unexpected error.
</ParamField>

## Response

The `journey` object uses camelCase: `id`, integer `accountId`, `name`, `trigger`, `priority`, `steps`, `startStepId`, `status`, `pauseReason`, `createdAt`, and `updatedAt`. The trigger can be null. Each step contains `stepId`, `name`, `stepType`, `config`, and nullable `nextStepId`. Pause reasons and absent timestamps can be null.

<ResponseExample>
  ```json 201 theme={null}
  {
    "success": true,
    "message": "Journey duplicated successfully",
    "journey": {
      "id": "664f1a2b3c4d5e6f7a8b9c0e",
      "accountId": 101,
      "name": "Welcome (Copy)",
      "trigger": {
        "operator": "AND",
        "conditions": [],
        "groups": []
      },
      "priority": 0,
      "steps": [
        {
          "stepId": "done",
          "name": "Exit",
          "stepType": "exit",
          "config": {},
          "nextStepId": null
        }
      ],
      "startStepId": "done",
      "status": "draft",
      "pauseReason": null,
      "createdAt": "2026-09-21T10:00:00",
      "updatedAt": "2026-09-21T10:00:00"
    }
  }
  ```
</ResponseExample>

Invalid copied steps return 400; missing or foreign journeys return 404. Follow the [write retry rules](/api-reference/v2/journeys/create-journey#errors-and-retry).

## Idempotency

This endpoint accepts an [`Idempotency-Key`](/api-reference/v2/idempotency) header. Reuse the same key when a lost response leaves the outcome ambiguous: the first 201 is cached for 24 hours and replayed verbatim, so the retry returns the copy the first request created instead of creating a second one. A `journey_write_outcome_unknown` 409 is cached the same way.

The replay fingerprint includes the source journey path, so the same key sent to a different journey returns `409 idempotency_conflict` rather than replaying the earlier copy, and it never collides with a key used for [Create Journey](/api-reference/v2/journeys/create-journey). A retry arriving while the first request is still running returns `409 idempotency_in_progress` with a `Retry-After` header. Without the header the request runs unprotected: inspect your journeys before repeating it after a lost response. See [Idempotency](/api-reference/v2/journeys/create-journey#idempotency) for the shared rules.
