MCP tools

Drive Agentic Slides from Claude (or any MCP client). The tools mirror the REST surface, returning canonical deck HTML you thread between calls.

Connecting

Agentic Slides exposes a stateless, Streamable-HTTP MCP endpoint:

https://slides.product-masterclass.com/mcp

Register it as a remote MCP server with your API key in the x-api-key header. Example client config:

{
  "mcpServers": {
    "agentic-slides": {
      "url": "https://slides.product-masterclass.com/mcp",
      "headers": { "x-api-key": "YOUR_API_KEY" }
    }
  }
}

For local development, run the server over stdio (no key required):

pnpm install
pnpm mcp:stdio
Recommended flow: call get_spec first, build or generate the deck, render_slide to verify the layout, then export_deck. Most tools take a deckHtml string and return the updated deck HTML.

Decks & canvas

create_deck

Start a new, brand-themed deck with one blank slide. Returns the deck's canonical HTML.

ParameterTypeNotes
titlestringoptDeck title.
formatenumoptwidescreen · square · portrait · story.
widthintegeroptCustom width (with height; not together with format).
heightintegeroptCustom height.
tenantIdstringoptDefaults to your key's tenant.

set_canvas

Retarget an existing deck to a different canvas size without touching slides, theme, or content. Element coordinates are not auto-re-laid-out.

ParameterTypeNotes
deckHtmlstringreqThe deck to retarget.
formatenumoptPreset, or use width+height.
width / heightintegeroptCustom canvas size.

list_decks

List the decks saved for a tenant (id + title). Returns a JSON array of summaries.

ParameterTypeNotes
tenantIdstringoptDefaults to your key's tenant.

get_deck

Load a saved deck by id and return its canonical HTML, ready to edit or render. Errors not_found if missing.

ParameterTypeNotes
deckIdstringreq
tenantIdstringopt

save_deck

Persist a deck (create if new, update if its id exists). Returns the stored deck's HTML.

ParameterTypeNotes
deckHtmlstringreq
tenantIdstringopt

delete_deck

Permanently delete a saved deck by id (hard delete). Returns { removed: true|false }.

ParameterTypeNotes
deckIdstringreq
tenantIdstringopt

Slides

add_slide

Append (or insert at index) a new blank slide, keeping every slide layout-valid. Returns the updated deck HTML.

ParameterTypeNotes
deckHtmlstringreq
indexintegeropt0-based insert position. Omit to append.

remove_slide

Delete the slide with the given id. The deck must keep at least one slide. Returns the updated deck HTML.

ParameterTypeNotes
deckHtmlstringreq
slideIdstringreqStable id from data-slide-id.

reorder_slides

Reorder a deck's slides. Returns the updated deck HTML.

ParameterTypeNotes
deckHtmlstringreq
orderstring[]reqEvery slide id exactly once, in the desired order.

apply_template

Rebuild a slide from a named catalog template (a curated, brand-conformant layout), keeping the slide's id. Returns the new slide as canonical HTML.

ParameterTypeNotes
slideIdstringreq
templateIdstringreqCatalog template id.

AI generation & editing

generate_deck

Generate a brand-conformant, layout-checked deck from a natural-language brief. The result is guaranteed to fit the canvas and brand. Optionally append into an existing deck. Returns the deck HTML.

ParameterTypeNotes
promptstringreqe.g. "a 6-slide deck on customer onboarding".
deckHtmlstringoptExisting deck to append generated slides into.

edit_slide

Change one existing slide from a natural-language instruction, keeping the rest intact and the result layout-valid. Returns the updated deck HTML and a per-element diff.

ParameterTypeNotes
deckHtmlstringreq
slideIdstringreq
promptstringreqe.g. "make the title bigger", "rewrite the bullets punchier".
elementIdsstring[]optdata-el-id values to scope the edit. Omit for the whole slide.

Render & export

render_slide

Render one slide to a PNG so the agent can see the result and verify its layout. Returns the image plus the slide's canvas size.

ParameterTypeNotes
deckHtmlstringreq
slideIdstringreq

export_deck

Export a whole deck to a deliverable file. Returns the file as base64 plus its byte length.

ParameterTypeNotes
deckHtmlstringreq
formatenumreqpdf (one page/slide) · png (ZIP of PNGs) · reveal (reveal.js HTML).

Brand

apply_brand

Re-theme a whole deck to a tenant's brand (colors, fonts). Omit profileId for the active profile. Returns the re-themed deck HTML.

ParameterTypeNotes
deckHtmlstringreq
tenantIdstringopt
profileIdstringoptOmit for the active profile.

list_brands

List a tenant's brand profiles (id, name, which is active). Returns { profiles, activeId }.

ParameterTypeNotes
tenantIdstringopt

import_brand

Create a new brand profile from a template supplied as text (colors + fonts extracted). Becomes the active brand. Returns { profileId, profiles, activeId }.

ParameterTypeNotes
namestringreq
contentstringreqTemplate as text (Agentic Slides / HTML).
mimeTypestringoptDefault text/html.
idstringoptExplicit profile id.
tenantIdstringopt

set_active_brand

Switch the tenant's active brand profile (the one apply_brand uses by default). Errors not_found for an unknown id. Returns { profiles, activeId }.

ParameterTypeNotes
profileIdstringreq
tenantIdstringopt

delete_brand

Delete a brand profile. Errors not_found for an unknown id, and last_profile when it is the only one left. Returns { profiles, activeId }.

ParameterTypeNotes
profileIdstringreq
tenantIdstringopt

Spec & validation

get_spec

Fetch the Agentic Slides specification: the canvas, the data-el-id schema, deterministic-HTML rules. Read this first when building or validating slide HTML yourself. No parameters. Returns the spec markdown, its version, and machine-readable constraints.

validate_slide

Check whether HTML is a valid Agentic Slides deck (parses to the canonical model and round-trips). Returns the canonical HTML on success, or a precise validation error.

ParameterTypeNotes
htmlstringreqCandidate HTML.