---
title: "corestack_deployments_options_update"
url: https://docs.corefinity.com/mcp/tools/corestack_deployments_options_update
type: tool
last_updated: 2026-11-13
feature: deployment-pipeline
related:
  - https://docs.corefinity.com/api/reference/deployments/update-site-deployment-options.md
  - https://docs.corefinity.com/guides/sites/code-and-deployments/pipeline-stages.md
---
# corestack_deployments_options_update

**Update deployment options.** Change the environment's deployment options, for every binding: extra shared paths, the paths a build reads, a snapshot before an upgrade (Magento 2), the pre-switch check, the warm-up, the Cloudflare purge and the Varnish purge (Magento 2). Only the options sent change. Scope: write.

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

## When to use it

Change the environment's deployment options, which every binding of it uses: extra shared paths, the paths a build reads, a snapshot before an upgrade (Magento 2 only), the pre-switch check, the warm-up after the switch, the Cloudflare purge and, on Magento 2, the Varnish purge right after the switch (on by default). Only the options you send change; send a list whole. An extra shared path's location under `shared/` is kept as stored (it is set in the Control Panel). Read them back with `corestack_deployments_pipeline_get` (its `options`, with the platform's own shared paths an extra one must not overlap).

The same action in the public REST API, with the same checks, refusals and scope: `PUT /api/corestack/sites/{site}/deployments/options`.

## Inputs

- `site_id` (integer, ≥ 1, required)
- `extra_shared_paths` (array of a path or {path, kind}, at most 50 items): The whole list: paths relative to the site root, each {path, kind dir|file} or a folder's path. A path keeps its stored location under shared/.
- `build_reads` (array of string, at most 10 items): The whole list of paths relative to the site root.
- `snapshot_before_upgrade` (boolean): Magento 2 only.
- `pre_switch_check` (boolean or {enabled, paths[]}): Off, on, or {enabled, paths[]} of up to five paths starting with a slash.
- `warm_up` (boolean or {enabled, paths[]}): Off, on, or {enabled, paths[]} of up to ten paths starting with a slash.
- `cloudflare_purge` (boolean)
- `varnish_purge` (boolean): Magento 2 only: purge Varnish right after the release switch (on unless set to false).

### Input schema

```json
{
  "additionalProperties": false,
  "properties": {
    "build_reads": {
      "description": "The whole list of paths relative to the site root.",
      "items": {
        "maxLength": 255,
        "type": "string"
      },
      "maxItems": 10,
      "type": "array"
    },
    "cloudflare_purge": {
      "type": "boolean"
    },
    "extra_shared_paths": {
      "description": "The whole list: paths relative to the site root, each {path, kind dir|file} or a folder's path. A path keeps its stored location under shared/.",
      "items": {
        "anyOf": [
          {
            "maxLength": 255,
            "type": "string"
          },
          {
            "additionalProperties": false,
            "properties": {
              "kind": {
                "enum": [
                  "dir",
                  "file"
                ],
                "type": "string"
              },
              "path": {
                "maxLength": 255,
                "type": "string"
              }
            },
            "required": [
              "path"
            ],
            "type": "object"
          }
        ]
      },
      "maxItems": 50,
      "type": "array"
    },
    "pre_switch_check": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "additionalProperties": false,
          "properties": {
            "enabled": {
              "type": "boolean"
            },
            "paths": {
              "items": {
                "maxLength": 251,
                "type": "string"
              },
              "maxItems": 5,
              "type": "array"
            }
          },
          "required": [
            "enabled"
          ],
          "type": "object"
        }
      ],
      "description": "Off, on, or {enabled, paths[]} of up to five paths starting with a slash."
    },
    "site_id": {
      "minimum": 1,
      "type": "integer"
    },
    "snapshot_before_upgrade": {
      "description": "Magento 2 only.",
      "type": "boolean"
    },
    "varnish_purge": {
      "description": "Magento 2 only: purge Varnish after the switch (default on).",
      "type": "boolean"
    },
    "warm_up": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "additionalProperties": false,
          "properties": {
            "enabled": {
              "type": "boolean"
            },
            "paths": {
              "items": {
                "maxLength": 251,
                "type": "string"
              },
              "maxItems": 10,
              "type": "array"
            }
          },
          "required": [
            "enabled"
          ],
          "type": "object"
        }
      ],
      "description": "Off, on, or {enabled, paths[]} of up to ten paths starting with a slash."
    }
  },
  "required": [
    "site_id"
  ],
  "type": "object"
}
```

## Refusals

- `forbidden`: the person's role lacks the Edit Environment Deployment Pipeline permission. The message names it and
  says an owner of the company can grant it in Roles; `details.permission` is `editEnvironmentDeploymentPipeline`.
  Nothing is changed.
- `wrong_platform`: a snapshot before an upgrade, and the Varnish purge, are for Magento 2 sites only.
- `managed_elsewhere` (message: "This site is managed by another control panel"): another control panel manages this site, so use that control panel for it. This is refused before anything else about the site, as in the Control Panel and the API. Nothing was done.
- 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_deployments_options_update",
  "arguments": {
    "site_id": 4211,
    "warm_up": {
      "enabled": true,
      "paths": [
        "/",
        "/shop"
      ]
    },
    "cloudflare_purge": true
  }
}
```

## Prompt

```text
Using the Corefinity MCP server, call corestack_deployments_options_update with site_id 4211, warm_up {"enabled":true,"paths":["/","/shop"]}, cloudflare_purge true. (Update deployment options.) Tell me what it returned.
```

## The same task elsewhere

- Endpoint: [PUT /api/corestack/sites/{site}/deployments/options](https://docs.corefinity.com/api/reference/deployments/update-site-deployment-options.md)
- Guide: [Pipeline](https://docs.corefinity.com/guides/sites/code-and-deployments/pipeline-stages.md)
