---
title: "Copy Workspace"
method: POST
path: "/copy/workspaces"
tags: ["Copy"]
---

# Copy Workspace

`POST /copy/workspaces`

Used to copy the contents of one workspace to another. This is not idempotent - multiple calls will create multiple copies in the destination. Both workspaces must be in the same account or company.

## Request body

- CopyWorkspaceRequest
  - `source_workspace_id` string, required — The id of the workspace from which to copy
  - `destination_workspace_id` string, required — The id of the destination workspace
  - `include_defaults` boolean — Include default tests during copy; defaults to false. If this parameter is provided, the "tests" scope will be implicitly included to the copy operation
  - `included_tests` string[] — A list of the tests to copy. If empty, all tests that are not in the excluded_list will be copied. If this parameter is provided, the "tests" scope will be implicitly included to the copy operation
  - `excluded_tests` string[] — A list of ids of tests to exclude from the copy. If this parameter is provided, the "tests" scope will be implicitly included to the copy operation
  - `entity_scopes` WorkspaceCopyEntityScope[] — A list of entity types to include in the copy, if nothing is provided all supported entity types will be copied. Some entities of the excluded types may need to be created due to entity dependencies.

## Response `200`

Operation was successful

## Other responses

- `400` — Invalid or missing parameter
- `401` — User not authenticated
- `403` — User not authorized
- `default` — Unknown error

---

[API](https://skmtc.net/mabl/apis/mabl-api.md) · [All operations](https://skmtc.net/mabl/apis/mabl-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mabl/mabl-api/revisions/d0fc0114da66/schema)
