Skip to main content
← All documentationContents ↓

API Reference: Websites & Pages

Manage team websites end to end: sites, pages and designs, announcements and popups, publishing and readiness checks, imports, backups, templates, layouts, review comments, and protected areas.

Overview

The Websites API is the programmatic surface behind Website Studio. It covers the full lifecycle of a team website: creating and configuring sites, reading and editing pages and their block-based designs, managing popups and banners, running publish-readiness checks and publishing, importing an external site, taking and restoring backups, working with team website templates and reusable layouts, review comments, and gated protected areas. This reference leads with the most useful integration flows and summarizes each sub-area with an endpoint table.

The same operations power the hosted MCP server's website tools (for example list_websites, get_website_page, run_website_publish_readiness, and the draft_* editing tools), so an agent connected over MCP and a REST integration see one consistent contract. One MCP/TeamAgent-only tool, plan_website_release, has no single REST counterpart here: it drafts one approval-gated proposal covering a whole release (Style Kit, page designs, headers and footers, metadata, and optionally publishing) by reusing these same REST-backed editing operations as internal steps — see Website Releases in the MCP Server reference. A REST/SDK caller reaches the same effect by calling each resource's own endpoint below and approving each proposal individually.

Key Concepts

  • Website — A team site identified by websiteSimplyId, carrying settings such as name, theme, navigation, header/footer designs, announcements and popups, languages, and publish state.
  • Page — A page identified by pageSimplyId with a draft design and a published design. Designs are block-based documents; edits target the draft, publishing promotes it.
  • Blocks and design patches — A page design is read as a bounded document and edited by submitting validated patch operations rather than replacing raw markup.
  • Publish readiness — A server-side checklist (missing metadata, broken references, and similar) you can run before publishing.
  • Templates and layouts — Team website templates release versioned snapshots that new sites can be created from and connected sites can sync to; the layout catalog and team-saved layouts provide reusable section designs.
  • Protected areas — Gated sections of a website whose pages require membership; effective access is inherited down the page tree.

Authentication and Tiers

Almost the entire cluster is standard tier, scope-checked as websites:read for reads and websites:write for writes. The route handlers require user-backed first-party authentication — a Simply360 session (Cognito) or a user-consented OAuth access token (which is how the hosted MCP server calls them) — sent as a bearer token, plus a selected team via the X-Team-Id header (team simplyId) or a teamSimplyId query parameter. Requests authenticated with a team API key (Authorization: Bearer s360_live_...) are rejected with 403 COGNITO_REQUIRED on the legacy website editing routes. The backup and recovery routes below support scoped team API keys for metadata, inspection, and authorized domain operations; human preview sessions require a current Team User. Callers additionally need the TEAM_WEBSITES or TEAM_ADMIN_WEBSITES feature permission, and per-website role permissions apply.

A few adjacent operations are privileged tier (first-party admin only) and are covered briefly at the end of this article: custom-domain management, external-website links, and the protected area team-user auth broker. See Authentication and Error Handling for the general envelope; all responses use the standard data/meta wrapper.

Websites

MethodPathDescription
GET/v1/websitesList websites for the selected team.
POST/v1/websitesCreate a website (body: name required, slug optional). Returns 201.
GET/v1/websites/{websiteSimplyId}Get a website.
PUT/v1/websites/{websiteSimplyId}Update website settings (see below).
DELETE/v1/websites/{websiteSimplyId}Delete a website.
POST/v1/websites/{websiteSimplyId}/blog/setupCreate default blog pages.
POST/v1/websites/{websiteSimplyId}/translate/startStart website translation into additional languages.

Start any integration by listing sites and picking a websiteSimplyId:

curl -s "https://api.simply360.app/v1/websites" \
  -H "Authorization: Bearer $S360_ACCESS_TOKEN" \
  -H "X-Team-Id: TEAM-1234-ABCD"

PUT /v1/websites/{websiteSimplyId} accepts the site's configurable fields; all are optional and only supplied fields change:

FieldTypeDescription
namestringDisplay name.
isPublishedbooleanSite publish state. First-time publishes may require an activationToken.
activationTokenstringShort-lived token from POST .../publish-activation when publish activation is required.
metaTitle / metaDescription / socialImageUrlstringDefault SEO and share metadata. socialImageUrl is a deprecated legacy literal URL; the renderer still emits it as the last og:image fallback only when no explicit File-backed share-image binding is configured. An unavailable explicit File binding is refused without using this URL; prefer defaultShareImageFileSimplyId.
faviconFileSimplyId / faviconFileVersionNumberstring | null / integer | nullFavicon by File simplyId, pinned to the exact File version in faviconFileVersionNumber. Send the version only together with faviconFileSimplyId; a version on its own, or a version with a null File, fails with 400. null on faviconFileSimplyId clears the favicon and its version. Without a version (omitted or null), a new favicon File is stored without an exact pin (it follows the File's current version), and re-sending the same File keeps an existing pin. Reads return the stored faviconFileVersionNumber, or null when the favicon is not pinned.
defaultShareImageFileSimplyId / defaultShareImageFileVersionNumber / shareImageAltstring | null / integer / string | nullDefault social share image (og:image/twitter:image) by File simplyId, pinned to the exact File version in defaultShareImageFileVersionNumber, plus its alt text. A page's own ogImageFileId overrides this. null clears the File (and its version) or the alt text.
themeSettingsobjectStrict theme configuration. Supported properties are the documented color, font, button, brand, public logo/favicon URL, gradient, docs-mode, visitorAccessibilityOptions (boolean; true shows the optional visitor "Accessibility options" panel on published pages, absent or false hides it; send the whole object because a theme update replaces it), teamStyleKitSimplyId, logoFileSimplyId + logoFileVersionNumber (website-level logo File pinned to an exact version; distinct from the shared Style Kit's own logo), and appleTouchIconFileSimplyId + appleTouchIconFileVersionNumber (falls back to the favicon File when unset) fields; unknown properties are rejected.
navigationJsonobjectNavigation model, version 2: { "version": 2, "menus": [...] } with 1–20 named menus; page items must reference pageSimplyId. (navigationSettings is a deprecated alias.)
headerDesignJson / footerDesignJsonobject | nullDraft site-wide header/footer designs (publish them via POST .../header-footer/publish). null clears either one, so pages without their own pageHeaderDesignJson/pageFooterDesignJson render no header or footer; arrays and other non-object values are rejected with 400.
campaignChromeConfigobject | nullStrict { "version": 2, "popups": [...] } draft with up to ten BANNER, MODAL, SLIDE_IN, or CONVERSATION entries. The /v1 endpoint namespace is the API path version; campaign-config version 1 is not accepted. Enabled design entries require localized accessible labels and sanitized meaningful content. Wizard and newsletter components are allowed only in modal and slide-in designs.
expectedCampaignChromeConfigDigestSha256stringOptional campaign draft concurrency precondition. Hash the exact loaded campaignChromeConfig (including null) with the SDK's getWebsiteCampaignChromeConfigDigest, then send the digest with its replacement. A stale digest returns HTTP 409 WEBSITE_CAMPAIGN_CHROME_CONFLICT without saving. Reload and merge your intended edit before retrying; omitting the precondition preserves unguarded update behavior.
googleAnalyticsMeasurementIdstring | nullStored and returned, but not used. No Website renders it, so no visits are sent to Google Analytics with it, and Website Studio no longer lets you edit it. Accepts G- followed by 4–15 letters or digits (case-insensitive); an empty string or null clears it.
defaultLanguageTagId / availableLanguageTagIdsstring / string[]Language configuration.
redirectSettingsobject | nullRedirect rules.

Every referenced File for the four File-backed brand asset fields above (faviconFileSimplyId, themeSettings.logoFileSimplyId, themeSettings.appleTouchIconFileSimplyId, defaultShareImageFileSimplyId) must already be PUBLIC — upload it with create_file_upload/upload_file purpose: "WEBSITE_MEDIA" and this websiteSimplyId first; a non-PUBLIC file is rejected. The share image, logo, and apple-touch icon are exact version pins: changing defaultShareImageFileSimplyId, themeSettings.logoFileSimplyId, or themeSettings.appleTouchIconFileSimplyId to a File requires its paired defaultShareImageFileVersionNumber, themeSettings.logoFileVersionNumber, or themeSettings.appleTouchIconFileVersionNumber naming a verified image version of that File, or the request fails with 400 WEBSITE_BRAND_ASSET_VERSION_REQUIRED; re-sending an unchanged File keeps its existing pin. The favicon takes the same exact pin through faviconFileVersionNumber, and a version that is not a verified image of that File fails with 400 FAVICON_VERSION_NOT_VERIFIED. This route does not yet require the favicon version, so a favicon change without one is still stored unpinned. Once a PUBLIC File is set in one of these fields, /api/website-media/{fileSimplyId} serves it for this website automatically — no separate grant or page reference is needed, and none is written. This PUT route writes these fields directly with no review step; the hosted MCP draft_set_website_brand_assets proposal tool is the reviewed path, requires an exact version for all four File-backed fields including the favicon (send faviconFileVersionNumber here too when a REST write should match it), and shows the approver a plain-language "File X is PUBLIC; approving makes it fetchable at <url> as this website's <role> while it stays configured here" statement per file. Clearing or replacing a field (through either path) stops serving the old file on this website, unless a published page design still references it.

Native Visitor Tracking Integrations (Slice A)

PUT /v1/websites/{websiteSimplyId} accepts trackingIntegrationsJson under manageSiteSettings, the same Website capability as the consent-banner fields. Send a version 1 document or null to clear the draft. The API validates and normalizes it:

{
  "trackingIntegrationsJson": {
    "version": 1,
    "posthog": { "enabled": true, "projectApiKey": "phc_TestProjectKey00000000000000", "region": "US" },
    "metaPixel": { "enabled": true, "pixelId": "123456789012345" },
    "signupUrlPrefixes": ["https://app.example.org/signup"]
  }
}

Use your own PostHog project's public phc_ write-only key, never a personal API key. Region is US or EU. A Meta Pixel ID has 10–20 digits. Each provider may be null; a disabled provider retains its ID. Up to five signup URL prefixes are allowed: absolute HTTPS URLs without credentials or custom ports. The parser trims values, removes fragments, and normalizes URL prefixes. Matching signup-link clicks send signup_started; Meta receives the custom event SignupStarted.

Simply360's own PostHog keys from every environment are refused, including keys in disabled integrations: HTTP 400 with SIMPLY_OWNED_POSTHOG_PROJECT_KEY. If the configured refusal list cannot be read, PostHog saves and publication fail closed with HTTP 503 and POSTHOG_REFUSAL_LIST_UNAVAILABLE. Meta-only documents and clearing visitor tracking do not read that list. Publish rechecks keys even when the draft has not changed.

Saving changes only the draft. A whole-site publish copies it to publishedTrackingIntegrationsJson and sets trackingIntegrationsPublishedAt, using the existing site artifact refresh. Publishing a page or only popups and banners does not publish visitor tracking. Unpublishing clears the live document and its timestamp while retaining the draft. Website GET/list responses, SDK types, and MCP get_website/list_websites expose both documents, the timestamp, and trackingIntegrationsHasUnpublishedChanges. These provider identifiers are public and are not redacted. Visitor tracking settings are never copied by templates, Blueprints, duplication, or Environment Promotion.

In Studio, open Site Settings → Visitor Tracking. Meta Pixel never loads while the cookie consent banner is off, even if a visitor previously consented. Studio warns and links to Privacy, but allows saving and never turns the banner on automatically. With the banner on, consent rules still apply. Keep Automatic Advanced Matching off in Meta Events Manager; no form values, names, or emails should be sent. On Simply360 web addresses (any host in a brand's teams.<brand> or sites.<brand> zone, in every environment), the pixel runs with Meta's first-party cookies off (fbq('set', 'firstPartyCookies', false, pixelId)): every Team's site there shares the brand domain, so _fbp/_fbc would be readable by other Teams' sites. Meta neither sets nor reads those cookies there; events still send, with weaker ad matching. Custom domains and Simply's brand sites keep the cookies. Results mode counts only enabled integrations in the published document. The legacy googleAnalyticsMeasurementId field is still stored but does not render visitor tracking.

Slice A covers published Website content pages only. Wizards on /w/* pages and payment-isolated responses are not tracked; previews, draft-share sessions, and inert renders are excluded too. Teams linking ads directly to hosted Wizard pages should account for that boundary. MCP and TeamAgent can read these settings and publish an existing Website draft, but cannot draft or change visitor tracking settings in slice A; agent drafting is planned for slice B. There is no OAuth grant or server-side conversion delivery in this slice.

No new billable action, meter, entitlement, or plan gate is added. Provider costs belong to the Team's own analytics or advertising account. This uses existing Website API, database, and publication capacity and is intentionally unallocated/excluded engineering work; server-side delivery, recurring sync, or a hosted proxy would need a new cost review.

GET /v1/websites/{websiteSimplyId}/link-targets returns destinations visible to the current actor for a source context. Supply sourceContext (body, header, footer, page-header, page-footer, popup, or navigation) and the applicable pageSimplyId/popupId. The SDK method is websites.getLinkTargets; MCP and Ask Simply use list_website_link_targets, where the popup handle input is named popupHandle. The response contains page and anchor identities, eligible Files/popups/Wizards, and incoming links from sources the actor can read. Dynamic record options use recordPageSimplyId, recordSearch, recordPage, and recordPageSize, with recordsPagination in the response.

Supply up to 100 fileSimplyIds to inspect candidate Files. The catalog checks current download and generated-output authority for both candidates and saved references. A File's authorable flag controls draft selection; available describes publication eligibility in the selected snapshot. Visitor access and grants are still checked at delivery; listing a File does not grant access to it.

Use existing design patch operations to set data-s360-links to a JSON-serialized slot map. For example, a durable Page link is {"href":{"version":1,"destination":{"kind":"page","pageSimplyId":"PAGE-1234-ABCD"}}}. An anchor destination uses kind: "anchor", area: "body", and the target's anchorKey; omit pageSimplyId for the current composed page. Store an anchor on its existing component as data-s360-anchor with {version:1,key,label,fragment}, where key equals that component's data-s360-id. Navigation link items and featured cards accept the same typed value in link.

Other destination kinds are url, file (open/download), email, phone, page-edge, popup, dynamic-page, and wizard. Their exact closed schemas live in the shared contracts. The page-design PATCH route rejects unsafe typed URLs and references to another Website or Team before saving, including when editing a recovery page. Current paths and dynamic slugs resolve from the selected snapshot; unavailable targets remain repairable in drafts and block publication. Renaming an anchor label does not change its fragment. Existing literal URLs are not automatically converted. All mutation, proposal, data-access, and publishing checks still apply.

Website Pages

Pages are managed through 16 standard operations on /v1/website-pages/{pageSimplyId} plus list/create/reorder under the parent website.

Page creation and metadata updates accept title as nonblank text or a language-to-text map. Plain text is stored under the Website's configured default language; explicit translations retain their language keys. Page metaTitle and metaDescription text uses that same language, and a blank text value clears the optional metadata. These writes retain the normal permissions and recovery checkpoints and do not publish or activate a subscription.

MethodPathDescription
GET/v1/websites/{websiteSimplyId}/pagesList the website's pages.
POST/v1/websites/{websiteSimplyId}/pagesCreate a page. Returns 201.
PUT/v1/websites/{websiteSimplyId}/pages/reorderReorder the page tree.
GET/v1/website-pages/{pageSimplyId}Get a page (metadata, path, publish state).
PUT/v1/website-pages/{pageSimplyId}Update page metadata/settings.
DELETE/v1/website-pages/{pageSimplyId}Delete a page.
GET/v1/website-pages/{pageSimplyId}/designRead the page's design document. Returns both the draft and published design when include is omitted (unchanged); pass include=draft or include=published to narrow the response. An unrecognized include value is rejected with 400 VALIDATION_ERROR rather than silently falling back to the default. designHash always reflects the current draft.
PATCH/v1/website-pages/{pageSimplyId}/designApply validated design patch operations.
GET/v1/website-pages/{pageSimplyId}/blocksList the page's blocks (bounded outline of the design).
GET/v1/website-pages/{pageSimplyId}/activityList page activity (edits, publishes, review events).
POST/v1/website-pages/{pageSimplyId}/publishPublish the page's draft design.
POST/v1/website-pages/{pageSimplyId}/submit-for-reviewSubmit the draft for review.
POST/v1/website-pages/{pageSimplyId}/request-changesRequest changes on a page under review.
GET/v1/website-pages/{pageSimplyId}/versionsList page versions.
POST/v1/website-pages/{pageSimplyId}/versionsCreate a manual version checkpoint.
POST/v1/website-pages/{pageSimplyId}/template/detachDetach the page from template sync.
POST/v1/website-pages/{pageSimplyId}/synced-layouts/{savedLayoutSimplyId}/detachDetach a synced saved-layout reference on the draft.

Page paths share each Team domain with platform features, so a page cannot be created, renamed, or moved (including a child moved with its parent) onto a reserved path. Reserved paths include /w, /v, /c, /t, /action-tag, /m, /sign, /time-clock, /p, /api, /.s360, /_analytics, /_consent, /_docs, and a few other system paths, each together with everything beneath it. Every other one-letter first path segment without a named owner, /a through /z, is reserved too, held for future Simply360 experiences, and the same create, rename, move, and redirect-source rule applies to it. Such a request answers 400 with "code": "WEBSITE_PAGE_PATH_RESERVED" and a message naming the reserved path. The same rule applies to the page tools in MCP and Ask Simply, and to Website redirect sources (except the /p page alias).

Reading a site's content is a two-step flow — list pages, then read each page's design or block outline:

curl -s "https://api.simply360.app/v1/websites/WEBS-1234-ABCD/pages" \
  -H "Authorization: Bearer $S360_ACCESS_TOKEN" \
  -H "X-Team-Id: TEAM-1234-ABCD"

curl -s "https://api.simply360.app/v1/website-pages/PAGE-5678-EFGH/design" \
  -H "Authorization: Bearer $S360_ACCESS_TOKEN" \
  -H "X-Team-Id: TEAM-1234-ABCD"

Design edits accept exactly one operation with an optional human-readable summary. Use replaceDesignJson for a complete draft replacement, or replaceComponentContentText for one exact text change. Both use the same permission classifier as Website Studio: plain copy, safe link destinations, and anchor metadata on existing page-body nodes require canEditContent or canEditDesign; layout, styling, component structure, resource URLs, and other changes require canEditDesign. Preserve the stable node IDs from the design read when sending a full replacement. The server compares the canonicalized candidate with the locked current page and reads the actor’s current permissions in the write transaction, including bound template sources and private recovery drafts. Template and element locks, data entitlements, typed-link custody, and retained-media checks still apply.

Designs are sanitized component trees that cannot run authored script; only a fixed set of platform blocks (nav-menu, Data View/Wizard embeds, and a few others with their own built-in runtime) are interactive without it. When an MCP or Ask Simply client drafts a full designJson replacement through draft_patch_website_page_design or draft_create_website_page, the draft proposal is additionally checked for interactive-looking markup with no real behavior behind it (a button with nothing to submit, an ARIA role like tab with no runtime, a link with no destination, a broken #fragment link, filter chips next to a list, an empty image slot) and any findings are surfaced as advisory warnings on the proposal — they never block the draft. This check runs only on the MCP/Ask Simply proposal-drafting path described here, not on direct Website Studio edits, which show inert controls on the visual canvas directly.

Exact Text Edits

To change wording inside a page component, first read the design with a literal contentQuery of 1–500 characters. The response includes contentSearch.matches: component paths, exact-content SHA-256 hashes, occurrence counts, and bounded excerpts. Check truncated and select the intended component; a match in a different component is not permission to edit it.

const result = await client.websitePages.getDesign(pageSimplyId, {
  contentQuery: 'Example, Inc.',
});
const match = result.data.contentSearch?.matches.find(
  (candidate) => candidate.componentPath === selectedComponentPath,
);
if (!match) throw new Error('Read and select the intended text component first.');

await client.websitePages.patchDesign(pageSimplyId, {
  operations: [{
    op: 'replaceComponentContentText',
    componentPath: match.componentPath,
    expectedContentSha256: match.contentSha256,
    oldText: 'Example, Inc.',
    newText: 'Example, LLC',
  }],
  summary: 'Correct the company name',
});

oldText must occur exactly once in the selected component's content. Both text values are limited to 8,000 characters; newText may be empty to remove the old text. Use the returned path unchanged. The server checks the content hash while locking the current page, creates the normal backup, and preserves unrelated page content. A stale hash or ambiguous match returns 409; read the current content before preparing another edit.

For hosted MCP or Ask Simply, read with get_website_page_design, then use draft_patch_website_page_design with pageSimplyId, summary, and arguments: { operations: [...] } (1-50 operations). Drafting requires canEditContent or canEditDesign. Execution uses the same locked-page classifier as the REST design patch: copy, safe links, and anchor metadata on existing nodes allow either grant; other changes require canEditDesign. The draft follows the normal proposal review and approval flow. Existing full-design proposals use arguments: { designJson }; arguments: {} is rejected with an error naming the missing field. Either form accepts an optional arguments.expectedDesignHash (the designHash from get_website_page_design) as an optimistic-lock precondition: if the page's design changed since that read, both the draft and the later approve_proposal fail with WEBSITE_DESIGN_CHANGED instead of silently overwriting the concurrent edit. A full-design replacement identical to the current draft design is rejected as a no-op. Applying either edit changes the draft; publishing remains a separate operation.

Every component in get_website_page_design's response carries a stable nodeId in attributes['data-s360-id']. Hosted MCP and Ask Simply can pass mode: 'outline' for a bounded, paginated projection of nodeId, component path, tag, rendered class tokens, and the first 80 content characters. get_website_page_text returns the same deterministic nodeId with every targetable text run, including for legacy pages whose ids are only backfilled on the returned copy. The full, outline, and text reads use the same authorization and canonical design source, so their handles match. Outline and text are agent projections over the existing design data; the REST/SDK full-design endpoint remains the equivalent external read and keeps its historical include: 'both' default. Instead of one exact text patch, MCP's operations[] accepts up to 50 node-targeted ops — setContent, setStyle, setAttributes, addClasses, removeClasses, insertAfter, insertBefore, appendChild, remove, move, and page-wide replaceText — each targeting a node by {nodeId}, {componentPath}, or {match: {text, tagName, classes, attribute}}:

await mcp.callTool('draft_patch_website_page_design', {
  pageSimplyId,
  summary: 'Rename the hero heading',
  arguments: {
    operations: [{ op: 'setContent', target: { nodeId: 'a2b3c4d5' }, value: 'Tech Check' }],
  },
});

Changing one sentence is now a call well under 1 KB instead of resending the whole page design. Node ids are stable across the first edit that assigns one: a never-written page's ids are computed deterministically from each node's position/tag/content and reused at approval, so a node an agent just read keeps the id it was targeted by. Website Studio copy/paste can clone a data-s360-id onto a duplicate node; the next read/write repairs it (first document-order occurrence keeps the id, later ones get a fresh one) and an unrepaired duplicate fails closed with WEBSITE_DESIGN_NODE_AMBIGUOUS rather than guessing. replaceText only rewrites literal text between tags — never inside a tag, never href/src/class/id/data-* — using a real linear-time HTML tokenizer (quoted attribute values of either quote style, comments, doctype/PI, CDATA, and raw-text element bodies like <script> are never text); a node whose markup it cannot parse confidently is left completely untouched and reported, not guessed at, and case-insensitive matching runs against the original bytes so it can never corrupt an offset the way transforming a copy first can.

A batch is all-or-nothing: every op mutates one clone, and that clone is only kept if every op in the batch succeeds, so a failing op at any index leaves the design exactly as it was. Each op's target (and a move's parent/after/before destination) resolves against the design AS IT STANDS after every earlier op in the SAME batch — not against the design you originally read — so a componentPath computed up front can point at the wrong node once an earlier op has inserted, removed, or moved a sibling; prefer nodeId for anything after the first op in a batch. move also rejects a destination that is the moved node itself or lies anywhere inside that node's own subtree, whether given as parent, after, or before, with WEBSITE_DESIGN_MOVE_INTO_SELF — the comparison is by node identity in the working tree, so a {match} or {nodeId} destination that resolves to a descendant is caught exactly like a {componentPath} one. Moving a node into its own descendant has no consistent result: a naive implementation that allowed it detached the subtree and spliced it into an array living inside that same subtree, so the splice succeeded but the subtree became unreachable from the page — silently deleting it and everything inside it even though the proposal review said only "move". After every op the server also verifies the design's component count and every node's data-s360-id changed exactly as that op's kind allows (unaffected by an in-place edit or move, minus a removed subtree, or plus an inserted one) and that no component is reachable from more than one place in the tree; a violation aborts the whole request with WEBSITE_DESIGN_PATCH_INVARIANT_VIOLATED instead of writing a corrupted design.

The proposal review is a generic structural diff of the whole design before vs. after the batch, keyed by data-s360-id and computed independently of which ops ran — not the per-op list each op's own code chose to report, so it cannot omit an effect (a setAttributes rewriting href to a javascript: URL, a full-viewport setStyle overlay, a remove of a 500-node subtree). A wholesale replaceDesignJson replacement backfills ids on the incoming design first (the same duplicate-repair rules as everywhere else), specifically so it diffs as removed + ADDED, never silently as pure removal. Every node whose serialized form changed appears: added, removed, AND moved subtrees alike carry the same summary (tag, node count, a text excerpt, and every sensitive attribute anywhere inside them), plus field-level changes for a node whose own fields changed (tagName, content excerpted around the first differing region, translations, booleans and unknown own fields, each changed attribute/style property before → after, classes added/removed). Unknown own fields are sensitive by default. A one-node setContent still reviews as exactly one change entry. The diff also covers what the node-id walk cannot reach: the top-level styles array is diffed as its own keyed set (a CSS rule's identity is its selector set plus state/media, never its array position), reporting added/removed/changed rules with the same style-value sensitivity check as node styles; relative order is also reported because reordering equal-specificity rules changes the cascade, including when another rule is added or removed in the same edit. Every OTHER top-level design-JSON key (assets, symbols, dataSources, or anything unrecognized) is compared directly and, if it differs, reported as a sensitive-by-default changed entry with a short before/after size note — a replaceDesignJson with byte-identical components but a swapped styles array (or any other swapped top-level field) never diffs as silently empty.

An entry is sensitive (sorted first, surviving the 50-entry bound that keeps a huge edit's proposal a bounded size — exact remaining counts by kind are still reported) by four published, independently tested rules: (1) an attribute NAME is a link/action/resource-bearing attribute — a list wider than just href/src/action, also covering formaction, ping, data, srcdoc, poster, codebase, xlink:href, cite, longdesc, manifest, srcset, usemap, itemid, dynsrc, and lowsrc — an on* handler, or a data-s360-* binding; (2) an attribute VALUE (either side), NORMALIZED (HTML entities decoded, ASCII control/whitespace characters stripped, lowercased, before matching — closing bypasses like java script: or &#106;avascript:), contains javascript:, data:, vbscript:, or a literal <; (3) a style property VALUE (either side), also NORMALIZED, contains url(, expression(, javascript:, data:, vbscript:, behavior:, -moz-binding, or </; (4) classes changed — via the GrapesJS classes array OR the raw attributes.class string, checked uniformly — on a "platform block" node — a Data View, Wizard, story, embed, newsletter, chat assistant, storefront, script widget, or navigation menu type, or any node carrying a data-s360-* attribute (e.g. a lightbox-enabled image) — because that block's own runtime JS keys off specific classes, so a class change there can silently change behavior, not just appearance. The diff's tree walks are iterative and it refuses (a typed WEBSITE_DESIGN_PATCH_TOO_DEEP error, never a raw crash) a design nested deeper than 512 levels — a pathological-input guard, deliberately NOT tied to the authoring sanitizer's 20-level content cap, since Website Studio's general page-save route never runs that sanitizer and a real stored page can already nest past 20. Width is unbounded by a depth cap; an extremely wide single parent (thousands of children) switches move-detection to a documented, still-exact O(n log n) comparison above a sibling-count threshold instead of the default O(n·m) one.

Governed Script Widgets

The shared block catalog exposes scriptWidget.doubleTheDonation for Studio, SDK, MCP, and TeamAgent authoring. Use a s360-script-widget component with these string attributes:

  • data-s360-type: script-widget.
  • data-s360-script-widget-vendor: double-the-donation.
  • data-s360-script-widget-public-key: the vendor public key, 8–128 letters, digits, underscores, or hyphens. Omit it for an inactive draft.
  • data-s360-script-widget-sections: an ordered comma-separated selection of match, payroll-giving, and volunteer, with at least one entry and no duplicates.
  • data-s360-script-widget-height: initial height from 320 to 1600; defaults to 640.
  • data-embed-title and data-embed-button-label: optional accessible title and load-button text.

Page, header, and footer writes reject invalid widget settings, authored runtime activation attributes, executable markup, and nested script widgets. The public renderer stays inactive until a visitor clicks the load button; the isolated vendor frame then resizes within the same bounds. Use the existing design read/write and preview-session methods; no separate widget authoring endpoint or private provider credential is required.

An s360-nav-menu component's mobile toggle button has two independent string attributes on its <nav> element. They are never derived from one another, so authoring one never silently changes what the other renders:

  • aria-label: the <nav> landmark's own accessible name (for example Primary navigation), read by assistive technology and used to tell two named menus on one page apart. It is never shown as visible button text.
  • data-s360-nav-toggle-text: the toggle button's VISIBLE text (for example Menu). Omit it to use the site's short, localized default; setting aria-label does not change this text.
  • data-s360-nav-toggle-label: true (default) or false — whether the visible label span renders next to the icon at all. It is a pure visibility switch and does not choose the label's text.

When the visible label renders, the button's aria-label matches that same resolved text. The accessible name remains available when custom site CSS hides the span at a phone breakpoint. When data-s360-nav-toggle-label="false" hides the visible span, the button's aria-label falls back through data-s360-nav-toggle-text, then the nav's own aria-label, then the localized default — an icon-only accessible name carries no layout-overflow risk, so unlike the visible text it may still use the menu's own configured/authored name.

When a data-s360-nav-mobile="drawer" menu opens, the runtime moves the <nav> to <body> (carrying s360-navmenu-open and s360-navmenu-portaled) so its full-screen overlay is sized against the viewport instead of a header/footer ancestor. If that nav lives inside header.s360-site-header or footer.s360-site-footer, the runtime wraps it — not tags it — in a same-tag, same-classed, box-less (display: contents) element carrying a data-s360-navmenu-portal-scope marker, so custom CSS written against that scope keeps applying correctly to the open drawer. Concretely, while the drawer is open:

  • Works: descendant selectors under the header/footer scope, including through the nav itself (for example .s360-site-header nav a or .s360-site-header .s360-nav-link), and inherited properties (font-family, color, custom properties) set on the scope.
  • Does not work: box styling written on the header/footer scope class itself (height, overflow, position, max-width, padding, border, background, flex, …) — the wrapper generates no box, so none of it reaches the drawer. Style the open drawer directly with a rule on .s360-nav.s360-navmenu-portaled instead.

Interactive Tabs Block

An s360-tabs component (root data-s360-type="tabs", or persisted type: 's360-tabs') renders a WAI-ARIA Tabs pattern (role="tablist"/role="tab"/role="tabpanel") backed by a dependency-free client runtime (S360_TABS_RUNTIME_JS, packages/contracts/src/websites/tabsRuntime.ts), inlined into the page's <head> only when the design contains one — the same pattern as the nav-menu, lightbox, and pricing-calculator runtimes above.

  • Initial state (no JS required): the block's own generated markup already carries the correct pre-JS state — the first (or previously-saved-selected) tab has aria-selected="true"/tabindex="0" and its panel has no hidden attribute; every other tab has aria-selected="false"/tabindex="-1" and its panel carries hidden. A visitor without JavaScript sees the correct tab with no layout shift.
  • Ids are runtime-owned, never authored: the runtime assigns every tab/panel its own id, aria-controls (tab → panel), and aria-labelledby (panel → tab) at attach time, scoped to that block's own root element. A pre-existing id is kept only when it is a plain token and not already claimed elsewhere on the page; otherwise (missing, malformed, or a duplicate from copying a Tabs block in Studio) a fresh s360-tabs-auto-N id is minted from a page-wide, never-reused counter. Internal tab↔panel wiring always pairs by DOM position, never by resolving an authored aria-controls/id value, so a hostile or duplicated authored id can only ever be overwritten, never trusted.
  • Keyboard: ArrowLeft/ArrowRight move and select the adjacent tab (ArrowUp/ArrowDown when the tablist carries aria-orientation="vertical"), with wrap-around; Home/End jump to the first/last tab; horizontal arrows reverse in an RTL document (nearest ancestor dir="rtl"). Activation is automatic (focus moves with selection) unless the tablist or root carries data-s360-tab-activation="manual", in which case arrow keys move focus only and Enter/Space select.
  • Deep link: if location.hash matches a tab or panel id inside a block, that tab is selected on load and on hashchange — selection only, never additional scrolling beyond the browser's own fragment navigation.
  • Nested Tabs: a Tabs block inside another Tabs block's panel is wired up independently; every lookup resolves ownership via the nearest [data-s360-type="tabs"] ancestor, so a parent tablist never captures a nested block's tabs or panels.
  • Legacy saved designs: a page saved before this runtime existed (inline display: none/block toggling instead of hidden, no ids) is normalized automatically at attach time — no re-save, no migration.

Functional CSS ([hidden] handling against a resetting site theme, a focus-visible ring) ships in the always-present base stylesheet scoped to [data-s360-type="tabs"], not from the runtime script, so it protects even a legacy design that predates the runtime.

An s360-carousel component (root data-s360-type="carousel" with class s360-carousel) is one horizontal row whose direct children are the slides. Any block can be a slide: images, cards, sections, buttons, Data View items. Settings, attribute contract, CSS, and labels live in packages/contracts/src/websites/websiteCarousel.ts; the presets are carousel.images, carousel.cards, and carousel.quotes.

  • Settings (data attributes on the root, closed value sets; unknown values fall back to the default): data-carousel-per-view, data-carousel-per-view-tablet (≤1023px), and data-carousel-per-view-phone (≤767px), each one of 1, 1.1, 1.2, 1.25, 1.5, 2, 2.2, 2.5, 3, 3.5, 4, 4.5, 5, 6 (defaults 3 / 2.2 / 1.2; a fraction lets the next slide peek in); data-carousel-gap (0px, 8px, 16px, 24px, 32px, 48px; default 24px); data-carousel-align (start | center); data-carousel-arrows (true | false, default true); data-carousel-arrow-position (sides | below); data-carousel-dots (default false); data-carousel-loop (default false); data-carousel-autoplay (off | 4 | 6 | 8 seconds, default off); data-carousel-label (accessible name, default “Carousel”).
  • Agents and the MCP: insert one with draft_insert_website_block (componentType: 's360-carousel' or a presetKey above) and change settings with draft_update_website_block. To add, remove, or reorder slides, add, remove, or reorder the carousel component’s components in the full designJson — there is no separate slide type. get_website_studio_context returns the manifest and presets.
  • Published markup (no JavaScript required): GrapesPageRenderer wraps the slides in .s360-carousel-viewport > .s360-carousel-track > .s360-carousel-slide. The root is a role="region" with aria-roledescription="carousel" and the label; each slide is a role="group" with aria-roledescription="slide" and an “N of M” label; the track is a focusable native CSS scroll-snap container, so touch, trackpad, shift+wheel, the scrollbar, and Tab through slide content all work without the runtime. Previous/next (s360-carousel-prev/s360-carousel-next, the same class names as the Data View CAROUSEL list controls), the dots, and the autoplay pause button are rendered with hidden.
  • Runtime (progressive enhancement): S360_CAROUSEL_RUNTIME_JS (carouselRuntime.ts) is inlined only on pages whose design contains a carousel. It reveals the controls when the row overflows, pages by the number of fully visible slides, marks the arrows aria-disabled at the ends unless looping (they stay focusable), moves one slide per Left/Right key and to the ends on Home/End when the track has focus (mirrored right-to-left), scrolls a slide fully into view when keyboard focus moves into its content (mandatory snapping would otherwise settle on the previous slide and hide the focused control), builds one dot per reachable position with aria-current, and scrolls with behavior: 'auto' under prefers-reduced-motion: reduce. Autoplay never runs under reduced motion and pauses on hover, on focus inside, while the page is hidden, and after the pause button.
  • Studio: the slides sit directly under the block on the canvas, which the same stylesheet lays out as the row; Preview mode runs the runtime, which builds the published structure and is torn down on exit. data-s360-carousel-rendered and data-s360-carousel-ready are renderer/runtime state, removed from authored designs by the sanitizer.

Page Versions

Every page keeps a version history. GET /v1/website-page-versions/{versionSimplyId} reads one version, PATCH updates its metadata (for example a label), and POST /v1/website-page-versions/{versionSimplyId}/restore restores it onto the draft. Restore atomically saves a MANUAL_SAVE safety version, replaces only the page draft and derived blocks, and creates a separate RESTORE result. It never publishes. Page History restore is human-only: the version schema requires a nonnull createdByTeamUserLinkId; API-key clients use dedicated private recovery graph edits instead.

Continue reading in API Reference: Websites & Pages: Publishing, Recovery, and Studio Tools.

↑