← WebMCP Directory

Tool tree

next.builder.run

Developer ToolsTools verified
Website
Home
Explore capabilities
    get_spaceAnswer

    Inspect the active space: apps, actors, backend, and exposed_types. Types with expose: true live on the account space and every app here shares those records — use that for data two apps both need (clients, organisations). App-only types do not appear here. Example: get_space({}).

    View tool JSON
    {
      "name": "get_space",
      "kind": "answer",
      "impl": "imperative",
      "description": "Inspect the active space: apps, actors, backend, and exposed_types. Types with expose: true live on the account space and every app here shares those records — use that for data two apps both need (clients, organisations). App-only types do not appear here. Example: get_space({}).",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false
      }
    }
    get_specAnswer

    Return the live spec, including generated default views, forms, and pages, and types the space exposes (those have expose: true — shared across apps). App-local types omit expose. Use get_space for the space-level exposed_types list. Use export_spec for the portable authored spec (defaults omitted).

    View tool JSON
    {
      "name": "get_spec",
      "kind": "answer",
      "impl": "imperative",
      "description": "Return the live spec, including generated default views, forms, and pages, and types the space exposes (those have expose: true — shared across apps). App-local types omit expose. Use get_space for the space-level exposed_types list. Use export_spec for the portable authored spec (defaults omitted).",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false
      }
    }
    get_widgetsAnswer

    Discover page widgets and their configuration contract. Call without widget to list or search widgets. Pass a widget key for its inputs. Also pass view for exact compatible field options before calling upsert_page.

    View tool JSON
    {
      "name": "get_widgets",
      "kind": "answer",
      "impl": "imperative",
      "description": "Discover page widgets and their configuration contract. Call without widget to list or search widgets. Pass a widget key for its inputs. Also pass view for exact compatible field options before calling upsert_page.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "widget": {
            "type": "string",
            "description": "Widget key to inspect"
          },
          "view": {
            "type": "string",
            "description": "Optional View key used to resolve compatible field inputs"
          },
          "query": {
            "type": "string",
            "description": "Optional text search when listing widgets"
          },
          "category": {
            "type": "string",
            "enum": [
              "content",
              "data",
              "actions"
            ],
            "description": "Optional category filter when listing widgets"
          }
        },
        "additionalProperties": false
      }
    }
    get_automation_primitivesAnswer

    Discover the canonical structured-workflow grammar, registered conditions and effects, and this runtime's capability profile. Call with a condition or effect key for its parameter contract before authoring a workflow.

    View tool JSON
    {
      "name": "get_automation_primitives",
      "kind": "answer",
      "impl": "imperative",
      "description": "Discover the canonical structured-workflow grammar, registered conditions and effects, and this runtime's capability profile. Call with a condition or effect key for its parameter contract before authoring a workflow.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "kind": {
            "type": "string",
            "enum": [
              "condition",
              "effect"
            ]
          },
          "key": {
            "type": "string"
          }
        },
        "additionalProperties": false
      }
    }
    export_specAction

    Export the portable authored spec as YAML or JSON. Generated default views, forms, and pages are omitted; they are recreated from types on import. Use get_spec to inspect the live spec including defaults.

    View tool JSON
    {
      "name": "export_spec",
      "kind": "act",
      "impl": "imperative",
      "description": "Export the portable authored spec as YAML or JSON. Generated default views, forms, and pages are omitted; they are recreated from types on import. Use get_spec to inspect the live spec including defaults.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "format": {
            "type": "string",
            "enum": [
              "yaml",
              "json"
            ]
          }
        },
        "additionalProperties": false
      }
    }
    query_viewAnswer

    Run a named view and return its rows. Views can filter, sort, limit, and derive live grouped measures — list_records returns every source record (list_<type> in typed mode). Discover view keys via get_spec. Example: query_view({ view: "active_projects" }).

    View tool JSON
    {
      "name": "query_view",
      "kind": "answer",
      "impl": "imperative",
      "description": "Run a named view and return its rows. Views can filter, sort, limit, and derive live grouped measures — list_records returns every source record (list_<type> in typed mode). Discover view keys via get_spec. Example: query_view({ view: \"active_projects\" }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "view": {
            "type": "string",
            "description": "View key from get_spec"
          },
          "expose": {
            "type": "object",
            "description": "Runtime values for the view's expose filters, e.g. { status: \"active\" }",
            "additionalProperties": true
          },
          "record_id": {
            "type": "string",
            "description": "Current record id when the view filters on $record.id"
          }
        },
        "required": [
          "view"
        ],
        "additionalProperties": false
      }
    }
    apply_specAction

    Replace the entire active app spec with a YAML or JSON document. Not a merge: types, views, forms, workflows, and pages missing from the document are deleted. Generated defaults are recreated from types. Requires confirm: true. A document with no types is refused unless wipe: true — { key: "foo" } is not a full spec. Example: apply_spec({ spec: "<full yaml or json>", confirm: true }).

    View tool JSON
    {
      "name": "apply_spec",
      "kind": "act",
      "impl": "imperative",
      "description": "Replace the entire active app spec with a YAML or JSON document. Not a merge: types, views, forms, workflows, and pages missing from the document are deleted. Generated defaults are recreated from types. Requires confirm: true. A document with no types is refused unless wipe: true — { key: \"foo\" } is not a full spec. Example: apply_spec({ spec: \"<full yaml or json>\", confirm: true }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "spec": {
            "type": "string",
            "description": "Full YAML or JSON document for the app spec"
          },
          "confirm": {
            "type": "boolean",
            "description": "Must be true. apply_spec replaces the entire spec."
          },
          "wipe": {
            "type": "boolean",
            "description": "Required with confirm if the document has no types and the app already has some."
          }
        },
        "required": [
          "spec",
          "confirm"
        ],
        "additionalProperties": false
      }
    }
    upsert_typeAction

    Create or update a type and its fields. Use a singular key and label for one record; optional collection_label overrides the automatically pluralized list name. Providing fields replaces the type's field list; omitting fields leaves existing fields unchanged. Field type is canonical; compatible format, presentation, validation, and conditional behavior are optional. lifecycle turns one enum field into a validated state machine. Add or change one field with upsert_field. expose: true stores the type on the account space so every app shares its records. Example: upsert_type({ key: "task", fields: [{ key: "status", type: "enum", values: ["draft", "done"] }], lifecycle: { field: "status", initial: "draft", terminal: ["done"], transitions: [{ key: "complete", from: ["draft"], to: "done" }] } }).

    View tool JSON
    {
      "name": "upsert_type",
      "kind": "act",
      "impl": "imperative",
      "description": "Create or update a type and its fields. Use a singular key and label for one record; optional collection_label overrides the automatically pluralized list name. Providing fields replaces the type's field list; omitting fields leaves existing fields unchanged. Field type is canonical; compatible format, presentation, validation, and conditional behavior are optional. lifecycle turns one enum field into a validated state machine. Add or change one field with upsert_field. expose: true stores the type on the account space so every app shares its records. Example: upsert_type({ key: \"task\", fields: [{ key: \"status\", type: \"enum\", values: [\"draft\", \"done\"] }], lifecycle: { field: \"status\", initial: \"draft\", terminal: [\"done\"], transitions: [{ key: \"complete\", from: [\"draft\"], to: \"done\" }] } }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "collection_label": {
            "type": "string",
            "description": "Optional plural label for lists and navigation. Omit it to infer an English plural from label; pass an empty string to clear an existing override."
          },
          "store": {
            "type": "string"
          },
          "expose": {
            "type": "boolean",
            "description": "If true, the type lives on the account space and all apps share its records. If false or omitted, the type belongs only to this app."
          },
          "lifecycle": {
            "anyOf": [
              {
                "type": "object",
                "description": "Optional state machine attached to one enum field",
                "properties": {
                  "field": {
                    "type": "string",
                    "description": "Enum field containing the current state"
                  },
                  "initial": {
                    "type": "string",
                    "description": "State assigned to every new record"
                  },
                  "terminal": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "transitions": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1
                        },
                        "label": {
                          "type": "string"
                        },
                        "description": {
                          "type": "string"
                        },
                        "placeholder": {
                          "type": "string"
                        },
                        "from": {
                          "type": "array",
                          "minItems": 1,
                          "items": {
                            "type": "string"
                          }
                        },
                        "to": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "key",
                        "from",
                        "to"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "field",
                  "initial",
                  "transitions"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ],
            "description": "State machine definition, or null to remove the existing lifecycle"
          },
          "fields": {
            "description": "Fields to create with the type. Array of field objects, or a map of field key → field (or shorthand type string).",
            "anyOf": [
              {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "minLength": 1,
                      "pattern": "\\S"
                    },
                    "label": {
                      "type": "string"
                    },
                    "meta": {
                      "type": "object",
                      "additionalProperties": true
                    },
                    "description": {
                      "type": "string"
                    },
                    "placeholder": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "text",
                        "number",
                        "date",
                        "datetime",
                        "boolean",
                        "enum",
                        "reference"
                      ]
                    },
                    "required": {
                      "type": "boolean"
                    },
                    "values": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "target": {
                      "type": "string",
                      "description": "Referenced type key (reference fields)"
                    },
                    "format": {
                      "type": "string",
                      "enum": [
                        "email",
                        "url",
                        "phone",
                        "currency",
                        "percentage"
                      ]
                    },
                    "currency": {
                      "type": "string",
                      "pattern": "^[A-Za-z]{3}$"
                    },
                    "presentation": {
                      "type": "string",
                      "enum": [
                        "textarea",
                        "rating",
                        "badge"
                      ]
                    },
                    "variant": {
                      "type": "string",
                      "enum": [
                        "segments"
                      ]
                    },
                    "max": {
                      "type": "number",
                      "minimum": 2,
                      "maximum": 10
                    },
                    "value_semantics": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "string",
                        "enum": [
                          "neutral",
                          "info",
                          "success",
                          "warning",
                          "danger"
                        ]
                      }
                    },
                    "default": {},
                    "validation": {
                      "type": "object",
                      "additionalProperties": true
                    },
                    "visible_when": {
                      "type": "object",
                      "additionalProperties": true
                    },
                    "enabled_when": {
                      "type": "object",
                      "additionalProperties": true
                    },
                    "required_when": {
                      "type": "object",
                      "additionalProperties": true
                    },
                    "hidden_value": {
                      "type": "string",
                      "enum": [
                        "preserve",
                        "clear"
                      ]
                    }
                  }
                }
              },
              {
                "type": "object",
                "additionalProperties": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "Shorthand field type, e.g. text"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1,
                          "pattern": "\\S"
                        },
                        "label": {
                          "type": "string"
                        },
                        "meta": {
                          "type": "object",
                          "additionalProperties": true
                        },
                        "description": {
                          "type": "string"
                        },
                        "placeholder": {
                          "type": "string"
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "text",
                            "number",
                            "date",
                            "datetime",
                            "boolean",
                            "enum",
                            "reference"
                          ]
                        },
                        "required": {
                          "type": "boolean"
                        },
                        "values": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "target": {
                          "type": "string",
                          "description": "Referenced type key (reference fields)"
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "email",
                            "url",
                            "phone",
                            "currency",
                            "percentage"
                          ]
                        },
                        "currency": {
                          "type": "string",
                          "pattern": "^[A-Za-z]{3}$"
                        },
                        "presentation": {
                          "type": "string",
                          "enum": [
                            "textarea",
                            "rating",
                            "badge"
                          ]
                        },
                        "variant": {
                          "type": "string",
                          "enum": [
                            "segments"
                          ]
                        },
                        "max": {
                          "type": "number",
                          "minimum": 2,
                          "maximum": 10
                        },
                        "value_semantics": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "string",
                            "enum": [
                              "neutral",
                              "info",
                              "success",
                              "warning",
                              "danger"
                            ]
                          }
                        },
                        "default": {},
                        "validation": {
                          "type": "object",
                          "additionalProperties": true
                        },
                        "visible_when": {
                          "type": "object",
                          "additionalProperties": true
                        },
                        "enabled_when": {
                          "type": "object",
                          "additionalProperties": true
                        },
                        "required_when": {
                          "type": "object",
                          "additionalProperties": true
                        },
                        "hidden_value": {
                          "type": "string",
                          "enum": [
                            "preserve",
                            "clear"
                          ]
                        }
                      }
                    }
                  ]
                }
              }
            ]
          }
        },
        "required": [
          "key"
        ],
        "additionalProperties": false
      }
    }
    rename_typeAction

    Rename a technical type key while preserving its stable identity, records, and direct spec references. Explicit view, form, page, and workflow keys remain unchanged.

    View tool JSON
    {
      "name": "rename_type",
      "kind": "act",
      "impl": "imperative",
      "description": "Rename a technical type key while preserving its stable identity, records, and direct spec references. Explicit view, form, page, and workflow keys remain unchanged.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          }
        },
        "required": [
          "from",
          "to"
        ],
        "additionalProperties": false
      }
    }
    upsert_fieldAction

    Add or update one field without replacing the type's other fields. type identifies the record type; kind is the field kind. Formats, presentations, and validation must be compatible with that kind. Enum fields need values, reference fields need target, currency fields need currency, and rating fields use max from 2 to 10. Example: upsert_field({ type: "submission", key: "stage", kind: "enum", values: ["submitted", "winner", "rejected"], presentation: "badge", value_semantics: { submitted: "neutral", winner: "success", rejected: "danger" } }).

    View tool JSON
    {
      "name": "upsert_field",
      "kind": "act",
      "impl": "imperative",
      "description": "Add or update one field without replacing the type's other fields. type identifies the record type; kind is the field kind. Formats, presentations, and validation must be compatible with that kind. Enum fields need values, reference fields need target, currency fields need currency, and rating fields use max from 2 to 10. Example: upsert_field({ type: \"submission\", key: \"stage\", kind: \"enum\", values: [\"submitted\", \"winner\", \"rejected\"], presentation: \"badge\", value_semantics: { submitted: \"neutral\", winner: \"success\", rejected: \"danger\" } }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key (not the field kind)"
          },
          "key": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "kind": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "date",
              "datetime",
              "boolean",
              "enum",
              "reference"
            ],
            "description": "Field kind"
          },
          "required": {
            "type": "boolean"
          },
          "values": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "target": {
            "type": "string",
            "description": "Referenced type key (reference fields)"
          },
          "format": {
            "type": "string",
            "enum": [
              "email",
              "url",
              "phone",
              "currency",
              "percentage"
            ]
          },
          "currency": {
            "type": "string",
            "pattern": "^[A-Za-z]{3}$"
          },
          "presentation": {
            "type": "string",
            "enum": [
              "textarea",
              "rating",
              "badge"
            ]
          },
          "variant": {
            "type": "string",
            "enum": [
              "segments"
            ]
          },
          "max": {
            "type": "number",
            "minimum": 2,
            "maximum": 10
          },
          "value_semantics": {
            "type": "object",
            "additionalProperties": {
              "type": "string",
              "enum": [
                "neutral",
                "info",
                "success",
                "warning",
                "danger"
              ]
            }
          },
          "validation": {
            "type": "object",
            "additionalProperties": true
          },
          "visible_when": {
            "type": "object",
            "additionalProperties": true
          },
          "enabled_when": {
            "type": "object",
            "additionalProperties": true
          },
          "required_when": {
            "type": "object",
            "additionalProperties": true
          },
          "hidden_value": {
            "type": "string",
            "enum": [
              "preserve",
              "clear"
            ]
          }
        },
        "required": [
          "type",
          "key"
        ],
        "additionalProperties": false
      }
    }
    rename_fieldAction

    Rename a field key while keeping its identity and stored values.

    View tool JSON
    {
      "name": "rename_field",
      "kind": "act",
      "impl": "imperative",
      "description": "Rename a field key while keeping its identity and stored values.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          }
        },
        "required": [
          "type",
          "from",
          "to"
        ],
        "additionalProperties": false
      }
    }
    delete_fieldSensitive Action

    Remove a field from a type and drop its SQLite column.

    View tool JSON
    {
      "name": "delete_field",
      "kind": "transact",
      "impl": "imperative",
      "description": "Remove a field from a type and drop its SQLite column.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "key": {
            "type": "string"
          }
        },
        "required": [
          "type",
          "key"
        ],
        "additionalProperties": false
      }
    }
    upsert_viewAction

    Create or update a named view (a stored query: filter, sort, limit, columns, or live grouped measures). For a normal view, include fields in the order people should see them, such as fields: ["name", "status", "client.name"]. If fields is omitted while creating a normal view, builder.run chooses up to six useful source fields automatically; an empty fields array is invalid. Omitting fields while updating preserves the existing selection. For a grouped view, omit fields to derive them from group_by and measure aliases. group_by accepts one source field. measures supports count, sum, avg, min, and max; avg accepts field or fields. Sort aggregate aliases with order_by. Run it with query_view. Example: upsert_view({ key: "scores", source: "review", group_by: "submission", measures: { review_count: { op: "count" }, overall_score: { op: "avg", fields: ["quality", "impact"] } }, order_by: { overall_score: "desc" } }).

    View tool JSON
    {
      "name": "upsert_view",
      "kind": "act",
      "impl": "imperative",
      "description": "Create or update a named view (a stored query: filter, sort, limit, columns, or live grouped measures). For a normal view, include fields in the order people should see them, such as fields: [\"name\", \"status\", \"client.name\"]. If fields is omitted while creating a normal view, builder.run chooses up to six useful source fields automatically; an empty fields array is invalid. Omitting fields while updating preserves the existing selection. For a grouped view, omit fields to derive them from group_by and measure aliases. group_by accepts one source field. measures supports count, sum, avg, min, and max; avg accepts field or fields. Sort aggregate aliases with order_by. Run it with query_view. Example: upsert_view({ key: \"scores\", source: \"review\", group_by: \"submission\", measures: { review_count: { op: \"count\" }, overall_score: { op: \"avg\", fields: [\"quality\", \"impact\"] } }, order_by: { overall_score: \"desc\" } }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "source": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "string"
            },
            "description": "Ordered visible columns for a normal view. Reference labels may use paths such as client.name. Omit on creation to infer useful defaults; omit on update to preserve existing columns; omit for grouped views to derive aggregate columns."
          },
          "where": {
            "type": "object"
          },
          "expose": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "limit": {
            "type": "number"
          },
          "order_by": {
            "type": "object"
          },
          "group_by": {
            "type": "string"
          },
          "measures": {
            "type": "object",
            "description": "Named live aggregates for a grouped view",
            "additionalProperties": {
              "type": "object",
              "properties": {
                "op": {
                  "type": "string",
                  "enum": [
                    "count",
                    "sum",
                    "avg",
                    "min",
                    "max"
                  ]
                },
                "field": {
                  "type": "string"
                },
                "fields": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "op"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": [
          "key",
          "source"
        ],
        "additionalProperties": false
      }
    }
    upsert_formAction

    Create or update a record-backed or standalone form. Record forms use type plus ordered field keys. Standalone forms own reusable field definitions under inputs and emit form.submitted with {form, values}. submit.success optionally customizes the standalone confirmation; workflow behavior belongs in a workflow listening for form.submitted. Example: upsert_form({ key: "contact_us", mode: "standalone", inputs: { name: { type: "text", required: true }, email: { type: "text", format: "email" } }, submit: { success: { title: "Thanks" } } }).

    View tool JSON
    {
      "name": "upsert_form",
      "kind": "act",
      "impl": "imperative",
      "description": "Create or update a record-backed or standalone form. Record forms use type plus ordered field keys. Standalone forms own reusable field definitions under inputs and emit form.submitted with {form, values}. submit.success optionally customizes the standalone confirmation; workflow behavior belongs in a workflow listening for form.submitted. Example: upsert_form({ key: \"contact_us\", mode: \"standalone\", inputs: { name: { type: \"text\", required: true }, email: { type: \"text\", format: \"email\" } }, submit: { success: { title: \"Thanks\" } } }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "type": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "inputs": {
            "type": "object",
            "description": "Named field definitions for a standalone form.",
            "additionalProperties": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "minLength": 1,
                  "pattern": "\\S"
                },
                "label": {
                  "type": "string"
                },
                "meta": {
                  "type": "object",
                  "additionalProperties": true
                },
                "description": {
                  "type": "string"
                },
                "placeholder": {
                  "type": "string"
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "text",
                    "number",
                    "date",
                    "datetime",
                    "boolean",
                    "enum",
                    "reference"
                  ]
                },
                "required": {
                  "type": "boolean"
                },
                "values": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "target": {
                  "type": "string",
                  "description": "Referenced type key (reference fields)"
                },
                "format": {
                  "type": "string",
                  "enum": [
                    "email",
                    "url",
                    "phone",
                    "currency",
                    "percentage"
                  ]
                },
                "currency": {
                  "type": "string",
                  "pattern": "^[A-Za-z]{3}$"
                },
                "presentation": {
                  "type": "string",
                  "enum": [
                    "textarea",
                    "rating",
                    "badge"
                  ]
                },
                "variant": {
                  "type": "string",
                  "enum": [
                    "segments"
                  ]
                },
                "max": {
                  "type": "number",
                  "minimum": 2,
                  "maximum": 10
                },
                "value_semantics": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "string",
                    "enum": [
                      "neutral",
                      "info",
                      "success",
                      "warning",
                      "danger"
                    ]
                  }
                },
                "default": {},
                "validation": {
                  "type": "object",
                  "additionalProperties": true
                },
                "visible_when": {
                  "type": "object",
                  "additionalProperties": true
                },
                "enabled_when": {
                  "type": "object",
                  "additionalProperties": true
                },
                "required_when": {
                  "type": "object",
                  "additionalProperties": true
                },
                "hidden_value": {
                  "type": "string",
                  "enum": [
                    "preserve",
                    "clear"
                  ]
                }
              }
            }
          },
          "mode": {
            "type": "string",
            "enum": [
              "create",
              "edit",
              "standalone"
            ]
          },
          "submit": {
            "type": "object",
            "properties": {
              "success": {
                "type": "object",
                "properties": {
                  "title": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          }
        },
        "required": [
          "key"
        ],
        "additionalProperties": false
      }
    }
    upsert_workflowAction

    Create or update a structured workflow. Call get_automation_primitives first. Use registered effects and {$ref:"vars.name"} bindings. Gates contain pass/fail steps; loops and parallel branches contain their own steps. expose: ["agent"] registers invoke_<key>. Example: upsert_workflow({ key: "mark_paid", expose: ["agent"], input: { invoice: { record: "invoice" } }, steps: [{ effect: { key: "records.set", params: { record: {$ref:"vars.invoice"}, values: {status:"paid"} } } }] }).

    View tool JSON
    {
      "name": "upsert_workflow",
      "kind": "act",
      "impl": "imperative",
      "description": "Create or update a structured workflow. Call get_automation_primitives first. Use registered effects and {$ref:\"vars.name\"} bindings. Gates contain pass/fail steps; loops and parallel branches contain their own steps. expose: [\"agent\"] registers invoke_<key>. Example: upsert_workflow({ key: \"mark_paid\", expose: [\"agent\"], input: { invoice: { record: \"invoice\" } }, steps: [{ effect: { key: \"records.set\", params: { record: {$ref:\"vars.invoice\"}, values: {status:\"paid\"} } } }] }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "description": {
            "type": "string"
          },
          "enabled": {
            "type": "boolean"
          },
          "priority": {
            "type": "integer"
          },
          "input": {
            "type": "object",
            "description": "Named inputs. Each value is {record:\"type_key\"} or {value:\"text|number|boolean|date|object|array\"}."
          },
          "trigger": {
            "type": "object",
            "description": "Optional {key, config?}. Omit for a callable workflow."
          },
          "expose": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "ui",
                "agent"
              ]
            }
          },
          "steps": {
            "type": "array",
            "description": "Canonical nested steps returned by get_automation_primitives."
          }
        },
        "required": [
          "key"
        ],
        "additionalProperties": false
      }
    }
    upsert_pageAction

    Create or update a page of grids and widgets. Call get_widgets first to discover widget keys, required values, and compatible fields. Widget values are validated against that contract. Optional folder groups it in the app menu. Optional icon is one of: page, dashboard, table, chart, line, donut, board, calendar, list, inbox, people, money, time. If icon is omitted when creating a page, a one-time default is inferred from its widgets; later edits do not change it. A group nests children in a blocks array even when there is only one widget. columns is how many widgets sit side by side; unused columns stay empty. Example: upsert_page({ key: "board", icon: "board", path: "/board", blocks: [{ kind: "group", columns: 1, blocks: [{ kind: "widget", widget: "table", values: { view: "active_projects" } }] }] }).

    View tool JSON
    {
      "name": "upsert_page",
      "kind": "act",
      "impl": "imperative",
      "description": "Create or update a page of grids and widgets. Call get_widgets first to discover widget keys, required values, and compatible fields. Widget values are validated against that contract. Optional folder groups it in the app menu. Optional icon is one of: page, dashboard, table, chart, line, donut, board, calendar, list, inbox, people, money, time. If icon is omitted when creating a page, a one-time default is inferred from its widgets; later edits do not change it. A group nests children in a blocks array even when there is only one widget. columns is how many widgets sit side by side; unused columns stay empty. Example: upsert_page({ key: \"board\", icon: \"board\", path: \"/board\", blocks: [{ kind: \"group\", columns: 1, blocks: [{ kind: \"widget\", widget: \"table\", values: { view: \"active_projects\" } }] }] }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "meta": {
            "type": "object",
            "additionalProperties": true
          },
          "path": {
            "type": "string"
          },
          "folder": {
            "type": "string"
          },
          "icon": {
            "type": "string",
            "enum": [
              "page",
              "dashboard",
              "table",
              "chart",
              "line",
              "donut",
              "board",
              "calendar",
              "list",
              "inbox",
              "people",
              "money",
              "time"
            ],
            "description": "Sidebar icon for this page."
          },
          "blocks": {
            "type": "array",
            "description": "Page layout. A group nests children in a blocks array — always an array, even for one widget.",
            "items": {
              "type": "object",
              "properties": {
                "kind": {
                  "type": "string",
                  "enum": [
                    "widget",
                    "group"
                  ]
                },
                "widget": {
                  "type": "string"
                },
                "values": {
                  "type": "object"
                },
                "columns": {
                  "type": "number",
                  "description": "Widgets side by side in this group (1–4). Unused cells stay empty."
                },
                "blocks": {
                  "type": "array",
                  "items": {
                    "type": "object"
                  }
                }
              }
            }
          }
        },
        "required": [
          "key"
        ],
        "additionalProperties": false
      }
    }
    create_appAction

    Create an app in the active space and switch to it. The new app can use types the space already exposes (see get_space.exposed_types) — do not recreate those types in the app. Example: create_app({ name: "Invoicing" }).

    View tool JSON
    {
      "name": "create_app",
      "kind": "act",
      "impl": "imperative",
      "description": "Create an app in the active space and switch to it. The new app can use types the space already exposes (see get_space.exposed_types) — do not recreate those types in the app. Example: create_app({ name: \"Invoicing\" }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "sample": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      }
    }
    delete_appSensitive Action

    Delete an app created from this account space. Shared records stay.

    View tool JSON
    {
      "name": "delete_app",
      "kind": "transact",
      "impl": "imperative",
      "description": "Delete an app created from this account space. Shared records stay.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      }
    }
    switch_appAction

    Switch the active app by id. Space-exposed types stay available; app-local types change with the app.

    View tool JSON
    {
      "name": "switch_app",
      "kind": "act",
      "impl": "imperative",
      "description": "Switch the active app by id. Space-exposed types stay available; app-local types change with the app.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      }
    }
    create_spaceAction

    Create a new account space with its own apps. After switching to it, upsert_type({ expose: true }) creates types every app in this space shares — e.g. a customer type used by both a CRM and invoicing. Example: create_space({ name: "Studio" }).

    View tool JSON
    {
      "name": "create_space",
      "kind": "act",
      "impl": "imperative",
      "description": "Create a new account space with its own apps. After switching to it, upsert_type({ expose: true }) creates types every app in this space shares — e.g. a customer type used by both a CRM and invoicing. Example: create_space({ name: \"Studio\" }).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      }
    }
    list_samplesAnswer

    List gallery sample applications that can be loaded as an app.

    View tool JSON
    {
      "name": "list_samples",
      "kind": "answer",
      "impl": "imperative",
      "description": "List gallery sample applications that can be loaded as an app.",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false
      }
    }
    describe_typeAnswer

    Inspect one record type on demand, including field constraints and lifecycle transitions. Pass a record id to also see its current state and available transitions. Call this before creating or updating unfamiliar records.

    View tool JSON
    {
      "name": "describe_type",
      "kind": "answer",
      "impl": "imperative",
      "description": "Inspect one record type on demand, including field constraints and lifecycle transitions. Pass a record id to also see its current state and available transitions. Call this before creating or updating unfamiliar records.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec"
          },
          "id": {
            "type": "string",
            "description": "Optional record id"
          }
        },
        "required": [
          "type"
        ],
        "additionalProperties": false
      }
    }
    list_recordsAnswer

    List every record of one type, unfiltered. Use query_view when you need filtering, sorting, limits, or aggregates.

    View tool JSON
    {
      "name": "list_records",
      "kind": "answer",
      "impl": "imperative",
      "description": "List every record of one type, unfiltered. Use query_view when you need filtering, sorting, limits, or aggregates.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          }
        },
        "required": [
          "type"
        ],
        "additionalProperties": false
      }
    }
    get_recordAnswer

    Get one record by type and id.

    View tool JSON
    {
      "name": "get_record",
      "kind": "answer",
      "impl": "imperative",
      "description": "Get one record by type and id.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          },
          "id": {
            "type": "string",
            "description": "Record id"
          }
        },
        "required": [
          "type",
          "id"
        ],
        "additionalProperties": false
      }
    }
    create_recordAction

    Create a record of one type. Call describe_type first for fields and constraints; lifecycle state and audit fields are system-managed.

    View tool JSON
    {
      "name": "create_record",
      "kind": "act",
      "impl": "imperative",
      "description": "Create a record of one type. Call describe_type first for fields and constraints; lifecycle state and audit fields are system-managed.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          },
          "values": {
            "type": "object",
            "description": "Field values accepted by the selected type. Use describe_type for the contract.",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "values"
        ],
        "additionalProperties": false
      }
    }
    update_recordAction

    Update fields on one record. Call describe_type first; use transition_record for lifecycle state changes.

    View tool JSON
    {
      "name": "update_record",
      "kind": "act",
      "impl": "imperative",
      "description": "Update fields on one record. Call describe_type first; use transition_record for lifecycle state changes.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          },
          "id": {
            "type": "string",
            "description": "Record id"
          },
          "values": {
            "type": "object",
            "description": "Field values accepted by the selected type. Use describe_type for the contract.",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "id",
          "values"
        ],
        "additionalProperties": false
      }
    }
    delete_recordSensitive Action

    Delete one record by type and id.

    View tool JSON
    {
      "name": "delete_record",
      "kind": "transact",
      "impl": "imperative",
      "description": "Delete one record by type and id.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          },
          "id": {
            "type": "string",
            "description": "Record id"
          }
        },
        "required": [
          "type",
          "id"
        ],
        "additionalProperties": false
      }
    }
    transition_recordAction

    Apply a named lifecycle transition to a record. Use describe_type with the record id to discover transitions currently available.

    View tool JSON
    {
      "name": "transition_record",
      "kind": "act",
      "impl": "imperative",
      "description": "Apply a named lifecycle transition to a record. Use describe_type with the record id to discover transitions currently available.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type key from get_spec or describe_type"
          },
          "id": {
            "type": "string",
            "description": "Record id"
          },
          "transition": {
            "type": "string",
            "description": "Lifecycle transition key"
          }
        },
        "required": [
          "type",
          "id",
          "transition"
        ],
        "additionalProperties": false
      }
    }