genart.dev
MCP ToolsCapture & Layout

snapshot_layout

Return a structural summary of the workspace layout — all sketches with positions, sizes, renderer types, groups, and bounding box — without full algorithm or philosophy content.

Input Schema

ParameterTypeRequiredDescription
includeGroupsbooleannoInclude group information (default: true)
includeStatebooleannoInclude current seed and param values (default: false)

Output Shape

{
  "success": true,
  "workspace": {
    "id": "typography-explorations",
    "title": "Typography Explorations",
    "viewport": { "x": 0, "y": 0, "zoom": 0.5 }
  },
  "sketches": [
    {
      "id": "orchestrated-opposition",
      "title": "Orchestrated Opposition",
      "renderer": "p5",
      "position": { "x": 0, "y": 0 },
      "canvas": { "width": 1200, "height": 1200 },
      "parameterCount": 4,
      "colorCount": 3,
      "snapshotCount": 1,
      "locked": false,
      "visible": true
    },
    {
      "id": "cadenced-fields",
      "title": "Cadenced Fields",
      "renderer": "p5",
      "position": { "x": 1400, "y": 0 },
      "canvas": { "width": 1200, "height": 1200 },
      "parameterCount": 6,
      "colorCount": 2,
      "snapshotCount": 0,
      "locked": false,
      "visible": true
    }
  ],
  "groups": [
    {
      "id": "typography-series",
      "label": "Typography Series",
      "sketchIds": ["orchestrated-opposition"],
      "color": "#c4342d"
    }
  ],
  "boundingBox": { "x": 0, "y": 0, "width": 2600, "height": 1200 },
  "totalSketches": 2,
  "rendererBreakdown": { "p5": 2 }
}

When includeState is true, each sketch entry also includes:

{
  "state": {
    "seed": 12345,
    "params": { "margin": 60, "cellCount": 8 },
    "colorPalette": ["#1a1a1a", "#f5f0eb", "#c4342d"]
  }
}

Side Effects

None. Read-only.

Error Cases

ConditionError
No workspace open"No workspace is currently open"

Golden Path Example

Request:

{
  "includeGroups": true,
  "includeState": false
}

Response: (as shown in Output Shape above)