Skip to main content
Glama

Publish page or site

publish_html

Publish a page (content: HTML, Markdown, code or JSON, max 5 MiB) or a static site (files: HTML, CSS, JS as text; 200 files, 20 MiB in total). Returns the share link, the owner token and manageUrl (private: its holder can edit or delete). Owner tokens and management links never go into published content. A page that saves what visitors enter needs state and the script named in guide topic page-data. Page code must not hide or alter the BrewPage badge; a profile can turn the badge off for a page.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "publish_html"
  }
}

Input Schema

NameRequiredDescriptionDefault
tagsNo
entryNoSite entry file, default index.html
filesNoSite files; instead of `content`
stateNoPage data config; `{}` = on with defaults
domainNoCustom domain the user owns, a bare hostname
formatNohtml, markdown or a code language; omitted: by file name, else by content
contentNo
ttlDaysNoDays to keep it: up to 30 days without an account, up to 90 with a free profile (an ownerToken held in the profile). Omitted: the default. The result states the expiry.
filenameNoOriginal file name; its extension sets the format
passwordNo
namespaceNo`public` for anything meant to be found or shared: listed in the gallery and sitemap, indexed by Google, Bing and AI search; unsuitable for secrets or personal data. Omit (default): private, a generated priv-* namespace, unlisted; the link still opens it. A custom name: 1-32 of a-z, 0-9, hyphen.
ownerTokenNoOwner token of an earlier create
showTopBarNoTop toolbar with file name and Download
deliveryModeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed23 schema fields changed
    • removedInput schema / $schema
      Removed value: -"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / properties / content / description
      Removed value: -"HTML, Markdown, code or JSON to publish"
    • removedInput schema / properties / deliveryMode / description
      Removed value: -"Optional delivery choice for a fresh publication, independent of password/namespace. Fresh sites and HTML-format pages outside public (including the default unlisted namespace) always use subdomain; an explicit path there still publishes, on subdomain, with a delivery notice. Everything else in any namespace (Markdown, code/text, files, JSON, KV, public HTML) defaults to path (Promotion); public HTML may automatically choose subdomain for browser features. When creation returns an existing publication, it keeps its actual mode and URL."
    • changedInput schema / properties / domain / description
      Previous value: -"Optional custom domain for the new publication: a bare hostname the user owns (www.example.com or example.com, no scheme or path). Needs a profile token or an owner token added to a free BrewPage profile, and no password. The publication is always created; the result lists the DNS records for the domain owner to create, or says why the custom domain was not set."New value: +"Custom domain the user owns, a bare hostname"
    • addedInput schema / properties / entry
      Added value: +{
      +  "description": "Site entry file, default index.html",
      +  "type": "string"
      +}
    • changedInput schema / properties / filename / description
      Previous value: -"Optional original filename (≤200 chars). Without `format`, a known extension sets the format (.md stays Markdown, even a whole HTML document). Used as title fallback when no <title>/<h1>; immutable on update."New value: +"Original file name; its extension sets the format"
    • removedInput schema / properties / filename / maxLength
      Removed value: -200
    • addedInput schema / properties / files
      Added value: +{
      +  "description": "Site files; instead of `content`",
      +  "items": {
      +    "properties": {
      +      "content": {
      +        "type": "string"
      +      },
      +      "path": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "path",
      +      "content"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • changedInput schema / properties / format / description
      Previous value: -"Omit: a known filename extension decides, else the server detects html, markdown, code or JSON. `html` keeps code/JSON as HTML; also markdown/md or a code language. A whole HTML document sent as markdown becomes an HTML page."New value: +"html, markdown or a code language; omitted: by file name, else by content"
    • removedInput schema / properties / format / minLength
      Removed value: -1
    • changedInput schema / properties / namespace / description
      Previous value: -"Send namespace=public for anything meant to be found or shared (docs, guides, demos, portfolios, reports, landing pages): listed in the public gallery and sitemap, so Google, Bing and AI search index it and people discover it. Public pages are served on the brewpage.app domain itself, for the strongest search reach; code that needs its own origin (cookies, storage) gets its own subdomain automatically. Anyone can find and read a public page, so it is unsuitable for secrets, tokens or personal data. Omit (default): private, a generated priv-* namespace; unlisted, not indexed; the link still opens it. Lowercase only: 1-32 of a-z, 0-9, hyphen."New value: +"`public` for anything meant to be found or shared: listed in the gallery and sitemap, indexed by Google, Bing and AI search; unsuitable for secrets or personal data. Omit (default): private, a generated priv-* namespace, unlisted; the link still opens it. A custom name: 1-32 of a-z, 0-9, hyphen."
    • changedInput schema / properties / ownerToken / description
      Previous value: -"Optional; the ownerToken from your first create keeps publications under one owner. Default: env BREWPAGE_OWNER_TOKEN (local server only), else a new token per create."New value: +"Owner token of an earlier create"
    • removedInput schema / properties / password / description
      Removed value: -"Optional password to protect the page"
    • changedInput schema / properties / showTopBar / description
      Previous value: -"Add a thin top toolbar (filename + Download button + theme toggle) on the served page. Default: hidden."New value: +"Top toolbar with file name and Download"
    • removedInput schema / properties / state / anyOf
      Removed value: -[
      -  {
      -    "additionalProperties": {},
      -    "propertyNames": {
      -      "type": "string"
      -    },
      -    "type": "object"
      -  },
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • changedInput schema / properties / state / description
      Previous value: -"Page data config (the `state` API): `{collections: {<name>: {mode: 'private'|'shared', write?: 'author'}}}`; full reference: guide topic `page-data`. HTML pages and sites, not Markdown; the page gets its own address."New value: +"Page data config; `{}` = on with defaults"
    • addedInput schema / properties / state / type
      Added value: +[
      +  "object",
      +  "null"
      +]
    • addedInput schema / properties / tags
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • removedInput schema / properties / ttlDays / anyOf
      Removed value: -[
      -  {
      -    "exclusiveMinimum": 0,
      -    "type": "number"
      -  },
      -  {
      -    "maxLength": 32,
      -    "minLength": 1,
      -    "type": "string"
      -  }
      -]
    • changedInput schema / properties / ttlDays / description
      Previous value: -"TTL in days: up to 30 days without an account, up to 90 with a free profile (pass an ownerToken held in the profile); a default applies when omitted. Accepts whole days: 15, '15d', '15 days'. The returned expiresAt is the actual expiry."New value: +"Days to keep it: up to 30 days without an account, up to 90 with a free profile (an ownerToken held in the profile). Omitted: the default. The result states the expiry."
    • addedInput schema / properties / ttlDays / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / ttlDays / type
      Added value: +"number"
    • removedInput schema / required
      Removed value: -[
      -  "content"
      -]
  2. Changed1 schema field changed
    • changedInput schema / properties / ttlDays / description
      Previous value: -"Requested TTL: days as a number, or a string such as '2w', '36h' or '1 month' (default 15 days). The server rounds to whole days and clamps to the allowed range (1-30; up to 90 with an owner token in a profile), reporting each adjustment in notices; the returned expiresAt is the actual expiry."New value: +"TTL in days: up to 30 days without an account, up to 90 with a free profile (pass an ownerToken held in the profile); a default applies when omitted. Accepts whole days: 15, '15d', '15 days'. The returned expiresAt is the actual expiry."
  3. Changed1 schema field changed
    • changedInput schema / properties / domain / description
      Previous value: -"Optional domain the user owns (www.example.com or example.com) to connect to the new publication. Works when the owner token is in a free BrewPage profile, without a password. The publication is always created; the result lists the DNS records for the domain owner to create, or says why the domain was not set."New value: +"Optional custom domain for the new publication: a bare hostname the user owns (www.example.com or example.com, no scheme or path). Needs a profile token or an owner token added to a free BrewPage profile, and no password. The publication is always created; the result lists the DNS records for the domain owner to create, or says why the custom domain was not set."
  4. Changed1 schema field changed
    • addedInput schema / properties / state
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": {},
      +      "propertyNames": {
      +        "type": "string"
      +      },
      +      "type": "object"
      +    },
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Page data config (the `state` API): `{collections: {<name>: {mode: 'private'|'shared', write?: 'author'}}}`; full reference: guide topic `page-data`. HTML pages and sites, not Markdown; the page gets its own address."
      +}
  5. Changed1 schema field changed
    • addedInput schema / properties / domain
      Added value: +{
      +  "description": "Optional domain the user owns (www.example.com or example.com) to connect to the new publication. Works when the owner token is in a free BrewPage profile, without a password. The publication is always created; the result lists the DNS records for the domain owner to create, or says why the domain was not set.",
      +  "type": "string"
      +}
  6. Changed2 schema fields changed
    • changedInput schema / properties / filename / description
      Previous value: -"Optional original filename (≤200 chars). Used as title fallback when no <title>/<h1>; immutable on update."New value: +"Optional original filename (≤200 chars). Without `format`, a known extension sets the format (.md stays Markdown, even a whole HTML document). Used as title fallback when no <title>/<h1>; immutable on update."
    • changedInput schema / properties / format / description
      Previous value: -"Omit: server detects html, markdown, code or JSON. `html` keeps code/JSON as HTML; also markdown/md or a code language."New value: +"Omit: a known filename extension decides, else the server detects html, markdown, code or JSON. `html` keeps code/JSON as HTML; also markdown/md or a code language. A whole HTML document sent as markdown becomes an HTML page."
  7. Changed1 schema field changed
    • changedInput schema / properties / namespace / description
      Previous value: -"namespace=public: listed in the public gallery and the sitemap, so Google, Bing and AI search can find and index it and people can discover it. Suits anything meant to be found or shared: docs, guides, demos, portfolios, reports, landing pages. Public pages are served right on the brewpage.app domain, which gives them the strongest reach in search; a page whose code needs its own origin (cookies, storage) gets its own subdomain automatically. Anyone can find and read a public page, so it is unsuitable for secrets, tokens or personal data. Omit (default): private. Unlisted and not indexed; anyone who has the link can still open it. Lowercase only: 1-32 of a-z, 0-9, hyphen."New value: +"Send namespace=public for anything meant to be found or shared (docs, guides, demos, portfolios, reports, landing pages): listed in the public gallery and sitemap, so Google, Bing and AI search index it and people discover it. Public pages are served on the brewpage.app domain itself, for the strongest search reach; code that needs its own origin (cookies, storage) gets its own subdomain automatically. Anyone can find and read a public page, so it is unsuitable for secrets, tokens or personal data. Omit (default): private, a generated priv-* namespace; unlisted, not indexed; the link still opens it. Lowercase only: 1-32 of a-z, 0-9, hyphen."
  8. Changed1 schema field changed
    • changedInput schema / properties / ownerToken / description
      Previous value: -"Optional. Default: env BREWPAGE_OWNER_TOKEN (local server only), else a new token per create."New value: +"Optional; the ownerToken from your first create keeps publications under one owner. Default: env BREWPAGE_OWNER_TOKEN (local server only), else a new token per create."
  9. Changed1 schema field changed
    • changedInput schema / properties / ttlDays / description
      Previous value: -"Requested TTL: days as a number, or a string such as '2w', '36h' or '1 month' (default 15 days). The server rounds to whole days and clamps to the allowed range (1-30 by default; owner caps differ), reporting each adjustment in notices; the returned expiresAt is the actual expiry."New value: +"Requested TTL: days as a number, or a string such as '2w', '36h' or '1 month' (default 15 days). The server rounds to whole days and clamps to the allowed range (1-30; up to 90 with an owner token in a profile), reporting each adjustment in notices; the returned expiresAt is the actual expiry."
  10. Changed1 schema field changed
    • changedInput schema / properties / ownerToken / description
      Previous value: -"Optional. Default: BREWPAGE_OWNER_TOKEN, else a new token per create."New value: +"Optional. Default: env BREWPAGE_OWNER_TOKEN (local server only), else a new token per create."
  11. Changed3 schema fields changed
    • changedInput schema / properties / content / description
      Previous value: -"HTML or Markdown content to publish"New value: +"HTML, Markdown, code or JSON to publish"
    • removedInput schema / properties / format / default
      Removed value: -"HTML"
    • changedInput schema / properties / format / description
      Previous value: -"Content format, default HTML. HTML or MARKDOWN; the server also maps aliases (md, text/markdown, file extensions, code languages) and detects unknown values from content, reporting the change in notices."New value: +"Omit: server detects html, markdown, code or JSON. `html` keeps code/JSON as HTML; also markdown/md or a code language."
  12. Changed2 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
  13. Changed2 schema fields changed
    • changedInput schema / properties / namespace / description
      Previous value: -"namespace=public: listed in the public gallery and the sitemap, so Google, Bing and AI search can find and index it and people can discover it. Use it for anything meant to be found or shared: docs, guides, demos, portfolios, reports, landing pages. Public pages are served right on the brewpage.app domain, which gives them the strongest reach in search; a page whose code needs its own origin (cookies, storage) gets its own subdomain automatically. Anyone can find and read a public page: never put secrets, tokens or personal data there. Omit (default): private. Unlisted and not indexed; anyone who has the link can still open it. Lowercase only: 1-32 of a-z, 0-9, hyphen."New value: +"namespace=public: listed in the public gallery and the sitemap, so Google, Bing and AI search can find and index it and people can discover it. Suits anything meant to be found or shared: docs, guides, demos, portfolios, reports, landing pages. Public pages are served right on the brewpage.app domain, which gives them the strongest reach in search; a page whose code needs its own origin (cookies, storage) gets its own subdomain automatically. Anyone can find and read a public page, so it is unsuitable for secrets, tokens or personal data. Omit (default): private. Unlisted and not indexed; anyone who has the link can still open it. Lowercase only: 1-32 of a-z, 0-9, hyphen."
    • changedInput schema / properties / ttlDays / description
      Previous value: -"Requested TTL: days as a number, or a string such as '2w', '36h' or '1 month' (default 15 days). The server rounds to whole days and clamps to the allowed range (1-30 by default; owner caps differ), reporting each adjustment in notices; use returned expiresAt."New value: +"Requested TTL: days as a number, or a string such as '2w', '36h' or '1 month' (default 15 days). The server rounds to whole days and clamps to the allowed range (1-30 by default; owner caps differ), reporting each adjustment in notices; the returned expiresAt is the actual expiry."
  14. First observed

TDQS

A4/5.0
Behavior5/5

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

Beyond the annotations, which only say this is a non-read-only, non-destructive write, the description discloses the return shape (share link, owner token, manageUrl with edit/delete power), a security constraint (owner tokens and manage links never appear in published content), listing/indexing consequences of `public` versus private `priv-*` namespaces, and retention behavior with the result stating expiry.

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?

The size limit and the two publish modes are front-loaded, so the most decision-relevant facts arrive first. The remaining sentences are dense and parenthetical, but each carries a concrete constraint (size caps, badge rule, token secrecy) rather than filler.

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

Completeness4/5

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

For a 14-parameter write tool with no output schema, the description covers what is returned, the size and count limits, security rules around owner tokens, and the badge restriction, which is a strong base. The main remaining gap is routing against sibling publish tools when the payload is plain JSON or a generic file.

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 71% and the schema descriptions are already detailed for `namespace`, `ttlDays`, `ownerToken` and `entry`. The description still adds meaning the schema lacks: the 5 MiB cap on `content`, the 200-file / 20 MiB cap on `files`, and the link between the `state` parameter and guide topic `page-data`.

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

Purpose4/5

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

The description states a specific verb and resource ('Publish a page ... or a static site') and separates the two modes by their key parameter (`content` vs `files`), so an agent knows exactly what the tool does. It does not, however, distinguish this from siblings such as publish_file or publish_json, even though the accepted content types (HTML, Markdown, code or JSON) clearly overlap with them.

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

Usage Guidelines3/5

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

Usage context is implied rather than prescribed: it says a page that saves visitor input needs `state` plus a script from guide topic `page-data`, and it warns that `namespace: public` is unsuitable for secrets. There is no explicit when-to-use-this-vs-alternative guidance, despite publish_file/publish_json being obvious candidates.

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.