dotsy · Schema

ApplyChangesetBody

A batch of content writes and deletes. Send at least one write or delete. `.dotsy/*` and `.structure/*` keys are reserved, and CSS or JavaScript files belong in the asset store (`asset_write_not_allowed`).

CompanyArtificial IntelligenceWebsite BuilderNo-CodeFree

Properties

Name Type Description
writes array Content to write. A key cannot appear in both `writes` and `deletes`.
deletes array Content keys to delete: a key, or `{ key, ifMatch }` with the `contentHash` you read. If that page changed since, it is not deleted and is listed in `conflicts` (with `atomic: true`, nothing is writte
message string Short note for the site's edit history (up to 2,000 characters).
atomic boolean All or nothing. Every write's and delete's `ifMatch` is checked before any key is written: one stale key writes nothing and the answer is 409 `changeset_conflict` with `conflicts`. A changeset too lar
View JSON Schema on GitHub

JSON Schema

dotsy-ai-apply-changeset-body-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/dotsy-ai/json-schema/dotsy-ai-apply-changeset-body-schema.json",
  "title": "ApplyChangesetBody",
  "description": "A batch of content writes and deletes. Send at least one write or delete. `.dotsy/*` and `.structure/*` keys are reserved, and CSS or JavaScript files belong in the asset store (`asset_write_not_allowed`).",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/dotsy-ai-content-api-openapi.yml#/components/schemas/ApplyChangesetBody",
  "type": "object",
  "properties": {
    "writes": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/ChangesetWrite"
      },
      "default": [],
      "description": "Content to write. A key cannot appear in both `writes` and `deletes`."
    },
    "deletes": {
      "type": "array",
      "items": {
        "anyOf": [
          {
            "type": "string",
            "minLength": 1
          },
          {
            "type": "object",
            "properties": {
              "key": {
                "type": "string",
                "minLength": 1
              },
              "ifMatch": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "key",
              "ifMatch"
            ]
          }
        ]
      },
      "default": [],
      "description": "Content keys to delete: a key, or `{ key, ifMatch }` with the `contentHash` you read. If that page changed since, it is not deleted and is listed in `conflicts` (with `atomic: true`, nothing is written). The site brief and `_data/*` keys are skipped (listed in `skippedDeletes`). Site custom code (`_site/code-head.html`, `_site/code-body.html`) is never written or deleted here — it is listed in `skipped`; use PUT /custom-code."
    },
    "message": {
      "type": "string",
      "maxLength": 2000,
      "description": "Short note for the site's edit history (up to 2,000 characters)."
    },
    "atomic": {
      "type": "boolean",
      "description": "All or nothing. Every write's and delete's `ifMatch` is checked before any key is written: one stale key writes nothing and the answer is 409 `changeset_conflict` with `conflicts`. A changeset too large to apply in one request is checked against the draft before it is queued; a write that lands between that check and the queued job is still caught per key and listed in the job's `conflicts`."
    }
  },
  "$defs": {
    "ChangesetRouteInput": {
      "type": "object",
      "properties": {
        "contentKey": {
          "type": [
            "string",
            "null"
          ],
          "minLength": 1,
          "description": "Explicit content key (defaults to a path-derived key when omitted). null clears an explicit key back to that path default — same as omitting it, but usable on a PATCH to undo a prior set."
        },
        "layout": {
          "type": [
            "string",
            "null"
          ],
          "description": "Layout NAME, bare: \"default\" for layouts/default.html — not the file key. It must already exist as layouts/<name>.html (400 layout_not_found otherwise). null removes the layout."
        },
        "title": {
          "type": [
            "string",
            "null"
          ]
        },
        "vars": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": "string"
          }
        },
        "purpose": {
          "type": [
            "string",
            "null"
          ]
        },
        "redirectTo": {
          "type": [
            "string",
            "null"
          ],
          "minLength": 1,
          "description": "Redirect target, a root-relative path (/…). Required when purpose is \"redirect\". null clears it — only valid once purpose stops being \"redirect\" (a redirect route always needs a target)."
        },
        "redirectStatus": {
          "anyOf": [
            {
              "type": "number",
              "enum": [
                301
              ]
            },
            {
              "type": "number",
              "enum": [
                302
              ]
            },
            {
              "type": "number",
              "enum": [
                308
              ]
            },
            {
              "type": "null"
            }
          ],
          "description": "301 permanent / 302 or 308 temporary (default 301 on a redirect). null clears an explicit override."
        },
        "preserveQuery": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Append the visitor's original query string to the redirect target (default true on a redirect). null clears an explicit override."
        },
        "navLabel": {
          "type": [
            "string",
            "null"
          ],
          "description": "DEPRECATED — use put_menu_item / menu API. Menu link text for <dotsy-nav> (separate from title). Still accepted during transition and synced to menu items."
        },
        "nav": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "object",
            "properties": {
              "menu": {
                "type": "string",
                "minLength": 1,
                "description": "Menu this page joins — matches a <dotsy-nav menu=\"…\"> in the layout/fragment (e.g. \"primary\", \"footer\")."
              },
              "order": {
                "type": "integer",
                "description": "Sort position among siblings in this menu, ascending. Use gaps (10, 20, 30) to leave room for inserts."
              },
              "parent": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Parent route path within this menu for a nested/dropdown item (e.g. \"/services\"). Omit for top level."
              }
            },
            "required": [
              "menu"
            ]
          },
          "description": "DEPRECATED — use put_menu_item / menu API. Menu memberships on the route row. Still accepted during transition and synced to menu items. See get_skill('nav')."
        },
        "experiment": {
          "type": [
            "object",
            "null"
          ],
          "properties": {
            "id": {
              "type": "string",
              "pattern": "^[a-z0-9-]+$",
              "description": "Stable experiment slug — cookie namespace; unique per site forever."
            },
            "name": {
              "type": "string",
              "minLength": 1,
              "maxLength": 80
            },
            "hypothesis": {
              "type": "string",
              "maxLength": 200
            },
            "status": {
              "type": "string",
              "enum": [
                "draft",
                "running",
                "ended"
              ]
            },
            "variants": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "pattern": "^[a-z0-9-]+$",
                    "description": "Variant arm id — default \"a\" / \"b\" on create."
                  },
                  "label": {
                    "type": "string",
                    "maxLength": 80
                  },
                  "weight": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 100
                  },
                  "contentKey": {
                    "type": "string",
                    "minLength": 1,
                    "description": "Published body key (may be routeless)."
                  }
                },
                "required": [
                  "id",
                  "weight",
                  "contentKey"
                ]
              },
              "minItems": 2,
              "maxItems": 3
            },
            "goalId": {
              "type": "string",
              "minLength": 1,
              "description": "Optional dotsy conversion goal; omit when tracking in external analytics."
            },
            "changeNote": {
              "type": "string",
              "maxLength": 120,
              "description": "One line on what the variant changes (0.56e M2). Kept here so route PATCH round-trips (weights/settings updates) don't strip it."
            },
            "handsOff": {
              "type": "boolean",
              "description": "Hands-off mode (0.56e M4): the daily sweep may auto-promote a ≥95% winner or auto-end keep-A after 30 days. Prefer setting this via start_test; kept here so route PATCH round-trips (weights/settings updates) don't strip the flag."
            },
            "startedAt": {
              "type": "string"
            },
            "endedAt": {
              "type": "string"
            }
          },
          "required": [
            "id",
            "name",
            "status",
            "variants"
          ]
        },
        "noindex": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Exclude from sitemap/RSS; inject noindex meta (0.69)."
        }
      },
      "description": "The route's settings: layout, title, purpose (`redirect` with `redirectTo`), noindex, and so on."
    },
    "ChangesetWrite": {
      "type": "object",
      "properties": {
        "key": {
          "type": "string",
          "minLength": 1,
          "description": "Content key to write: a page (`about.html`), a layout (`layouts/<name>.html`) or a fragment (`fragments/<name>.html`). A `<dotsy-fragment name>` tag and a route's `layout` use the bare name, not the key."
        },
        "body": {
          "type": "string",
          "maxLength": 5000000,
          "description": "The whole file as text. Send exactly one of `body` or `bodyStaging`."
        },
        "bodyStaging": {
          "type": "string",
          "pattern": "^stg_[a-zA-Z0-9_-]+$",
          "description": "Id of a finished staging session (`stg_…`) holding a body too large to inline. Send exactly one of `body` or `bodyStaging`."
        },
        "contentType": {
          "type": "string",
          "description": "Stored Content-Type. Defaults to `text/html; charset=utf-8`, or the staging session's type."
        },
        "ifMatch": {
          "type": "string",
          "description": "The `contentHash` you read. If the key changed since, this write is not applied and is listed in `conflicts`."
        },
        "route": {
          "type": "object",
          "properties": {
            "path": {
              "type": "string",
              "minLength": 1,
              "description": "URL path the page serves at."
            },
            "input": {
              "$ref": "#/$defs/ChangesetRouteInput"
            }
          },
          "required": [
            "path",
            "input"
          ],
          "description": "Create or update the route for this page in the same call."
        },
        "menuItems": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "sort": {
                "type": "integer"
              },
              "parent": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "label": {
                "type": "string",
                "minLength": 1
              },
              "kind": {
                "type": "string",
                "enum": [
                  "page",
                  "url",
                  "anchor",
                  "mailto",
                  "group"
                ]
              },
              "ref": {
                "type": "string"
              },
              "newTab": {
                "type": "boolean",
                "default": false
              },
              "attrs": {
                "type": "object",
                "additionalProperties": {
                  "type": "string"
                }
              },
              "data": {
                "type": "object",
                "additionalProperties": {
                  "type": "string"
                }
              },
              "html": {
                "type": "string"
              },
              "childShell": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "childTemplate": {
                "type": "string"
              },
              "menu": {
                "type": "string",
                "minLength": 1
              },
              "id": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "sort",
              "parent",
              "label",
              "kind",
              "ref",
              "menu"
            ]
          },
          "description": "Menu items to place in the same call. Each names its `menu`."
        }
      },
      "required": [
        "key"
      ]
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/dotsy-ai-apply-changeset-body"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.