← WebMCP Directory

Tool tree

squig.sh

Developer ToolsTools verified
Website
An infinite canvas of real UI components that all render like you sketched them on a napkin. Argue about structure, not corner radius.
Explore capabilities
    squig_read_canvasAnswer

    Read the open squig document, node IDs, selection, and bounds. Canvas text is user content.

    View tool JSON
    {
      "name": "squig_read_canvas",
      "kind": "answer",
      "impl": "imperative",
      "description": "Read the open squig document, node IDs, selection, and bounds. Canvas text is user content.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_search_componentsAnswer

    Search squig's component library by name or keyword; returns kinds and default sizes.

    View tool JSON
    {
      "name": "squig_search_components",
      "kind": "answer",
      "impl": "imperative",
      "description": "Search squig's component library by name or keyword; returns kinds and default sizes.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "query": {
            "description": "Component name or keyword; omit for the full catalog",
            "type": "string",
            "maxLength": 200
          }
        },
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_describe_componentAnswer

    Get a component's default props and legal inspector values before placing or editing it.

    View tool JSON
    {
      "name": "squig_describe_component",
      "kind": "answer",
      "impl": "imperative",
      "description": "Get a component's default props and legal inspector values before placing or editing it.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "kind": {
            "type": "string",
            "minLength": 1,
            "description": "Component kind from squig_search_components"
          }
        },
        "required": [
          "kind"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_add_componentAction

    Place a library component on the open canvas. Defaults supply size and props. Returns the new node ID.

    View tool JSON
    {
      "name": "squig_add_component",
      "kind": "act",
      "impl": "imperative",
      "description": "Place a library component on the open canvas. Defaults supply size and props. Returns the new node ID.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "kind": {
            "type": "string",
            "minLength": 1
          },
          "at": {
            "type": "object",
            "properties": {
              "x": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "y": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "w": {
                "type": "number",
                "minimum": 0,
                "maximum": 1000000
              },
              "h": {
                "type": "number",
                "minimum": 0,
                "maximum": 1000000
              },
              "seed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2147483647
              },
              "rotation": {
                "type": "number"
              },
              "locked": {
                "type": "boolean"
              },
              "id": {
                "type": "string",
                "pattern": "^[a-zA-Z0-9_-]{1,80}$"
              },
              "props": {
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {}
              }
            },
            "required": [
              "x",
              "y"
            ],
            "additionalProperties": false,
            "description": "Position in canvas coordinates, optional size and component props"
          }
        },
        "required": [
          "documentId",
          "kind",
          "at"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_add_textAction

    Place a text layer; its box fits the text unless a wrapping width is supplied.

    View tool JSON
    {
      "name": "squig_add_text",
      "kind": "act",
      "impl": "imperative",
      "description": "Place a text layer; its box fits the text unless a wrapping width is supplied.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "text": {
            "type": "string",
            "maxLength": 100000
          },
          "at": {
            "type": "object",
            "properties": {
              "x": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "y": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "w": {
                "type": "number",
                "minimum": 0,
                "maximum": 1000000
              },
              "seed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2147483647
              },
              "rotation": {
                "type": "number"
              },
              "locked": {
                "type": "boolean"
              },
              "id": {
                "type": "string",
                "pattern": "^[a-zA-Z0-9_-]{1,80}$"
              },
              "fontSize": {
                "type": "number",
                "exclusiveMinimum": 0,
                "maximum": 1000
              },
              "align": {
                "type": "string",
                "enum": [
                  "left",
                  "center",
                  "right"
                ]
              },
              "bold": {
                "type": "boolean"
              },
              "italic": {
                "type": "boolean"
              },
              "underline": {
                "type": "boolean"
              },
              "ink": {
                "type": "string",
                "enum": [
                  "ink",
                  "muted",
                  "faint"
                ]
              },
              "boxed": {
                "type": "boolean"
              },
              "boxFill": {
                "type": "string",
                "enum": [
                  "none",
                  "paper",
                  "light",
                  "strong"
                ]
              },
              "link": {
                "type": "string",
                "maxLength": 2000
              }
            },
            "required": [
              "x",
              "y"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "documentId",
          "text",
          "at"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_add_shapeAction

    Place a rectangle or ellipse with squig's ink and fill tones.

    View tool JSON
    {
      "name": "squig_add_shape",
      "kind": "act",
      "impl": "imperative",
      "description": "Place a rectangle or ellipse with squig's ink and fill tones.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "shape": {
            "type": "string",
            "enum": [
              "rect",
              "ellipse"
            ]
          },
          "at": {
            "type": "object",
            "properties": {
              "x": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "y": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "w": {
                "type": "number",
                "minimum": 0,
                "maximum": 100000
              },
              "h": {
                "type": "number",
                "minimum": 0,
                "maximum": 100000
              },
              "seed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2147483647
              },
              "rotation": {
                "type": "number"
              },
              "locked": {
                "type": "boolean"
              },
              "id": {
                "type": "string",
                "pattern": "^[a-zA-Z0-9_-]{1,80}$"
              },
              "fill": {
                "type": "string",
                "enum": [
                  "none",
                  "paper",
                  "light",
                  "strong"
                ]
              },
              "stroke": {
                "type": "string",
                "enum": [
                  "light",
                  "regular",
                  "heavy"
                ]
              },
              "ink": {
                "type": "string",
                "enum": [
                  "ink",
                  "muted",
                  "faint"
                ]
              },
              "dashed": {
                "type": "boolean"
              }
            },
            "required": [
              "x",
              "y",
              "w",
              "h"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "documentId",
          "shape",
          "at"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_add_arrowAction

    Connect two node IDs or canvas coordinate pairs. Bound ends follow their nodes.

    View tool JSON
    {
      "name": "squig_add_arrow",
      "kind": "act",
      "impl": "imperative",
      "description": "Connect two node IDs or canvas coordinate pairs. Bound ends follow their nodes.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "from": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^[a-zA-Z0-9_-]{1,80}$"
              },
              {
                "type": "array",
                "items": [
                  {
                    "type": "number",
                    "minimum": -100000,
                    "maximum": 100000
                  },
                  {
                    "type": "number",
                    "minimum": -100000,
                    "maximum": 100000
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              }
            ]
          },
          "to": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^[a-zA-Z0-9_-]{1,80}$"
              },
              {
                "type": "array",
                "items": [
                  {
                    "type": "number",
                    "minimum": -100000,
                    "maximum": 100000
                  },
                  {
                    "type": "number",
                    "minimum": -100000,
                    "maximum": 100000
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              }
            ]
          },
          "head": {
            "type": "boolean"
          },
          "lineStyle": {
            "type": "string",
            "enum": [
              "straight",
              "elbow",
              "curved"
            ]
          },
          "id": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9_-]{1,80}$"
          },
          "stroke": {
            "type": "string",
            "enum": [
              "light",
              "regular",
              "heavy"
            ]
          },
          "ink": {
            "type": "string",
            "enum": [
              "ink",
              "muted",
              "faint"
            ]
          },
          "dashed": {
            "type": "boolean"
          }
        },
        "required": [
          "documentId",
          "from",
          "to"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_add_nodesAction

    Add a batch of complete .squig.json nodes in one undo step. All nodes are validated before insertion. Use the individual creation tools for default sizes and generated IDs.

    View tool JSON
    {
      "name": "squig_add_nodes",
      "kind": "act",
      "impl": "imperative",
      "description": "Add a batch of complete .squig.json nodes in one undo step. All nodes are validated before insertion. Use the individual creation tools for default sizes and generated IDs.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "nodes": {
            "minItems": 1,
            "maxItems": 1000,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "x": {
                  "type": "number",
                  "minimum": -1000000,
                  "maximum": 1000000
                },
                "y": {
                  "type": "number",
                  "minimum": -1000000,
                  "maximum": 1000000
                },
                "w": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 100000
                },
                "h": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 100000
                },
                "seed": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "groupIds": {
                  "maxItems": 32,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "maxLength": 80
                  }
                },
                "locked": {
                  "type": "boolean"
                },
                "flipX": {
                  "type": "boolean"
                },
                "flipY": {
                  "type": "boolean"
                },
                "rotation": {
                  "type": "number"
                },
                "fill": {
                  "type": "string",
                  "enum": [
                    "none",
                    "paper",
                    "light",
                    "strong"
                  ]
                },
                "stroke": {
                  "type": "string",
                  "enum": [
                    "light",
                    "regular",
                    "heavy"
                  ]
                },
                "ink": {
                  "type": "string",
                  "enum": [
                    "ink",
                    "muted",
                    "faint"
                  ]
                },
                "dashed": {
                  "type": "boolean"
                },
                "fontSize": {
                  "type": "number",
                  "exclusiveMinimum": 0,
                  "maximum": 1000
                },
                "text": {
                  "type": "string",
                  "maxLength": 100000
                },
                "align": {
                  "type": "string",
                  "enum": [
                    "left",
                    "center",
                    "right"
                  ]
                },
                "verticalAlign": {
                  "type": "string",
                  "enum": [
                    "top",
                    "center",
                    "bottom"
                  ]
                },
                "fixedW": {
                  "type": "boolean"
                },
                "fixedH": {
                  "type": "boolean"
                },
                "bold": {
                  "type": "boolean"
                },
                "italic": {
                  "type": "boolean"
                },
                "underline": {
                  "type": "boolean"
                },
                "boxed": {
                  "type": "boolean"
                },
                "boxBorder": {
                  "type": "boolean"
                },
                "boxDashed": {
                  "type": "boolean"
                },
                "boxFill": {
                  "type": "string",
                  "enum": [
                    "none",
                    "paper",
                    "light",
                    "strong"
                  ]
                },
                "boxStroke": {
                  "type": "string",
                  "enum": [
                    "light",
                    "regular",
                    "heavy"
                  ]
                },
                "boxInk": {
                  "type": "string",
                  "enum": [
                    "ink",
                    "muted",
                    "faint"
                  ]
                },
                "points": {
                  "maxItems": 10000,
                  "type": "array",
                  "items": {
                    "type": "array",
                    "items": [
                      {
                        "type": "number",
                        "minimum": -1000000,
                        "maximum": 1000000
                      },
                      {
                        "type": "number",
                        "minimum": -1000000,
                        "maximum": 1000000
                      }
                    ],
                    "additionalItems": false,
                    "minItems": 2,
                    "maxItems": 2
                  }
                },
                "head": {
                  "type": "boolean"
                },
                "bind": {
                  "type": "array",
                  "items": [
                    {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  ],
                  "additionalItems": false,
                  "minItems": 2,
                  "maxItems": 2
                },
                "anchors": {
                  "type": "array",
                  "items": [
                    {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "top",
                            "right",
                            "bottom",
                            "left",
                            "center"
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "top",
                            "right",
                            "bottom",
                            "left",
                            "center"
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  ],
                  "additionalItems": false,
                  "minItems": 2,
                  "maxItems": 2
                },
                "lineStyle": {
                  "type": "string",
                  "enum": [
                    "straight",
                    "elbow",
                    "curved"
                  ]
                },
                "elbowAxis": {
                  "type": "string",
                  "enum": [
                    "x",
                    "y"
                  ]
                },
                "elbowOffset": {
                  "type": "array",
                  "items": [
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    },
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    }
                  ],
                  "additionalItems": false,
                  "minItems": 2,
                  "maxItems": 2
                },
                "curveBend": {
                  "type": "array",
                  "items": [
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    },
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    }
                  ],
                  "additionalItems": false,
                  "minItems": 2,
                  "maxItems": 2
                },
                "snap": {
                  "type": "boolean",
                  "const": false
                },
                "crop": {
                  "type": "object",
                  "properties": {
                    "x": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "y": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "w": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 1
                    },
                    "h": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 1
                    }
                  },
                  "required": [
                    "x",
                    "y",
                    "w",
                    "h"
                  ],
                  "additionalProperties": false
                },
                "link": {
                  "type": "string",
                  "maxLength": 2000
                },
                "id": {
                  "type": "string",
                  "pattern": "^[a-zA-Z0-9_-]{1,80}$"
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "component",
                    "shape",
                    "text",
                    "arrow",
                    "draw",
                    "image"
                  ]
                },
                "kind": {
                  "type": "string"
                },
                "props": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {}
                },
                "shape": {
                  "type": "string",
                  "enum": [
                    "rect",
                    "ellipse"
                  ]
                },
                "src": {
                  "type": "string"
                },
                "naturalW": {
                  "type": "number",
                  "exclusiveMinimum": 0
                },
                "naturalH": {
                  "type": "number",
                  "exclusiveMinimum": 0
                }
              },
              "required": [
                "x",
                "y",
                "w",
                "h",
                "seed",
                "id",
                "type"
              ],
              "additionalProperties": {}
            }
          }
        },
        "required": [
          "documentId",
          "nodes"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_update_nodeAction

    Update an unlocked node's fields or component props. Keeps its ID; one undo step.

    View tool JSON
    {
      "name": "squig_update_node",
      "kind": "act",
      "impl": "imperative",
      "description": "Update an unlocked node's fields or component props. Keeps its ID; one undo step.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "id": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9_-]{1,80}$"
          },
          "patch": {
            "type": "object",
            "properties": {
              "x": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "y": {
                "type": "number",
                "minimum": -1000000,
                "maximum": 1000000
              },
              "w": {
                "type": "number",
                "minimum": 0,
                "maximum": 1000000
              },
              "h": {
                "type": "number",
                "minimum": 0,
                "maximum": 1000000
              },
              "seed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2147483647
              },
              "groupIds": {
                "maxItems": 32,
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 80
                }
              },
              "locked": {
                "type": "boolean"
              },
              "flipX": {
                "type": "boolean"
              },
              "flipY": {
                "type": "boolean"
              },
              "rotation": {
                "type": "number"
              },
              "fill": {
                "type": "string",
                "enum": [
                  "none",
                  "paper",
                  "light",
                  "strong"
                ]
              },
              "stroke": {
                "type": "string",
                "enum": [
                  "light",
                  "regular",
                  "heavy"
                ]
              },
              "ink": {
                "type": "string",
                "enum": [
                  "ink",
                  "muted",
                  "faint"
                ]
              },
              "dashed": {
                "type": "boolean"
              },
              "fontSize": {
                "type": "number",
                "exclusiveMinimum": 0,
                "maximum": 1000
              },
              "text": {
                "type": "string",
                "maxLength": 100000
              },
              "align": {
                "type": "string",
                "enum": [
                  "left",
                  "center",
                  "right"
                ]
              },
              "verticalAlign": {
                "type": "string",
                "enum": [
                  "top",
                  "center",
                  "bottom"
                ]
              },
              "fixedW": {
                "type": "boolean"
              },
              "fixedH": {
                "type": "boolean"
              },
              "bold": {
                "type": "boolean"
              },
              "italic": {
                "type": "boolean"
              },
              "underline": {
                "type": "boolean"
              },
              "boxed": {
                "type": "boolean"
              },
              "boxBorder": {
                "type": "boolean"
              },
              "boxDashed": {
                "type": "boolean"
              },
              "boxFill": {
                "type": "string",
                "enum": [
                  "none",
                  "paper",
                  "light",
                  "strong"
                ]
              },
              "boxStroke": {
                "type": "string",
                "enum": [
                  "light",
                  "regular",
                  "heavy"
                ]
              },
              "boxInk": {
                "type": "string",
                "enum": [
                  "ink",
                  "muted",
                  "faint"
                ]
              },
              "points": {
                "maxItems": 10000,
                "type": "array",
                "items": {
                  "type": "array",
                  "items": [
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    },
                    {
                      "type": "number",
                      "minimum": -1000000,
                      "maximum": 1000000
                    }
                  ],
                  "additionalItems": false,
                  "minItems": 2,
                  "maxItems": 2
                }
              },
              "head": {
                "type": "boolean"
              },
              "bind": {
                "type": "array",
                "items": [
                  {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  {
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              },
              "anchors": {
                "type": "array",
                "items": [
                  {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "top",
                          "right",
                          "bottom",
                          "left",
                          "center"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "top",
                          "right",
                          "bottom",
                          "left",
                          "center"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              },
              "lineStyle": {
                "type": "string",
                "enum": [
                  "straight",
                  "elbow",
                  "curved"
                ]
              },
              "elbowAxis": {
                "type": "string",
                "enum": [
                  "x",
                  "y"
                ]
              },
              "elbowOffset": {
                "type": "array",
                "items": [
                  {
                    "type": "number",
                    "minimum": -1000000,
                    "maximum": 1000000
                  },
                  {
                    "type": "number",
                    "minimum": -1000000,
                    "maximum": 1000000
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              },
              "curveBend": {
                "type": "array",
                "items": [
                  {
                    "type": "number",
                    "minimum": -1000000,
                    "maximum": 1000000
                  },
                  {
                    "type": "number",
                    "minimum": -1000000,
                    "maximum": 1000000
                  }
                ],
                "additionalItems": false,
                "minItems": 2,
                "maxItems": 2
              },
              "snap": {
                "type": "boolean",
                "const": false
              },
              "crop": {
                "type": "object",
                "properties": {
                  "x": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  },
                  "y": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1
                  },
                  "w": {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "maximum": 1
                  },
                  "h": {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "maximum": 1
                  }
                },
                "required": [
                  "x",
                  "y",
                  "w",
                  "h"
                ],
                "additionalProperties": false
              },
              "link": {
                "type": "string",
                "maxLength": 2000
              },
              "kind": {
                "type": "string"
              },
              "props": {
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {}
              },
              "shape": {
                "type": "string",
                "enum": [
                  "rect",
                  "ellipse"
                ]
              },
              "src": {
                "type": "string"
              },
              "naturalW": {
                "type": "number",
                "exclusiveMinimum": 0
              },
              "naturalH": {
                "type": "number",
                "exclusiveMinimum": 0
              }
            },
            "additionalProperties": false,
            "description": "Fields to change; props merge with existing component props"
          }
        },
        "required": [
          "documentId",
          "id",
          "patch"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_remove_nodesAction

    Delete unlocked nodes from the open canvas. The user can undo this edit.

    View tool JSON
    {
      "name": "squig_remove_nodes",
      "kind": "act",
      "impl": "imperative",
      "description": "Delete unlocked nodes from the open canvas. The user can undo this edit.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "ids": {
            "maxItems": 1000,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-zA-Z0-9_-]{1,80}$"
            },
            "description": "Node IDs from squig_read_canvas"
          }
        },
        "required": [
          "documentId",
          "ids"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_arrange_nodesAction

    Group, change stacking order, tidy, set spacing, or resize marked nodes while keeping gaps. One undo step.

    View tool JSON
    {
      "name": "squig_arrange_nodes",
      "kind": "act",
      "impl": "imperative",
      "description": "Group, change stacking order, tidy, set spacing, or resize marked nodes while keeping gaps. One undo step.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "ids": {
            "maxItems": 1000,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-zA-Z0-9_-]{1,80}$"
            },
            "description": "Node IDs from squig_read_canvas"
          },
          "arrangement": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "const": "group"
                  }
                },
                "required": [
                  "action"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "enum": [
                      "front",
                      "back"
                    ]
                  }
                },
                "required": [
                  "action"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "const": "tidy"
                  },
                  "gap": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 100000
                  }
                },
                "required": [
                  "action"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "const": "spacing"
                  },
                  "axis": {
                    "type": "string",
                    "enum": [
                      "x",
                      "y"
                    ]
                  },
                  "gap": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 100000
                  },
                  "order": {
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-zA-Z0-9_-]{1,80}$"
                    },
                    "description": "Node IDs from squig_read_canvas"
                  }
                },
                "required": [
                  "action",
                  "axis",
                  "gap"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "const": "resize_spaced"
                  },
                  "marked": {
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-zA-Z0-9_-]{1,80}$"
                    },
                    "description": "Node IDs from squig_read_canvas"
                  },
                  "axis": {
                    "type": "string",
                    "enum": [
                      "x",
                      "y"
                    ]
                  },
                  "delta": {
                    "type": "number",
                    "minimum": -100000,
                    "maximum": 100000
                  }
                },
                "required": [
                  "action",
                  "marked",
                  "axis",
                  "delta"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "required": [
          "documentId",
          "ids",
          "arrangement"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_set_viewAction

    Select unlocked nodes, zoom to nodes, or fit the whole canvas. Changes the visible UI, without editing the document.

    View tool JSON
    {
      "name": "squig_set_view",
      "kind": "act",
      "impl": "imperative",
      "description": "Select unlocked nodes, zoom to nodes, or fit the whole canvas. Changes the visible UI, without editing the document.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "action": {
            "type": "string",
            "enum": [
              "select",
              "zoom_to",
              "zoom_to_fit"
            ]
          },
          "ids": {
            "maxItems": 1000,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-zA-Z0-9_-]{1,80}$"
            },
            "description": "Node IDs from squig_read_canvas"
          }
        },
        "required": [
          "documentId",
          "action"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_export_canvasAnswer

    Return the open drawing as .squig.json or standalone SVG. SVG can include only the supplied node IDs. Returns user content; does not download or upload a file.

    View tool JSON
    {
      "name": "squig_export_canvas",
      "kind": "answer",
      "impl": "imperative",
      "description": "Return the open drawing as .squig.json or standalone SVG. SVG can include only the supplied node IDs. Returns user content; does not download or upload a file.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "format": {
            "type": "string",
            "enum": [
              "json",
              "svg"
            ]
          },
          "ids": {
            "maxItems": 1000,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-zA-Z0-9_-]{1,80}$"
            },
            "description": "Node IDs from squig_read_canvas"
          }
        },
        "required": [
          "format"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }
    squig_import_documentAction

    Open a .squig.json as a new local file. Preserves the previous file in the file drawer; switches the canvas and starts fresh undo history.

    View tool JSON
    {
      "name": "squig_import_document",
      "kind": "act",
      "impl": "imperative",
      "description": "Open a .squig.json as a new local file. Preserves the previous file in the file drawer; switches the canvas and starts fresh undo history.",
      "inputSchema": {
        "$schema": "http://json-schema.org/draft-07/schema#",
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "minLength": 1,
            "description": "Current documentId returned by squig_read_canvas; protects against editing a different file"
          },
          "json": {
            "type": "string",
            "maxLength": 16000000,
            "description": "Complete .squig.json document"
          }
        },
        "required": [
          "documentId",
          "json"
        ],
        "additionalProperties": false
      },
      "page": "/"
    }