Skip to main content
Glama

Deploy hosted app

deploy_app
Destructive

Start from a recipe: read_documentation hosted_apps, then the hosted_apps_recipe_* topic closest to the request (gallery, upload against a brief, review; for guests without an account: client approval, garage sale, workshop RSVP), and change that app rather than writing one from scratch. Keep content that changes — briefs, captions, prices, names — on the folder (its description, asset titles and fields), not in the files, so the team edits it in Playbook without a redeploy. Put a small web app that you wrote live at its own address, or replace the files of the app this workspace already has under the same slug. A hosted app is static files — HTML, CSS, JavaScript, no build step — that show ONE folder and its subfolders: a gallery, a portfolio, a catalogue. Returns the app's url, and warnings when Playbook spots a likely mistake in the files: fix each one and deploy again. The hosted_apps topic has the contract. In short, the page reads the folder through its own address: a GET of the RELATIVE URL playbook/api/<path> returns the Playbook REST API's answer to /v1/{organization}/<path> (e.g. playbook/api/assets?nested_assets=true), and playbook/app answers { board } (the folder; the app API keeps that name). The page needs and gets no token; every URL in the app must be relative. access sets who may open it: members (the default for a new app: people who can view the folder in Playbook, after signing in), public (anyone with the address), or password (visitors who give password). Make an app public only when the user asks for it; a deploy without access keeps an existing app's access. Whoever gets in sees everything on the folder, unapproved assets and uploader names included, and folders added under it later too, so confirm the folder with the user before deploying. The folder's own share settings do not protect the app, but its share link's watermark is on every image the app reads, and while that link allows downloads visitors can download originals through playbook/download, with the link's password if it has one; a subfolder whose own share link has a password gives its files that password and that link's terms (see the topic). Everything in files is served to every visitor: never put a token, a key, or content read from another folder into them. Visitors may upload into the folder (playbook/upload, see the topic): allowed while the folder's share link has Allow uploads or the upload-only page on, with no password, no email form and no past expiry, or, in an app that is not public, for a signed-in visitor who may upload to the folder. In a members app the page may also change the folder's assets as the signed-in visitor, with their permissions: title, description, status, fields, tags, approval and comments (see the topic), and read an asset's comments as that visitor sees them; public and password apps cannot read comments. A public or password app may also take guests through a playbook.json file (see the topic): visitors who sign up by name or enter a PIN from create_app_guest, and then run only the actions it declares on one item at a time — write set values into Status, select and typed fields under a condition, or leave an answer such as an RSVP or a vote. A guest's email and phone may only go into members-only fields (create_custom_field members_only), and guest text must be shown with textContent. Nothing else is written: no deletes, moves or folder changes. A redeploy without access keeps the app's access. Limits: an index.html is required; text files only (.html .css .js .mjs .json .svg .txt .webmanifest); at most 50 files and 1 MB in total — images stay in Playbook and are never part of the app. The workspace's plan caps how many apps it may have: a new app over the cap is refused with the reason, while replacing the files of an existing app never is. A deploy replaces the whole file set, so send every file each time, not only the changed ones; to change a few files of an existing app, edit_app_source is lighter. Every deploy, even of the same files, is kept as a new numbered version, and past 50 the oldest is dropped. The app reads the folder as whoever deployed it last. If the call times out, check list_app_versions before deploying again: a deploy that landed is already live, and a repeat adds another version. Requires write scope and permission to edit the folder.

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": {
      "folder_token": "<folder_token>",
      "slug": "<slug>",
      "name": "<name>",
      "files": "<files>"
    },
    "name": "deploy_app"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesDisplay name of the app, at most 100 characters
slugYesThe app's address: lowercase letters, digits and hyphens, at most 63 characters, starting with a letter or digit. Unique across all of Playbook, so make it specific; one taken by another workspace is refused with a 422. A slug this workspace already uses replaces that app's files.
filesYesThe complete file set: contents as text, keyed by path relative to the app's root, e.g. { "index.html": "<!doctype html>…", "app.js": "…", "styles.css": "…" }. Paths are plain names joined by `/` and `.`, with no leading slash. A top-level `worker.js` is the app's optional backend and is not served as a file; leave it out unless the `hosted_apps` topic says you need one. Nothing may sit under `playbook/`, which Playbook answers itself.
accessNoWho may open the app. Omit to make a new app `members` and to keep an existing app's access. `public` only when the user asks for it.
commentNoA note stored with the new version, shown by list_app_versions
passwordNoFor `password` access: at least 8 characters, and only on plans with share-link passwords. Omit to keep the app's current password.
folder_tokenYesToken of the folder the app shows, from list_folders. Its subfolders are readable too; nothing else in the workspace is.
organizationNoWorkspace slug, as returned by list_organizations. Omit it when the account has a single workspace — it is then resolved from your token. Pass it only when the account has several, or when you mean a workspace other than the obvious one.
expected_versionNoWhen replacing an existing app: its `head_version_number` as you last read it. The deploy is refused with `stale_app` if the app changed since, instead of overwriting someone else's change.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • removedInput schema / properties / board_token
      Removed value: -{
      -  "description": "Token of the board the app shows, from list_boards. Its sub-boards are readable too; nothing else in the workspace is.",
      -  "type": "string"
      -}
    • addedInput schema / properties / folder_token
      Added value: +{
      +  "description": "Token of the folder the app shows, from list_folders. Its subfolders are readable too; nothing else in the workspace is.",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "board_token",
      -  "slug",
      -  "name",
      -  "files"
      -]New value: +[
      +  "folder_token",
      +  "slug",
      +  "name",
      +  "files"
      +]
  2. Changed1 schema field changed
    • changedInput schema / properties / access / description
      Previous value: -"Who may open the app. Omit to make a new app `public` and to keep an existing app's access."New value: +"Who may open the app. Omit to make a new app `members` and to keep an existing app's access. `public` only when the user asks for it."
  3. Changed2 schema fields changed
    • addedInput schema / properties / comment
      Added value: +{
      +  "description": "A note stored with the new version, shown by list_app_versions",
      +  "type": "string"
      +}
    • addedInput schema / properties / expected_version
      Added value: +{
      +  "description": "When replacing an existing app: its `head_version_number` as you last read it. The deploy is refused with `stale_app` if the app changed since, instead of overwriting someone else's change.",
      +  "maximum": 9007199254740991,
      +  "minimum": 1,
      +  "type": "integer"
      +}
  4. Changed2 schema fields changed
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / files / propertyNames
      Added value: +{
      +  "type": "string"
      +}
  5. Changed2 schema fields changed
    • addedInput schema / properties / access
      Added value: +{
      +  "description": "Who may open the app. Omit to make a new app `public` and to keep an existing app's access.",
      +  "enum": [
      +    "members",
      +    "password",
      +    "public"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / password
      Added value: +{
      +  "description": "For `password` access: at least 8 characters, and only on plans with share-link passwords. Omit to keep the app's current password.",
      +  "minLength": 8,
      +  "type": "string"
      +}
  6. Added

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true and idempotentHint=false, and the description explains exactly why: a deploy replaces the whole file set, retains every deploy as a numbered version, drops the oldest past 50, and adds a version even for identical files. It further discloses auth requirements (write scope plus folder edit permission), plan app caps, timeout recovery via list_app_versions, and data-exposure consequences — well beyond the annotation surface, with no contradiction.

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

Conciseness2/5

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

The definition is a single dense block of roughly 600+ words with no headings or bullets, and it is not front-loaded: the tool's own action trails a multi-sentence recipe/onboarding preamble. Almost every sentence carries real information, but the sheer volume and flat structure make it hard for an agent to locate the operative constraints quickly.

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 9-parameter destructive deploy with nested file objects and no output schema, the description covers the return values (url, warnings), the app's runtime API contract, security boundaries (no tokens in files, relative URLs only, watermark/password inheritance), guest/upload semantics, and failure recovery. Nothing an agent needs to call this safely appears to be 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 100%, so the baseline is 3, but the description adds real meaning: the `access` enum is expanded into who each tier admits and the default-omission behavior, `folder_token` scope is clarified (subfolders readable, nothing else), and `expected_version` staleness is tied to the `stale_app` refusal. It does not add much on `files` structure, which the schema already covers in depth.

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 core action is stated concretely: "Put a small web app that you wrote live at its own address, or replace the files of the app this workspace already has under the same `slug`," and it distinguishes itself from edit_app_source. However, the purpose arrives after a full recipe-routing preamble, so an agent scanning the first lines reads onboarding instructions rather than what the tool does; the verb 'deploy' only appears many sentences later.

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 alternatives and exclusions are given: use edit_app_source to change a few files of an existing app, read the hosted_apps_recipe_* topic closest to the request, and only make an app public when the user asks. It also states the condition for the sibling route ("to change a few files of an existing app, edit_app_source is lighter") and requires confirming the folder with the user before deploying.

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.

Resources