Create model
layerz_create_modelCreates a model and returns its detail with its UUID, in workspace_id (a workspace the caller belongs to; default the personal one) where every member of that workspace edits it. template_id copies a template (official, or from the library of a workspace the caller belongs to) into the new model with its sources, staged transactions and mapping rules under fresh ids (connector credentials excluded); the template itself is unchanged. timelines sets the grains and bounds (only the grains given: { monthly } alone gives a monthly-only model; on a template, the bounds), glyph its emblem (a kebab-case Lucide icon name, e.g. trending-up, landmark, house, coffee, wallet). file_id imports an uploaded workbook instead (deterministic compiler, no AI) and returns { model_id, name, status: "importing" } with guidance (the rebuild method) at once: the import runs after the response (about a minute for a large workbook), then its report (fidelity by scenario, residue, constructions map) lands in the model FINANCE.md (has_finance_md); a failed import deletes the model. The workbook stays with the model for layerz_diff { source }. Undated period headers return IMPORT_DECISION_REQUIRED with the axes to anchor (anchors). conventions carries the conventions of the workspace it lands in and its FINANCE.md (as in layerz_get_conventions) when either is set. Rejected past the plan model cap. Not advertised to model-scoped or read-only keys.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "layerz_create_model"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Model name. Required without `file_id`; an imported workbook names the model after its file. | |
| glyph | No | Emblem icon: a kebab-case Lucide icon name (https://lucide.dev/icons), e.g. "trending-up", "coffee", "landmark". Shown in-app and on the social/OG card. Emojis/free text are rejected with suggestions. Aliases: cash/money→banknote, bank→landmark, cart→shopping-cart, chart/graph→chart-line. | |
| anchors | No | With `file_id`: the first period (`2026`, `2026-01`, `2026-Q1`) of each sheet whose period headers carry no date, as listed by an `IMPORT_DECISION_REQUIRED` error; `[]` leaves those sheets out. | |
| file_id | No | An uploaded workbook (`layerz_create_upload_url`) the model is imported from by the deterministic compiler: live formulas, values where a formula has no equivalent, and the import report (`import`: fidelity, residue, recalculation coverage, constructions map). Exclusive with `template_id`. | |
| subtitle | No | ||
| timelines | No | ||
| template_id | No | ||
| workspace_id | No | Workspace the model is created in (one the caller belongs to; `layerz_list_models` lists them). Default: the personal workspace. |