Finalize workspace setup
finalize_workspace_setupCommit onboarding answers into the workspace config. Any field omitted is left untouched. active_motions records the confirmed motion choice and auto-applies each chosen motion's template; feature_templates applies additional standalone add-on templates (opted into during the interview) AFTER the motion templates — an unknown feature key is skipped and named in the result, never a failure; answers records checklist items without a dedicated field. Returns the updated workspace.
When to use: Call at the end of the interview once the user has confirmed the choices. Records the confirmed motion(s), applies their starter templates, and commits the answers — anything omitted keeps its default.
Example: Looks good — save those settings.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | The workspace's display name — answers the checklist's name item; until set it reads "<sign-up email domain> workspace". | |
| answers | No | Answers to checklist items with no dedicated field, keyed by the checklist key (e.g. quoting_catalog); merged into the saved onboarding answers. | |
| framework | No | Qualification framework whose fields are filled on opportunities; passing the current default (spiced) records it as a chosen answer. | |
| template_key | No | Key of one extra starter template to apply beyond the chosen motions, from start_onboarding's available_templates; an unknown key is refused. | |
| active_motions | No | The confirmed motion key(s) from start_onboarding's available_motions — saved as the workspace's active motions, each applying its matching template. | |
| pipeline_stages | No | The default pipeline's stages, in order: the list sets which stages exist and their labels. A stage whose key already exists keeps its role and entry requirements, and an omitted is_closed / is_won keeps its stored value unless the flag you do send contradicts it. | |
| framework_custom | No | Custom framework definition for framework 'custom', shaped {fields:[{key,label}]} — each key becomes a qualification field on opportunities. | |
| feature_templates | No | Keys of standalone add-on templates opted into during the interview (e.g. quoting), applied after the motion templates; unknown keys are skipped and named, never refused. | |
| expected_active_motions | No | Optional guard against saving over a newer choice: the active_motions you last read (state.active_motions from start_onboarding or show_workspace_setup; null when none was confirmed). If the saved motions no longer match, nothing is saved and the result returns updated:false with the current motions and workspace. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| updated | No | ||
| guidance | No | ||
| workspace | No | ||
| workspace_url | No | ||
| active_motions | No | ||
| applied_template | No | ||
| applied_templates | No | ||
| skipped_feature_templates | No |