Skip to main content
Glama

Add custom domain

add_custom_domain
Idempotent

Use when the user wants the site on their own domain (owners and admins who edit the site). Points "deck.acme.com" at SnapHost. With site_id the domain shows that one site (Pro); with target: "workspace" (a Pro workspace) it becomes the workspace’s sharing domain, where every site and folder link opens. Returns required_dns_records: a pointing record and a TXT ownership record, both needed. Relay them exactly; live once both resolve. mode "viewer" (default) shows the site in the SnapHost viewer. mode "website" makes the site a public website at the domain, for good: only an owner can, it needs a team workspace on a paid plan and an HTML site, and it removes every share and makes the site public. Make one only after the person confirms. A shared-page address already added for this site becomes the website when you call again with the same host, site_id and mode "website". mode "redirect" sends visitors to the site’s website (up to 3 redirect addresses). listed (website only, default true) lets search engines list it. A domain on another site: remove_custom_domain there first. A view password, link expiry or allowlist must be removed first: ask the person before removing any.

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": {
      "host": "<host>"
    },
    "name": "add_custom_domain"
  }
}

Input Schema

NameRequiredDescriptionDefault
hostYesThe domain or subdomain, e.g. deck.acme.com
modeNo"viewer" (default), "website" (public website at this domain, owners only, permanent address) or "redirect" (send visitors to the site’s website domain)
listedNoWith mode "website": true (default) lets search engines list it, false asks them to skip it
targetNo"site" (default) binds one site; "workspace" makes the domain the Pro workspace’s sharing domain
site_idNoThe site to bind the domain to. On target "workspace" it is optional and names the Shared drive site shown at the bare / of the sharing domain.
workspace_idNoOptional: the workspace to act in, from list_workspaces (the connection reaches the person's personal space and every workspace they are a member of). Required on a write when the connection reaches more than one workspace. Omit to act in the personal space (for an older single-workspace connection, the one workspace it was authorized for).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / site_id / description
      Previous value: -"The site to bind the domain to. On target \"workspace\" it is optional and names the site shown at the bare / of the sharing domain."New value: +"The site to bind the domain to. On target \"workspace\" it is optional and names the Shared drive site shown at the bare / of the sharing domain."
  2. Changed4 schema fields changed
    • addedInput schema / properties / listed
      Added value: +{
      +  "description": "With mode \"website\": true (default) lets search engines list it, false asks them to skip it",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / mode
      Added value: +{
      +  "description": "\"viewer\" (default), \"website\" (public website at this domain, owners only, permanent address) or \"redirect\" (send visitors to the site’s website domain)",
      +  "enum": [
      +    "viewer",
      +    "website",
      +    "redirect"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / site_id / description
      Previous value: -"The site to bind the domain to. On target \"workspace\" it is optional and names the ROOT site served at the bare / of the domain."New value: +"The site to bind the domain to. On target \"workspace\" it is optional and names the site shown at the bare / of the sharing domain."
    • changedInput schema / properties / target / description
      Previous value: -"\"site\" (default) binds one site; \"workspace\" aliases the whole Pro workspace"New value: +"\"site\" (default) binds one site; \"workspace\" makes the domain the Pro workspace’s sharing domain"
  3. Changed1 schema field changed
    • changedInput schema / properties / workspace_id / description
      Previous value: -"Optional: the workspace (the personal space or a Pro workspace) to act in, from list_workspaces. Omit to act in the token owner's own account."New value: +"Optional: the workspace to act in, from list_workspaces (the connection reaches the person's personal space and every workspace they are a member of). Required on a write when the connection reaches more than one workspace. Omit to act in the personal space (for an older single-workspace connection, the one workspace it was authorized for)."
  4. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Adds substantial context beyond the annotations: the returned required_dns_records (a pointing record plus a TXT ownership record) that must be relayed exactly, the fact the domain only goes live once both resolve, the 'for good' permanence of website mode, the up-to-3 redirect limit, and a mandatory confirmation step. The one point of tension is that the description says website mode 'removes every share and makes the site public' while destructiveHint=false — share removal is arguably a destructive update, though the site and its content survive, so this reads as under-flagging rather than a direct contradiction. Idempotency claims in the annotations are actively supported by the re-call-with-same-host/site_id/mode sentence.

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

Conciseness4/5

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

Front-loaded with the trigging condition and the primary example, then ordered by mode. It is dense and long, and the redirect/listed details trail in a somewhat run-on middle section, but each sentence carries operational information the agent would otherwise have to guess.

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?

For a six-parameter, multi-mode mutation tool with no output schema, the description covers permissions, plan prerequisites, precondition cleanup, the confirmation requirement, conflict handling with other domains, and the exact return payload the agent must relay. Nothing material needed to call it safely is missing.

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 already 100%, so the baseline is 3; the description goes further by explaining how site_id behaves differently under target "workspace" (optional, names the Shared drive site at the bare / of the sharing domain) and what listed means only in website mode. It also explains the same-argument re-call semantics that the schema cannot express. Minor gap: workspace_id is only covered by its schema text, though that text is thorough.

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?

States a specific action and resource ('points deck.acme.com at SnapHost', bind a domain to a site or workspace) and distinguishes itself from the sibling operations that bookend it: remove_custom_domain and verify_custom_domain are both named. The three modes are enumerated, so an agent knows exactly what variant of the operation it is choosing.

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?

Explicit when-to-use ('when the user wants the site on their own domain'), who may do it (owners/admins who edit the site; owner-only for website mode), and per-mode preconditions (team workspace on a paid plan, HTML site, Pro for workspace sharing domain). It also names alternatives and blockers: remove_custom_domain on another site first, and clearing a view password/expiry/allowlist before adding.

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.