---
title: "corestack_site_clone_preview"
url: https://docs.corefinity.com/mcp/tools/corestack_site_clone_preview
type: tool
last_updated: 2026-11-13
feature: copies
related:
  - https://docs.corefinity.com/api/reference/environments/preview-site-clone.md
  - https://docs.corefinity.com/guides/sites/environments-and-copies/clone-a-site.md
---
# corestack_site_clone_preview

**Preview a copy.** What copying a row's files and / or database onto one of the site's environments or its production row would move, the steps, the fix-ups and what blocks it now. The target is busy while the copy runs; the copy's task shows its steps. Scope: read.

- Scope: `read`
- Runs as a task: no

## When to use it

What copying a row's files and / or database onto one of the site's environments or its production row would move, the steps, the fix-ups and what blocks it now. The target is busy while the copy runs; the copy's task shows its steps.

## Inputs

- `site_id` (integer, ≥ 1, required): The source row.
- `target_type` (one of `environment`, `production`, required)
- `target_id` (integer, ≥ 1): With target_type environment: the environment's row.
- `scope` (one of `files_db`, `db`, `files`): What to copy (files_db).
- `snapshot_id` (integer, ≥ 1): Copy from a ready snapshot of the source instead.

### Input schema

```json
{
  "additionalProperties": false,
  "properties": {
    "scope": {
      "description": "What to copy (files_db).",
      "enum": [
        "files_db",
        "db",
        "files"
      ],
      "type": "string"
    },
    "site_id": {
      "description": "The source row.",
      "minimum": 1,
      "type": "integer"
    },
    "snapshot_id": {
      "description": "Copy from a ready snapshot of the source instead.",
      "minimum": 1,
      "type": "integer"
    },
    "target_id": {
      "description": "With target_type environment: the environment's row.",
      "minimum": 1,
      "type": "integer"
    },
    "target_type": {
      "enum": [
        "environment",
        "production"
      ],
      "type": "string"
    }
  },
  "required": [
    "site_id",
    "target_type"
  ],
  "type": "object"
}
```

## Refusals

- A copy that cannot be made is answered, not refused: `blockers[]` lists each reason with its message and `can_proceed` is false.
- A copy that only has to wait is not blocked: `waits[]` lists what it would wait for (`clone_in_progress`: another copy on either site, or one queued there before it; `busy` / `target_busy`: a change in progress on the source or the target, or one still being set up; `cluster_migrating`; `snapshot_slot`), each with the words the person sees ("Waiting for another copy on this site to finish. It starts on its own."), `queues` is true and `can_proceed` stays true. corestack_site_clone then queues the copy and it starts on its own. `copy_queued` in `blockers[]` means a copy onto that target is already waiting: it must start, or be cancelled, before another is queued. `not_offered` there with "This WordPress site is built with Bedrock, so it can only be copied to a site that deploys the same way. For a staging copy, use a branch (Git) environment." means the target deploys another way; corestack_site_clone would refuse it.
- `snapshot_transfer` in `blockers[]` (message: "A saved snapshot can be copied only to an environment on the same servers for now, and these two environments are on different servers. Copy the live environment instead, or restore the snapshot to an environment on the same servers."): the chosen `snapshot_id` cannot be copied to the target, which runs on other servers than the source; corestack_site_clone would refuse it on `snapshot_id`. Tell the person they can copy the live environment instead (leave out `snapshot_id`), or restore the snapshot to an environment on the same servers.
  Where it is switched on and both servers can, a saved snapshot on other servers is sent to the target environment's servers first instead: the preview shows `transport` `sent_local`, its `estimated_seconds` include the send, and `expected_switch.note` says so. `snapshot_transfer` stays for a snapshot the servers cannot send.
- `too_small` (or `source_larger`) in `blockers[]`: the target environment's disk is too small for the data; the message names the size to resize it to, or says production's package or support is needed. `target_growth` then gives the size (`size`, `label`, `disk_bytes`, `needed_bytes`) with `automatic` false: ask the person to resize the target first (corestack_environment_resize, priced with corestack_billing_quote_preview); nothing is bought for them.
- `target_growth` with `automatic` true and no size blocker: the company turned on automatic upgrades, so starting the copy resizes the target to `label` first, priced as a resize (`monthly_delta` a month more, when known) within the company's monthly limit; `message` says so ("The target grows to Medium (100 GB) first, as an automatic upgrade you turned on."). Tell the person before you start it.
- The refusals every tool can answer: `invalid_arguments`, `tenant_mismatch`, `scope_required`, `pin_refused`, `rate_limited`, `temporarily_unavailable`, `internal_error` (corestack://guides/how-this-server-works).

## Example

```json
{
  "name": "corestack_site_clone_preview",
  "arguments": {
    "site_id": 4211,
    "target_type": "environment"
  }
}
```

## Prompt

```text
Using the Corefinity MCP server, call corestack_site_clone_preview with site_id 4211, target_type environment. (Preview a copy.) Tell me what it returned.
```

## The same task elsewhere

- Endpoint: [GET /api/corestack/sites/{site}/clone/preview](https://docs.corefinity.com/api/reference/environments/preview-site-clone.md)
- Guide: [Clone an environment](https://docs.corefinity.com/guides/sites/environments-and-copies/clone-a-site.md)
