agent_capability Plugin
Mockups
Ships as the bundled `mockups` plugin, enabled by default. It gives planning-mode chat agents a scratch area for building HTML/CSS/JS sketches (`show_preview`, `write_preview_file`, `edit_preview_file`, `render_preview`, `close_preview`, plus the read-only `inspect_preview_versions`) and makes the results first-class objects an operator can find later.
Mockups
Ships as the bundled mockups plugin, enabled by default. It gives planning-mode chat agents a scratch area for building HTML/CSS/JS sketches (show_preview, write_preview_file, edit_preview_file, render_preview, close_preview, plus the read-only inspect_preview_versions) and makes the results first-class objects an operator can find later.
Slugs
A published mockup gets a stable MOCKUP-<id> slug, the same shape as JOB-<id> and EPIC-<id>. Republishing a panel updates the same mockup rather than creating another, so the slug survives an agent iterating on it. Both the slug and a bare id resolve: /mockups/MOCKUP-12 and /mockups/12 are the same page.
The Mockups page
A Mockups entry in the primary sidebar opens a filter-bar-searchable list (/mockups). Selecting one opens it in a side panel beside the list rather than navigating away, so a filtered list stays put while you look through it.
Filter chips: title, created_at, updated_at. The bar uses the same chip AST and q parameter as every other filtered list, and the applied filter is returned with the results so the bar renders what is actually in effect. The list response sends its filter schema only on page one; the frontend loads and caches the schema separately so later pages keep the same controls without resending it. Exact totals are deliberately omitted in favor of next/previous page availability.
Visibility: a mockup is visible to whoever can see the preview panel behind it, which is the panel's own rule (you can see a panel if you can see its chat) — not a second, looser rule. Closing its transient chat tab does not remove the published mockup: the saved panel remains viewable from the Mockups page. A successful close_preview response includes that retained mockup's mockup_slug, allowing the closed-state tool card to link to it. Panels that were never published have no mockup reference in the response and become unreachable when closed.
Relationship to preview panels
PreviewPanel and PreviewPanelVersion stay core. The panel is a generic multi-format viewer — html, markdown, pdf, image — that other features render into, and the mockups plugin is one of its clients rather than its owner.
Two core seams make that work:
preview_panel_viewer— a plugin can teach the panel a content kind core
does not know ({ kind:, extensions: [], content_types: [] }). Core's built-in kinds win, so a plugin extends the set rather than reinterpreting a file core already renders; an unrecognised kind falls back to source text.
preview_panel_retention— a plugin can identify durable records that
keep a closed panel servable after its chat tab is dismissed. The mockups plugin retains panels referenced by published mockups.
/api/v1/app/preview_panels/:id(show,update,files,export,token) —
panel content addressed independently of the chat it was opened in, so a page outside chat can render one without inventing its own file serving. Scoped by PreviewPanel.accessible_to.
The mockup detail response contains only the current panel version by default. Clients that render version history request it explicitly with ?versions=all.
Disabling
Turning the plugin off from Admin -> Plugins stops new mockups being recorded and removes the page, nav entry and chat tools. Mockups already published are kept, and the panels behind them are core and unaffected. Deleting a chat or a user removes their mockup index entries, since the panel content goes with them.