Cloee Docs
Paymenter ExtensionsPageDesigner

MCP tools reference

Complete grouped reference to the PageDesigner MCP server tools.

Complete grouped reference to the tools exposed by the PageDesigner MCP server and the safe workflow for using them.

This page lists the current PageDesigner MCP tools. The server returns the authoritative JSON Schema through tools/list; client UIs should use that schema for exact arguments.

flowchart TD
    A[Read agent guide and design docs] --> B[List pages and storefront summary]
    B --> C[Inspect target page context]
    C --> D{Need product, plan, or link facts?}
    D -- Yes --> E[Read catalog data and valid link targets]
    D -- No --> F[Search library or target components]
    E --> F
    F --> G[Make surgical tool changes]
    G --> H[Re-read context or component]
    H --> I[Update SEO and settings]
    I --> J{Explicit publication intent?}
    J -- No --> K[Leave draft and report]
    J -- Yes --> L[Publish and verify]

Orientation and storefront facts

ToolPurpose
list_pagesList PageDesigner pages with ID, title, slug, published state, and update time
get_pageRead page metadata, SEO, custom-code flags, and content lengths
get_storefront_summaryGet counts for pages, categories, products, and plans
list_categoriesList product categories, hierarchy, and product counts
get_categoryRead one category and optionally its products
list_productsList visible products, optionally with plans and prices
get_productRead one product, category, plans, and prices
list_plansList plans filtered by product, category, type, or currency
get_planRead one plan, billing interval, product, and prices
list_link_targetsReturn valid site, page, category, product, and checkout URLs

Rule

Before writing product, plan, billing, or pricing copy, read the applicable storefront tool. Before setting a PageDesigner or Paymenter CTA, call list_link_targets and use a returned href.

Page lifecycle

ToolPurposeImportant behavior
create_pageCreate a pageDraft by default; slug can be generated
update_page_settingsUpdate title, slug, SEO, publish, and navigation fieldsDoes not touch canvas HTML
duplicate_pageCopy a pageNew copy is unpublished
publish_pageSet the page activeRequires explicit intent
unpublish_pageHide the page from public visitorsSafer than deletion
delete_pagePermanently deleteRequires confirm: true

Page and component inspection

ToolPurpose
get_page_contextReturn a compact component tree; prefer depth 2–3
ensure_component_idsAssign stable IDs to nodes missing them
get_componentRead one component's classes, attributes, children, and optional HTML
search_componentsSearch by ID, name, tag, class, text, Hosted UID, or i18n key
get_page_htmlRead rendered page HTML with a character limit
get_page_cssRead page CSS with a character limit

Call get_page_context before editing. Use the exact component IDs returned by inspection tools.

Library and reusable components

ToolPurposeImportant behavior
list_librarySearch Hosted cache and custom blocksUse component_uid when available
add_componentAdd a library model to a pageCan target parent and index
create_componentSave a new local reusable blockCan optionally place it
fork_componentCopy a Hosted/custom source into a new local blockOriginal never changes; source must be cached

Prefer a suitable library model over hand-building a common hero, pricing, feature, or FAQ section.

Canvas structure and content

ToolPurposeRisk
insert_htmlInsert safe HTML under a parent or rootStructural
replace_component_htmlReplace one component or root childrenDestructive
remove_componentRemove one componentDestructive
move_componentReorder or reparentStructural
set_page_htmlReplace the entire canvas and optionally CSSDestructive full rebuild
update_textChange visible text onlySurgical
update_classesAdd/remove/set CSS classesSurgical unless using full set
update_attributesSet safe attributesSurgical
set_component_linkSet a safe CTA/link URL plus optional label/title/targetCall list_link_targets first

HTML safety

Canvas HTML must not contain scripts, event handlers, or javascript: URLs. Use theme utilities rather than inline theme colors.

Translations

ToolPurposeImportant behavior
list_localesList available, current, and fallback locales
list_translationsList translation keys and per-locale values
get_translationRead one key and its bound component IDs
set_translationCreate or update locale values
bind_translationAttach a component to a key and optionally seed values
unbind_translationRemove the component binding
remove_translationRemove a locale value or whole keyWhole-key deletion requires confirmation

Keys must match the safe PageDesigner key pattern and should remain stable. Do not overwrite unrelated locales.

Page-level custom code

ToolPurposeImportant behavior
get_custom_codeRead all page custom-code slotsCall before editing
set_custom_codeSet head, before/after HTML, CSS, or JavaScript slotsCan replace provided slots
add_custom_scriptAppend or replace a script in head or after-content locationAppend by default; code runs publicly

Never put a secret in public page code. Use location: head only when necessary. Use replace only with explicit intent.

Design documentation

ToolPurpose
list_docsList PageDesigner design documents
read_docsRead a document such as best practices, theme colors, classes/layout, or components
get_agent_guideRead the complete connected-agent workflow

Read the design docs before creating or substantially restyling content.

Tool annotations and destructive work

The MCP schemas annotate read-only and destructive operations. Clients should expose those cues.

Treat these as high risk:

  • delete_page
  • set_page_html
  • replace_component_html
  • remove_component
  • whole-key remove_translation
  • Custom Code replacement
  • publish_page

Before a high-risk operation:

  1. Inspect the target.
  2. Confirm the page ID and component ID.
  3. Prefer an unpublished duplicate.
  4. Clarify the intended scope.
  5. Verify after the call.

Prompts are not tools

The server provides build_page, edit_section, and design_review prompts. A prompt prepares an instruction for the client. It does not mutate anything until the client calls tools.

Resources are not page publication

Reading pagedesigner://pages/{page_id}/context or /html is inspection. It does not open, save, or publish the page in a browser.

Example: safe pricing-page task

  1. get_storefront_summary
  2. list_products with include_plans: true
  3. list_link_targets for product/checkout targets
  4. create_page as a draft
  5. list_docs and read_docs
  6. list_library for hero, pricing, and FAQ
  7. add_component
  8. get_page_context
  9. update_text, update_classes, and set_component_link
  10. update_page_settings for SEO
  11. Re-read the page and leave it unpublished for human Preview

Example: safe translation update

  1. list_locales
  2. list_translations
  3. get_translation for each target key
  4. set_translation only for intended locales
  5. get_translation again to verify
  6. Leave unrelated locale values unchanged

Reporting

A connected assistant should report:

  • page ID and title;
  • component IDs or labels changed;
  • settings or locales changed;
  • whether the page remains draft or is published;
  • verification performed;
  • any user decision still required.

It must never claim success when a tool returned an error.


On this page