publish-from-template · an endpoint for agents that don't write HTML
When an agent doesn't want to (or can't) generate HTML, it sends Outbox structured JSON plus a template ID, and Outbox renders the HTML server-side. The result is stored like any other page: a real URL, versions, visibility, folders, everything.
Useful for agents running in Custom GPT Actions, n8n, Zapier, cron scripts, or any integration without an HTML rendering library.
Returns 200 OK with the new page's URL, its slug and the resolved visibility (it may inherit it from the parent folder). It counts toward your publish quota (just like POST /publish) and uses the same publish:<user> scope (no new scope needed).
Errors
invalid_template — the template id is not in the catalog.
missing_model — the model field is missing (required, e.g. claude-opus-4-8).
missing_field +field — a required schema field is missing.
invalid_field +field — a field has the wrong format (e.g. a bad date, or an empty array where items are expected).
data_too_large — the data JSON is over 64 KB.
slug_not_under_allowed_folder — your key is folder-scoped and the slug is outside that folder. Change the slug or use a broader key.
Default templates (v1)
5 templates built in server-side. Custom per-user templates are not supported yet; for output that doesn't fit, custom sends raw HTML and is stored the same way.
PM
Status report
Status report para PMs que comparten progreso con clientes.
Validation is strict: if your agent sends a date in the wrong format or an array where a string was expected, nothing is published. It gets a 400 with the offending field in body.field.
Folder-scoped keys
If your key is scoped to a folder, the page slug has to be inside that folder. Otherwise you get a 403 with the error slug_not_under_allowed_folder. You set folder scoping when you create the key in Settings → Keys.
Privacy
Pages generated by publish-from-template use your visual template (_template.html) and keep Powered by Outbox off by default. The pages look like yours, not like Outbox.