---
type: api
title: Clone a workflow
description: Create a copy of an existing workflow.<br/><br/>[Required authorization] Route required privileges: workflowsManagement:create AND workflowsManagement:read.
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v0/operation/operation-post-workflows-workflow-id-clone
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v0/operation/operation-post-workflows-workflow-id-clone
products:
  - Kibana
---

# Clone a workflow

Availability: 9.4+

- Server: `https://{kibana_url}`

## Paths

- `POST` `/api/workflows/workflow/{id}/clone`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v0/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v0/authentication#basicauth)

#### Path Parameters

- `id` (string · max: 255)
  Workflow ID

## Description

Create a copy of an existing workflow.<br/><br/>[Required authorization] Route required privileges: workflowsManagement:create AND workflowsManagement:read.

## Response

Indicates a successful response

## Code Examples

#### Console

```console
POST kbn://api/workflows/workflow/{id}/clone
```

#### curl

```curl
curl \
  -X POST "${KIBANA_URL}/api/workflows/workflow/{id}/clone" \
  -H "Authorization: ApiKey ${API_KEY}" \
  -H "kbn-xsrf: true"
```

## Response Examples

#### Clone workflow response

Example response returning the cloned workflow with a new ID

```json
{
  "createdAt": "2025-11-22T11:00:00.000Z",
  "createdBy": "elastic",
  "definition": {
    "description": "This is a workflow example",
    "enabled": false,
    "inputs": [
      {
        "default": "hello world",
        "name": "message",
        "type": "string"
      }
    ],
    "name": "Example definition (copy)",
    "steps": [
      {
        "name": "hello_world_step",
        "type": "console",
        "with": {
          "message": "{{ inputs.message }}"
        }
      }
    ],
    "triggers": [
      {
        "type": "manual"
      }
    ]
  },
  "description": "This is a workflow example",
  "enabled": false,
  "id": "workflow-b2c3d4e5-f6a7-8901-bcde-f12345678901",
  "lastUpdatedAt": "2025-11-22T11:00:00.000Z",
  "lastUpdatedBy": "elastic",
  "name": "Example definition (copy)",
  "valid": true,
  "yaml": "name: Example definition (copy)\nenabled: false\ndescription: This is a workflow example\ntriggers:\n  - type: manual\ninputs:\n  - name: message\n    type: string\n    default: \u0022hello world\u0022\nsteps:\n  - name: hello_world_step\n    type: console\n    with:\n      message: \u0022{{ inputs.message }}\u0022\n"
}
```

