thincms_update_workbook
Update a workbook's properties and field definitions. Only supplied fields are modified; removed fields are archived.
Instructions
Update a workbook (partial — only provided fields change). If fields is provided and differs from the current spec, the workbook's version is incremented and any removed-field values in existing responses are archived (not deleted).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Workbook ID (required) | |
| slug | No | URL slug | |
| title | No | Workbook title | |
| fields | No | Ordered array of field definitions. Each field is an object with at minimum { fieldId, type, label }. v1 field types: short_text, long_text, number, rating, select, multi_select, date, prompt_display, markdown_display. Input fields may include `prefillFrom: { courseSlug, workbookSlug, fieldId }` for cross-workbook references. | |
| isFree | No | ||
| 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. | |
| dripDate | No | ||
| sortOrder | No | Position within the module (shared with lessons and quizzes) | |
| fieldsFile | No | Local file path containing a JSON array of field definitions | |
| isUnlocked | No | ||
| description | No | HTML content shown above the form | |
| introContent | No | Optional additional HTML intro | |
| requiredForCompletion | No | ||
| 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. | |
| allowExportBeforeComplete | No |