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

# client.pipelines.copy()

> Copy a pipeline.

Send an optional name to copy the pipeline, including its configuration and dataset binding, within its project. Returns the new pipeline's metadata. Use `GET /api/v2-beta/pipelines/{pipelineId}/graph` with the new pipeline ID to read the copied configuration.

## Signature

Method signature on `client.pipelines`:

```ts theme={null}
copy(args: {
  pipelineId: string;
  name?: string;
}): Promise<Pipeline>;
```

## Parameters

**pipelineId** `string` *required*

Pipeline ID with prefix `pl.`.

**name** `string`

Name for the copy. Defaults to the source pipeline name.

## Returns

`Promise<Pipeline>`

A pipeline within a project.

**id** `PipelineId` *required*

Pipeline ID with prefix `pl.`.

**projectId** `ProjectId` *required*

Project ID with prefix `pp.`.

**name** `string` *required*

Name of the pipeline.

**version** `number` *required*

Pipeline version number; copying a pipeline increments the source version.

**createdAt** `string` *required*

Time the pipeline was created, as an ISO 8601 timestamp.

**updatedAt** `string` *required*

Time the pipeline was last updated, as an ISO 8601 timestamp.

## Errors

HTTP errors throw [`PotatoApiError`](https://docs.platform.toloka.ai/docs/sdk/errors). The endpoint documents these error responses:

| Status | Description |
| - | - |
| 403 | Trial limit reached. An account that has not completed identity or business verification may hold one project and one pipeline, and cannot start a run. The body message reads "Your trial allows a single pipeline. Verify your account to unlock full access." Complete verification in the web app to lift the limit. |
| 404 | Pipeline not found |
| 429 | Rate limit exceeded |

HTTP endpoint: [`POST /pipelines/{pipelineId}/copy`](https://docs.platform.toloka.ai/docs/api-reference/pipelines/copy-pipeline).

```ts copy() theme={null}
import { createClient } from "@toloka-platform/sdk";

const client = createClient({
  baseUrl: "https://platform.toloka.ai",
  apiKey: process.env.TOLOKA_API_KEY!,
});

const pipeline = await client.pipelines.copy({
  pipelineId: "pl.019a0000-0000-7000-8000-000000000001",
  name: "Text labeling copy"
});
console.log(pipeline);
```

```json copy() theme={null}
{
  "id": "pl.019a0000-0000-7000-8000-000000000001",
  "projectId": "pp.019a0000-0000-7000-8000-000000000001",
  "name": "<string>",
  "version": 0,
  "createdAt": "2026-01-01T00:00:00Z",
  "updatedAt": "2026-01-01T00:00:00Z"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.