Skip to main content
Glama

Deploy a site (create or full-replace)

deploy_site
DestructiveIdempotent

Publish a static site or single-page app to a live HTTPS URL on the account's platform subdomain (e.g. {name}.subsite.site). A new name creates the site. An existing name REPLACES EVERY FILE (files not in this call are deleted) and needs confirm:"I-want-to-replace-all-files"; preview with dryRun:true. Use update_site instead to change some files of an existing site. A 100-250 KB text file fits in this call with encoding:'gzip+base64' (gzip locally, then base64); use begin_deploy only when the files do not fit in one call. Ship a top-level 404.html for multi-page sites (otherwise unknown paths serve index.html) and use plain ASCII file names. Afterwards add_custom_domain can serve the site on the user's own domain.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>",
      "files": "<files>"
    },
    "name": "deploy_site"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesSite subdomain. Lowercase, 3-63 chars, alphanumeric + hyphens. Must not start or end with a hyphen.
filesYesEither an array of {path, content, encoding?} entries OR a path->content map. Total payload <= 500 MB.
dryRunNoValidate and preview without writing; deletedFiles lists what would be removed. Recommended before replacing an existing site.
confirmNoRequired when the site already exists: exactly "I-want-to-replace-all-files", confirming that every existing file is deleted and replaced. Omit for a new site.

Output Schema

NameRequiredDescriptionDefault
urlYesLive URL of the site.
dryRunNoTrue on a dry run: nothing was written or deleted.
siteIdYes
createdYesTrue if this call created the site.
warningsNoNon-blocking findings: DOTFILE_PUBLIC (a public .well-known file) or detected secrets such as API keys or JWTs.
manageUrlNoDashboard page where the user manages this site (domains, versions, settings). Omitted on dry runs.
deletedFilesYesFiles that existed before this call and were removed by it. Empty for a new site.
customDomainsNoCustom domains of this site and the team's custom-domain allowance; null when they could not be read. Omitted on dry runs.
customHeadersNoResult of syncing the _headers file in the site root (site-wide /* response headers).
filesDeployedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / customDomains
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "allowance": {
      +          "description": "Custom domains the team's current plan includes.",
      +          "type": "number"
      +        },
      +        "connected": {
      +          "description": "Custom domains on this site from both sources, one entry per hostname.",
      +          "items": {
      +            "additionalProperties": false,
      +            "properties": {
      +              "domain": {
      +                "description": "Hostname, e.g. shop.example.com.",
      +                "type": "string"
      +              },
      +              "source": {
      +                "description": "dashboard: linked on the dashboard Web Addresses page. mcp: added with add_custom_domain or the site API.",
      +                "enum": [
      +                  "dashboard",
      +                  "mcp"
      +                ],
      +                "type": "string"
      +              },
      +              "status": {
      +                "description": "live: verified and serving this site. pending: linked, not verified yet.",
      +                "enum": [
      +                  "live",
      +                  "pending"
      +                ],
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "domain",
      +              "status",
      +              "source"
      +            ],
      +            "type": "object"
      +          },
      +          "type": "array"
      +        },
      +        "nextTool": {
      +          "const": "add_custom_domain",
      +          "description": "Present when this site has no custom domain yet and the team has room for one.",
      +          "type": "string"
      +        },
      +        "used": {
      +          "description": "Distinct custom domains in use across the team, both sources (same count as get_account).",
      +          "type": "number"
      +        }
      +      },
      +      "required": [
      +        "connected",
      +        "allowance",
      +        "used"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Custom domains of this site and the team's custom-domain allowance; null when they could not be read. Omitted on dry runs."
      +}
  2. Changed10 schema fields changed
    • changedInput schema / properties / confirm / description
      Previous value: -"Required when the named site already exists. Pass exactly \"I-want-to-replace-all-files\" to acknowledge that every existing file will be deleted and replaced with this new fileset. Omit on first deploy of a new site. If you want to add or change files without removing the others, use update_site instead — it defaults to patch mode."New value: +"Required when the site already exists: exactly \"I-want-to-replace-all-files\", confirming that every existing file is deleted and replaced. Omit for a new site."
    • changedInput schema / properties / dryRun / description
      Previous value: -"If true, validate input + introspect what would change but don't write or delete. Returns the same shape with `dryRun: true` and `deletedFiles` showing what *would* be removed. Strongly recommended before any deploy_site against an existing site."New value: +"Validate and preview without writing; deletedFiles lists what would be removed. Recommended before replacing an existing site."
    • changedInput schema / properties / files / anyOf
      Previous value: -[
      -  {
      -    "description": "Array of { path, content, encoding? } file entries. Use this form for binary files.",
      -    "items": {
      -      "properties": {
      -        "content": {
      -          "type": "string"
      -        },
      -        "encoding": {
      -          "description": "utf8 (default), base64 (binary files), or gzip+base64 (~3–5× more raw bytes per tool call: gzip locally, base64-encode the gzip output, server gunzips on receive).",
      -          "enum": [
      -            "utf8",
      -            "base64",
      -            "gzip+base64"
      -          ],
      -          "type": "string"
      -        },
      -        "path": {
      -          "type": "string"
      -        }
      -      },
      -      "required": [
      -        "path",
      -        "content"
      -      ],
      -      "type": "object"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "additionalProperties": {
      -      "type": "string"
      -    },
      -    "description": "Map of relative file path to UTF-8 content. Use the array form if you need binary support (images, fonts).",
      -    "propertyNames": {
      -      "type": "string"
      -    },
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "description": "Array form; needed for binary files.",
      +    "items": {
      +      "properties": {
      +        "content": {
      +          "description": "File content: text, or base64 as set by encoding.",
      +          "type": "string"
      +        },
      +        "encoding": {
      +          "description": "utf8 (default), base64 (binary files), or gzip+base64 (gzip locally, then base64; fits 3-5x more text per call).",
      +          "enum": [
      +            "utf8",
      +            "base64",
      +            "gzip+base64"
      +          ],
      +          "type": "string"
      +        },
      +        "path": {
      +          "description": "Path relative to the site root, e.g. index.html or assets/app.js. Plain ASCII, no leading slash.",
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "path",
      +        "content"
      +      ],
      +      "type": "object"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "additionalProperties": {
      +      "type": "string"
      +    },
      +    "description": "Map form: path to UTF-8 text.",
      +    "propertyNames": {
      +      "type": "string"
      +    },
      +    "type": "object"
      +  }
      +]
    • changedOutput schema / properties / created / description
      Previous value: -"True if the site was created by this call."New value: +"True if this call created the site."
    • changedOutput schema / properties / customHeaders / description
      Previous value: -"Result of the Netlify-style _headers sync: include a _headers file in the site root to override default response headers (e.g. Permissions-Policy). Site-wide (/*) rules only."New value: +"Result of syncing the _headers file in the site root (site-wide /* response headers)."
    • changedOutput schema / properties / deletedFiles / description
      Previous value: -"Files that existed before this call and were removed by it. Empty for brand-new sites."New value: +"Files that existed before this call and were removed by it. Empty for a new site."
    • changedOutput schema / properties / dryRun / description
      Previous value: -"True if this was a dry-run; nothing was written or deleted."New value: +"True on a dry run: nothing was written or deleted."
    • addedOutput schema / properties / manageUrl
      Added value: +{
      +  "description": "Dashboard page where the user manages this site (domains, versions, settings). Omitted on dry runs.",
      +  "type": "string"
      +}
    • changedOutput schema / properties / url / description
      Previous value: -"Live URL of the deployed site."New value: +"Live URL of the site."
    • changedOutput schema / properties / warnings / description
      Previous value: -"Surfaced issues that did not block the deploy. Common types: DOTFILE_PUBLIC (a .well-known/* file is served publicly, confirm intent), or secret-scanner findings (AWS Access Key, Stripe Key, JWT Token, etc.)."New value: +"Non-blocking findings: DOTFILE_PUBLIC (a public .well-known file) or detected secrets such as API keys or JWTs."
  3. Changed1 schema field changed
    • removedOutput schema / properties / request_id
      Removed value: -{
      -  "description": "Server-assigned request correlation id. Quote it when contacting support.",
      -  "type": "string"
      -}
  4. Changed1 schema field changed
    • addedOutput schema / properties / customHeaders
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "applied": {
      +          "type": "number"
      +        },
      +        "changed": {
      +          "type": "boolean"
      +        },
      +        "warnings": {
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        }
      +      },
      +      "required": [
      +        "applied",
      +        "changed",
      +        "warnings"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Result of the Netlify-style _headers sync: include a _headers file in the site root to override default response headers (e.g. Permissions-Policy). Site-wide (/*) rules only."
      +}
  5. Changed1 schema field changed
    • addedOutput schema / properties / request_id
      Added value: +{
      +  "description": "Server-assigned request correlation id. Quote it when contacting support.",
      +  "type": "string"
      +}
  6. First observed

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the destructiveHint and idempotentHint annotations, the description discloses the critical destructive consequence: an existing name REPLACES EVERY FILE and deletes files not included in the call. It also adds the required confirmation string, dryRun preview behavior, payload guidance, 404.html behavior, and ASCII filename constraint.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but front-loaded: publish purpose first, then create/replace behavior, alternatives, encoding guidance, 404.html, and custom-domain follow-up. Every clause carries operational value, with no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the destructive write operation, rich annotations, complete input schema, and existing output schema, the description covers everything an agent needs: create-vs-replace semantics, confirmation, preview, alternatives, payload encoding, and post-deploy domain steps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds operational meaning: it gives a practical 100-250 KB threshold for encoding:'gzip+base64' and explains why that encoding fits more text per call. It also reinforces dryRun for previewing deletions and the exact confirm token, though most parameter details remain in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: "Publish a static site or single-page app to a live HTTPS URL." It immediately distinguishes create-vs-replace semantics and names the sibling tools update_site and begin_deploy, so an agent can select it without opening another schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly states when a new name creates a site, when an existing name replaces every file, when to use update_site instead, when to use begin_deploy, and when to preview with dryRun. The confirm token requirement for replacement is stated clearly.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.