<!-- kernel -->
> Creatomate AI reference — topic page "Seeing the user's template"; the index of all pages is https://creatomate.com/llms.txt
<!-- /kernel -->

## Seeing the user's template

If the question answers itself from knowledge, answer — no tools, no pastes. Never claim a capability you don't have.

**Fetched copies expire — the user edits in parallel.** Whatever you fetched or were pasted is a snapshot, not a live view: between your turns the user may move, retime, rename, or delete elements in the editor. When the user reports a new symptom ("now it doesn't work anymore"), says they changed something, or describes behavior that doesn't match the copy you hold, assume the template has changed and re-sync BEFORE diagnosing — MCP: `get_template` again; browser: re-read `getTimeline`; paste flow: ask for a fresh copy of the source JSON. When their description and your copy disagree, trust their description — your copy is the stale one. Re-sync before any write too: a stale write either misses silently (modifications keyed to renamed elements are ignored) or overwrites the user's newer edits (full-source updates).

1. **Paste (the common case):** the user opens the editor's source editor (the `{ }` icon or F12), selects all, and pastes the template JSON to you. That is the RAW stored source, the same thing `get_template` returns: no resolved timeline comes with it, so resolve computed start/end times mentally AND say you did when timing is the question. Deliver fixes as one of: (a) corrected full JSON the user pastes back into the same source editor — one paste, one undo step; (b) exact editor steps; (c) a corrected API call.
2. **Browser control** (the user shares their browser with the editor open): see Operating the template editor (https://creatomate.com/llms/editor-operation.md).
3. **MCP** (headless account access, when configured): tools `list_templates`, `get_template`, `create_template`, `update_template`, `delete_template`, `create_render`, `get_render`. Limits to respect: `get_template` returns the RAW stored source — no resolved timeline exists outside a running editor, so resolve durations mentally AND say you did; with browser control, `getTimeline` is the only channel that hands you the resolved times. `update_template` saves go live to automations immediately — recommend draft mode first on production templates. Writing while the user's editor is open is safe — the editor detects outside changes (a clean editor reloads them; unsaved work gets a keep-mine/load-latest prompt) — but your own risk remains the stale copy: re-fetch with `get_template` before writing, or your write lands on top of edits you never saw. Headless and bulk jobs belong here, never in the browser.
   **Setting it up** (only if the user wants it — see channel etiquette in "Choosing the right path" (https://creatomate.com/llms/choosing-the-path.md)): the endpoint is `https://api.creatomate.com/mcp`. **OAuth is the preferred way to connect**: the user adds the URL, signs in on a Creatomate page, and picks the project to grant — no API key changes hands. That is the whole setup in **claude.ai** (paid plans: Settings → Connectors → Add custom connector) and **ChatGPT** (enable developer mode under Settings → Apps & Connectors first), and **Claude Code, Cursor, and other dev tools** run the same sign-in when the server is added without credentials — Claude Code: `claude mcp add --transport http creatomate https://api.creatomate.com/mcp`. The **API-key alternative** — the same URL with a header `Authorization: Bearer <project API key>` (key: Project Settings → API Integration) — is for headless setups (servers, CI, clients without OAuth support) where a browser sign-in isn't possible. Access is scoped to the granted project (OAuth) or the key's project.
4. **Building something new** mid-conversation → start a fresh template instead of performing surgery on an unrelated one. With MCP: `create_template`. Without: have the user start from the closest template in the gallery (https://creatomate.com/templates), then deliver your reshape as corrected full JSON pasted into the editor's source editor (the `{ }` icon or F12) — one paste, one undo step.
