thincms_create_page
Create a static page with HTML content. Use 'wrapped' render mode for site template pages or 'standalone' for full custom HTML. For large content, pass a file path instead.
Instructions
Create a new static page. Content should be raw HTML. Use renderMode 'wrapped' for pages that use the site template, or 'standalone' for full custom HTML. For large content (>10KB), use contentFile instead of content to pass a local file path.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slug | No | URL slug (auto-generated from title if omitted) | |
| title | Yes | Page title (required) | |
| jsonLd | No | Custom JSON-LD (Schema.org) injected verbatim into the page <head>. Pass valid JSON as a string. Use for Service, Event, BreadcrumbList, HowTo, Article, etc. Set to empty string to clear. | |
| siteId | No | Override the active site for this single call. Pass to target a specific tenant without mutating shared active-site state — the right pattern when running concurrent agent sessions managing different tenants. Must match a siteId from your THINCMS_SITES config (use thincms_list_sites to inspect). When omitted, the call uses the active site set by thincms_switch_site. | |
| status | No | Page status (default: draft) | |
| content | No | HTML content | |
| noIndex | No | Set true to add noindex meta tag | |
| metaTitle | No | SEO meta title | |
| ogImageUrl | No | Open Graph image URL | |
| renderMode | No | Render mode (default: wrapped) | |
| contentFile | No | Local file path containing HTML content — use this instead of content for large pages (>10KB). The file is read and sent as content. | |
| canonicalUrl | No | Canonical URL | |
| metaDescription | No | SEO meta description | |
| confirmProductionWrite | No | Acknowledge that this call may write to a configured production site (THINCMS_PRODUCTION_SITE_IDS env var). Required for any POST/PUT/PATCH/DELETE against a production-listed site; ignored otherwise. The error message lists which site triggered the requirement and recommends thincms_snapshot before any production write. |