surfcad-mcp 0.2.2 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@
2
2
  "version": 1,
3
3
  "bridgeVersion": 1,
4
4
  "generatedBy": "npm run export:agent",
5
- "count": 188,
5
+ "count": 189,
6
6
  "$defs": {
7
7
  "status": {
8
8
  "type": "object",
@@ -503,7 +503,7 @@
503
503
  },
504
504
  {
505
505
  "name": "errors",
506
- "description": "Structured errors from the last finished geometry run. message is the same text the viewport shows. featureType, featureLabel, and featureIndex identify the failed feature when known. detail is the exception name, a Manifold status, or the kernel message when that text is not already in message. Stack frames and URLs are omitted, and detail is absent when there is nothing further. Cleared on the next successful run. Feature and kernel failures use code feature_failed.",
506
+ "description": "Structured errors from the last finished geometry run. message is the same text the viewport shows. featureType, featureLabel, and featureIndex identify the failed feature when known. detail is the exception name, a Manifold status, or the kernel message when that text is not already in message. Stack frames and URLs are omitted, and detail is always present on feature_failed: when the kernel adds nothing, it names the helper that threw (move adds how to name the body). Cleared on the next successful run. Feature and kernel failures use code feature_failed.",
507
507
  "args": {
508
508
  "type": "object",
509
509
  "additionalProperties": false,
@@ -557,7 +557,7 @@
557
557
  },
558
558
  {
559
559
  "name": "screenshot",
560
- "description": "Capture the viewport. The default is a full-size PNG data URL. Optional max_width and scale downscale in the browser before encoding. format is png or jpeg; quality (0 to 1) applies to jpeg only.",
560
+ "description": "Capture the viewport, centered on the camera target (an open feature card's view offset is not applied to the capture). The default is a full-size PNG data URL. Optional max_width and scale downscale in the browser before encoding. format is png or jpeg; quality (0 to 1) applies to jpeg only.",
561
561
  "args": {
562
562
  "type": "object",
563
563
  "additionalProperties": false,
@@ -628,7 +628,7 @@
628
628
  },
629
629
  {
630
630
  "name": "undo",
631
- "description": "One undo on the feature-bar stack (sketch session, assembly joints, or active part script) and run when the part script changes.",
631
+ "description": "One undo on the feature-bar stack (sketch session, assembly joints, or active part script) and run when the part script changes. A part step returns the refreshed status, bodyCount included.",
632
632
  "args": {
633
633
  "type": "object",
634
634
  "additionalProperties": false,
@@ -749,7 +749,7 @@
749
749
  },
750
750
  {
751
751
  "name": "redo",
752
- "description": "One redo on the feature-bar stack (assembly joints or active part; sketch has no redo).",
752
+ "description": "One redo on the feature-bar stack (assembly joints or active part; sketch has no redo). A part step returns the refreshed status, bodyCount included.",
753
753
  "args": {
754
754
  "type": "object",
755
755
  "additionalProperties": false,
@@ -1076,7 +1076,7 @@
1076
1076
  },
1077
1077
  {
1078
1078
  "name": "mode",
1079
- "description": "Open picker / card mode summary.",
1079
+ "description": "Open picker / card mode summary. featureEdit is { mode, featureId, kind, dialog } while any feature edit is open (the App sheet or the viewport card open_feature put up), else null.",
1080
1080
  "args": {
1081
1081
  "type": "object",
1082
1082
  "additionalProperties": false,
@@ -1212,6 +1212,28 @@
1212
1212
  "uiEntry": null,
1213
1213
  "example": {}
1214
1214
  },
1215
+ {
1216
+ "name": "list_bodies",
1217
+ "description": "Bodies of the active part's last run, in mesh order: [{ index, at, triangleCount }]. index is insert_move body_index; at is the centroid move() names (insert_move at, edit_feature at). Empty before the first run.",
1218
+ "args": {
1219
+ "type": "object",
1220
+ "additionalProperties": false,
1221
+ "properties": {}
1222
+ },
1223
+ "result": {
1224
+ "type": "object",
1225
+ "additionalProperties": true
1226
+ },
1227
+ "errors": [
1228
+ "internal"
1229
+ ],
1230
+ "mutates": false,
1231
+ "destructive": false,
1232
+ "confirm": false,
1233
+ "immediate": true,
1234
+ "uiEntry": null,
1235
+ "example": {}
1236
+ },
1215
1237
  {
1216
1238
  "name": "list_edges",
1217
1239
  "description": "Mesh feature edges (raw or grouped).",
@@ -1406,7 +1428,7 @@
1406
1428
  },
1407
1429
  {
1408
1430
  "name": "insert_cube",
1409
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
1431
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
1410
1432
  "args": {
1411
1433
  "type": "object",
1412
1434
  "additionalProperties": false,
@@ -1428,18 +1450,18 @@
1428
1450
  },
1429
1451
  "x": {
1430
1452
  "type": "number",
1431
- "minimum": -500,
1432
- "maximum": 500
1453
+ "minimum": -1000000,
1454
+ "maximum": 1000000
1433
1455
  },
1434
1456
  "y": {
1435
1457
  "type": "number",
1436
- "minimum": -500,
1437
- "maximum": 500
1458
+ "minimum": -1000000,
1459
+ "maximum": 1000000
1438
1460
  },
1439
1461
  "z": {
1440
1462
  "type": "number",
1441
- "minimum": -500,
1442
- "maximum": 500
1463
+ "minimum": -1000000,
1464
+ "maximum": 1000000
1443
1465
  },
1444
1466
  "rx": {
1445
1467
  "type": "number",
@@ -1580,7 +1602,7 @@
1580
1602
  },
1581
1603
  {
1582
1604
  "name": "insert_rounded_box",
1583
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
1605
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
1584
1606
  "args": {
1585
1607
  "type": "object",
1586
1608
  "additionalProperties": false,
@@ -1607,18 +1629,18 @@
1607
1629
  },
1608
1630
  "x": {
1609
1631
  "type": "number",
1610
- "minimum": -500,
1611
- "maximum": 500
1632
+ "minimum": -1000000,
1633
+ "maximum": 1000000
1612
1634
  },
1613
1635
  "y": {
1614
1636
  "type": "number",
1615
- "minimum": -500,
1616
- "maximum": 500
1637
+ "minimum": -1000000,
1638
+ "maximum": 1000000
1617
1639
  },
1618
1640
  "z": {
1619
1641
  "type": "number",
1620
- "minimum": -500,
1621
- "maximum": 500
1642
+ "minimum": -1000000,
1643
+ "maximum": 1000000
1622
1644
  },
1623
1645
  "rx": {
1624
1646
  "type": "number",
@@ -1760,7 +1782,7 @@
1760
1782
  },
1761
1783
  {
1762
1784
  "name": "insert_cylinder",
1763
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
1785
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
1764
1786
  "args": {
1765
1787
  "type": "object",
1766
1788
  "additionalProperties": false,
@@ -1779,18 +1801,18 @@
1779
1801
  },
1780
1802
  "x": {
1781
1803
  "type": "number",
1782
- "minimum": -500,
1783
- "maximum": 500
1804
+ "minimum": -1000000,
1805
+ "maximum": 1000000
1784
1806
  },
1785
1807
  "y": {
1786
1808
  "type": "number",
1787
- "minimum": -500,
1788
- "maximum": 500
1809
+ "minimum": -1000000,
1810
+ "maximum": 1000000
1789
1811
  },
1790
1812
  "z": {
1791
1813
  "type": "number",
1792
- "minimum": -500,
1793
- "maximum": 500
1814
+ "minimum": -1000000,
1815
+ "maximum": 1000000
1794
1816
  },
1795
1817
  "rx": {
1796
1818
  "type": "number",
@@ -1930,7 +1952,7 @@
1930
1952
  },
1931
1953
  {
1932
1954
  "name": "insert_sphere",
1933
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
1955
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
1934
1956
  "args": {
1935
1957
  "type": "object",
1936
1958
  "additionalProperties": false,
@@ -1946,18 +1968,18 @@
1946
1968
  },
1947
1969
  "x": {
1948
1970
  "type": "number",
1949
- "minimum": -500,
1950
- "maximum": 500
1971
+ "minimum": -1000000,
1972
+ "maximum": 1000000
1951
1973
  },
1952
1974
  "y": {
1953
1975
  "type": "number",
1954
- "minimum": -500,
1955
- "maximum": 500
1976
+ "minimum": -1000000,
1977
+ "maximum": 1000000
1956
1978
  },
1957
1979
  "z": {
1958
1980
  "type": "number",
1959
- "minimum": -500,
1960
- "maximum": 500
1981
+ "minimum": -1000000,
1982
+ "maximum": 1000000
1961
1983
  },
1962
1984
  "rx": {
1963
1985
  "type": "number",
@@ -2096,7 +2118,7 @@
2096
2118
  },
2097
2119
  {
2098
2120
  "name": "insert_tube",
2099
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2121
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2100
2122
  "args": {
2101
2123
  "type": "object",
2102
2124
  "additionalProperties": false,
@@ -2143,18 +2165,18 @@
2143
2165
  },
2144
2166
  "x": {
2145
2167
  "type": "number",
2146
- "minimum": -500,
2147
- "maximum": 500
2168
+ "minimum": -1000000,
2169
+ "maximum": 1000000
2148
2170
  },
2149
2171
  "y": {
2150
2172
  "type": "number",
2151
- "minimum": -500,
2152
- "maximum": 500
2173
+ "minimum": -1000000,
2174
+ "maximum": 1000000
2153
2175
  },
2154
2176
  "z": {
2155
2177
  "type": "number",
2156
- "minimum": -500,
2157
- "maximum": 500
2178
+ "minimum": -1000000,
2179
+ "maximum": 1000000
2158
2180
  },
2159
2181
  "rx": {
2160
2182
  "type": "number",
@@ -2300,7 +2322,7 @@
2300
2322
  },
2301
2323
  {
2302
2324
  "name": "insert_hex_prism",
2303
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2325
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2304
2326
  "args": {
2305
2327
  "type": "object",
2306
2328
  "additionalProperties": false,
@@ -2315,18 +2337,18 @@
2315
2337
  },
2316
2338
  "x": {
2317
2339
  "type": "number",
2318
- "minimum": -500,
2319
- "maximum": 500
2340
+ "minimum": -1000000,
2341
+ "maximum": 1000000
2320
2342
  },
2321
2343
  "y": {
2322
2344
  "type": "number",
2323
- "minimum": -500,
2324
- "maximum": 500
2345
+ "minimum": -1000000,
2346
+ "maximum": 1000000
2325
2347
  },
2326
2348
  "z": {
2327
2349
  "type": "number",
2328
- "minimum": -500,
2329
- "maximum": 500
2350
+ "minimum": -1000000,
2351
+ "maximum": 1000000
2330
2352
  },
2331
2353
  "rx": {
2332
2354
  "type": "number",
@@ -2465,7 +2487,7 @@
2465
2487
  },
2466
2488
  {
2467
2489
  "name": "insert_fillet_edges",
2468
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2490
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2469
2491
  "args": {
2470
2492
  "type": "object",
2471
2493
  "additionalProperties": false,
@@ -2607,7 +2629,7 @@
2607
2629
  },
2608
2630
  {
2609
2631
  "name": "insert_chamfer_edges",
2610
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2632
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2611
2633
  "args": {
2612
2634
  "type": "object",
2613
2635
  "additionalProperties": false,
@@ -2724,7 +2746,7 @@
2724
2746
  },
2725
2747
  {
2726
2748
  "name": "insert_cross_section",
2727
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2749
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2728
2750
  "args": {
2729
2751
  "type": "object",
2730
2752
  "additionalProperties": false,
@@ -2883,7 +2905,7 @@
2883
2905
  },
2884
2906
  {
2885
2907
  "name": "insert_sweep_path",
2886
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
2908
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
2887
2909
  "args": {
2888
2910
  "type": "object",
2889
2911
  "additionalProperties": false,
@@ -2999,7 +3021,7 @@
2999
3021
  },
3000
3022
  {
3001
3023
  "name": "insert_hole",
3002
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3024
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3003
3025
  "args": {
3004
3026
  "type": "object",
3005
3027
  "additionalProperties": false,
@@ -3232,7 +3254,7 @@
3232
3254
  },
3233
3255
  {
3234
3256
  "name": "insert_hole_pattern",
3235
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3257
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3236
3258
  "args": {
3237
3259
  "type": "object",
3238
3260
  "additionalProperties": false,
@@ -3369,7 +3391,7 @@
3369
3391
  },
3370
3392
  {
3371
3393
  "name": "insert_clearance_hole",
3372
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3394
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3373
3395
  "args": {
3374
3396
  "type": "object",
3375
3397
  "additionalProperties": false,
@@ -3512,7 +3534,7 @@
3512
3534
  },
3513
3535
  {
3514
3536
  "name": "insert_tap_drill_hole",
3515
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3537
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3516
3538
  "args": {
3517
3539
  "type": "object",
3518
3540
  "additionalProperties": false,
@@ -3646,7 +3668,7 @@
3646
3668
  },
3647
3669
  {
3648
3670
  "name": "insert_cbore_hole",
3649
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3671
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3650
3672
  "args": {
3651
3673
  "type": "object",
3652
3674
  "additionalProperties": false,
@@ -3781,7 +3803,7 @@
3781
3803
  },
3782
3804
  {
3783
3805
  "name": "insert_csk_hole",
3784
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3806
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3785
3807
  "args": {
3786
3808
  "type": "object",
3787
3809
  "additionalProperties": false,
@@ -3916,7 +3938,7 @@
3916
3938
  },
3917
3939
  {
3918
3940
  "name": "insert_shell",
3919
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
3941
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
3920
3942
  "args": {
3921
3943
  "type": "object",
3922
3944
  "additionalProperties": false,
@@ -4046,7 +4068,7 @@
4046
4068
  },
4047
4069
  {
4048
4070
  "name": "insert_cut",
4049
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4071
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4050
4072
  "args": {
4051
4073
  "type": "object",
4052
4074
  "additionalProperties": false,
@@ -4161,7 +4183,7 @@
4161
4183
  },
4162
4184
  {
4163
4185
  "name": "insert_boolean",
4164
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4186
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4165
4187
  "args": {
4166
4188
  "type": "object",
4167
4189
  "additionalProperties": false,
@@ -4285,29 +4307,51 @@
4285
4307
  },
4286
4308
  {
4287
4309
  "name": "insert_move",
4288
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4310
+ "description": "Prefer this over freehand set_script. Move one body of the active part by [dx, dy, dz]. Name the body: body_index or at from list_bodies, face or face_id from list_faces, or use_selection with a selected face. Nothing named and nothing selected is no_body; the origin is never assumed. Working copy only; git_save commits.",
4289
4311
  "args": {
4290
4312
  "type": "object",
4291
4313
  "additionalProperties": false,
4292
4314
  "properties": {
4315
+ "body_index": {
4316
+ "type": "integer",
4317
+ "minimum": 0,
4318
+ "description": "Body from list_bodies"
4319
+ },
4320
+ "at": {
4321
+ "type": "array",
4322
+ "items": {
4323
+ "type": "number"
4324
+ },
4325
+ "minItems": 3,
4326
+ "maxItems": 3,
4327
+ "description": "Body centroid [x, y, z] mm from list_bodies"
4328
+ },
4329
+ "face_id": {
4330
+ "type": "string",
4331
+ "description": "A list_faces id (f12) on the body to move"
4332
+ },
4333
+ "face": {
4334
+ "type": "object",
4335
+ "description": "A list_faces key { at, n, area } on the body to move"
4336
+ },
4293
4337
  "body": {
4294
4338
  "type": "string",
4295
4339
  "description": "Part script binding name"
4296
4340
  },
4297
4341
  "dx": {
4298
4342
  "type": "number",
4299
- "minimum": -1000,
4300
- "maximum": 1000
4343
+ "minimum": -1000000,
4344
+ "maximum": 1000000
4301
4345
  },
4302
4346
  "dy": {
4303
4347
  "type": "number",
4304
- "minimum": -1000,
4305
- "maximum": 1000
4348
+ "minimum": -1000000,
4349
+ "maximum": 1000000
4306
4350
  },
4307
4351
  "dz": {
4308
4352
  "type": "number",
4309
- "minimum": -1000,
4310
- "maximum": 1000
4353
+ "minimum": -1000000,
4354
+ "maximum": 1000000
4311
4355
  }
4312
4356
  }
4313
4357
  },
@@ -4398,6 +4442,9 @@
4398
4442
  },
4399
4443
  "errors": [
4400
4444
  "bad_args",
4445
+ "no_body",
4446
+ "no_mesh",
4447
+ "unknown_face",
4401
4448
  "insert_failed",
4402
4449
  "internal"
4403
4450
  ],
@@ -4418,7 +4465,7 @@
4418
4465
  },
4419
4466
  {
4420
4467
  "name": "insert_center",
4421
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4468
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4422
4469
  "args": {
4423
4470
  "type": "object",
4424
4471
  "additionalProperties": false,
@@ -4542,7 +4589,7 @@
4542
4589
  },
4543
4590
  {
4544
4591
  "name": "insert_align",
4545
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4592
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4546
4593
  "args": {
4547
4594
  "type": "object",
4548
4595
  "additionalProperties": false,
@@ -4654,7 +4701,7 @@
4654
4701
  },
4655
4702
  {
4656
4703
  "name": "insert_mirror",
4657
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4704
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4658
4705
  "args": {
4659
4706
  "type": "object",
4660
4707
  "additionalProperties": false,
@@ -4779,7 +4826,7 @@
4779
4826
  },
4780
4827
  {
4781
4828
  "name": "insert_array3_d",
4782
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
4829
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4783
4830
  "args": {
4784
4831
  "type": "object",
4785
4832
  "additionalProperties": false,
@@ -4955,7 +5002,7 @@
4955
5002
  },
4956
5003
  {
4957
5004
  "name": "insert_polar_array",
4958
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5005
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
4959
5006
  "args": {
4960
5007
  "type": "object",
4961
5008
  "additionalProperties": false,
@@ -5096,7 +5143,7 @@
5096
5143
  },
5097
5144
  {
5098
5145
  "name": "insert_add_draft",
5099
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5146
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5100
5147
  "args": {
5101
5148
  "type": "object",
5102
5149
  "additionalProperties": false,
@@ -5242,7 +5289,7 @@
5242
5289
  },
5243
5290
  {
5244
5291
  "name": "insert_workplane",
5245
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5292
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5246
5293
  "args": {
5247
5294
  "type": "object",
5248
5295
  "additionalProperties": false,
@@ -5347,7 +5394,7 @@
5347
5394
  },
5348
5395
  {
5349
5396
  "name": "insert_make_extrude",
5350
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5397
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5351
5398
  "args": {
5352
5399
  "type": "object",
5353
5400
  "additionalProperties": false,
@@ -5471,7 +5518,7 @@
5471
5518
  },
5472
5519
  {
5473
5520
  "name": "insert_make_revolve",
5474
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5521
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5475
5522
  "args": {
5476
5523
  "type": "object",
5477
5524
  "additionalProperties": false,
@@ -5595,7 +5642,7 @@
5595
5642
  },
5596
5643
  {
5597
5644
  "name": "insert_make_sweep",
5598
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5645
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5599
5646
  "args": {
5600
5647
  "type": "object",
5601
5648
  "additionalProperties": false,
@@ -5710,7 +5757,7 @@
5710
5757
  },
5711
5758
  {
5712
5759
  "name": "insert_make_loft",
5713
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5760
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5714
5761
  "args": {
5715
5762
  "type": "object",
5716
5763
  "additionalProperties": false,
@@ -5834,7 +5881,7 @@
5834
5881
  },
5835
5882
  {
5836
5883
  "name": "insert_move_face",
5837
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
5884
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5838
5885
  "args": {
5839
5886
  "type": "object",
5840
5887
  "additionalProperties": false,
@@ -5954,7 +6001,7 @@
5954
6001
  },
5955
6002
  {
5956
6003
  "name": "insert_delete_face",
5957
- "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Working copy only; git_save commits.",
6004
+ "description": "Prefer this over freehand set_script. Insert this helper on the active part (set_active_part first) and run it. Numbers are finite and within ±1000000 mm (positions and deltas included); NaN and Infinity are bad_args. Working copy only; git_save commits.",
5958
6005
  "args": {
5959
6006
  "type": "object",
5960
6007
  "additionalProperties": false,
@@ -6312,7 +6359,7 @@
6312
6359
  },
6313
6360
  {
6314
6361
  "name": "delete_feature",
6315
- "description": "Delete a feature block from the script.",
6362
+ "description": "Delete a feature block from the script and run the part through mutate, so the result status and errors are current and undo once restores the block. Deleting the feature that declares part while later code still uses it is confirm_required until confirm: true; the result then carries a warning.",
6316
6363
  "args": {
6317
6364
  "type": "object",
6318
6365
  "additionalProperties": false,
@@ -6324,6 +6371,10 @@
6324
6371
  "index": {
6325
6372
  "type": "number",
6326
6373
  "description": "Feature index from feature_tree"
6374
+ },
6375
+ "confirm": {
6376
+ "type": "boolean",
6377
+ "description": "Required true to delete the feature that declares part while later code still uses it"
6327
6378
  }
6328
6379
  }
6329
6380
  },
@@ -6415,6 +6466,8 @@
6415
6466
  "errors": [
6416
6467
  "unknown_feature",
6417
6468
  "bad_index",
6469
+ "bad_args",
6470
+ "confirm_required",
6418
6471
  "delete_failed",
6419
6472
  "no_write_part",
6420
6473
  "internal"
@@ -7236,7 +7289,7 @@
7236
7289
  },
7237
7290
  {
7238
7291
  "name": "camera_set",
7239
- "description": "Set camera from a named view or explicit pose.",
7292
+ "description": "Set camera from a named view or explicit pose. A named view frames the whole assembly as placed, or the selected part alone while a part body is highlighted (set_active_part, select_parts; select_clear returns to the assembly), so no camera_fit is needed after it. An explicit position + target takes an optional up (default [0, 0, 1]) and never rolls the view.",
7240
7293
  "args": {
7241
7294
  "type": "object",
7242
7295
  "additionalProperties": false,
@@ -7272,6 +7325,15 @@
7272
7325
  },
7273
7326
  "fov": {
7274
7327
  "type": "number"
7328
+ },
7329
+ "up": {
7330
+ "type": "array",
7331
+ "items": {
7332
+ "type": "number"
7333
+ },
7334
+ "minItems": 3,
7335
+ "maxItems": 3,
7336
+ "description": "Camera up vector for an explicit pose. Default [0, 0, 1] (Z-up); the view never rolls."
7275
7337
  }
7276
7338
  }
7277
7339
  },
@@ -11254,7 +11316,7 @@
11254
11316
  },
11255
11317
  {
11256
11318
  "name": "create_assembly",
11257
- "description": "Seed a blank local assembly. Single-flight per tab: overlapping calls return the same assemblyId. Optional name is a non-unique label. No git write. Returns { assemblyId, assemblyName, activeId, partCount }.",
11319
+ "description": "Seed a blank assembly with one empty part (no demo script, no seed cube: the first insert_* creates the body). Single-flight per tab: overlapping calls return the same assemblyId. Optional name is a non-unique label. No git write. Returns { assemblyId, assemblyName, activeId, partCount }.",
11258
11320
  "args": {
11259
11321
  "type": "object",
11260
11322
  "additionalProperties": false,
@@ -11283,7 +11345,7 @@
11283
11345
  },
11284
11346
  {
11285
11347
  "name": "create_part",
11286
- "description": "Add a part and make it the active part before returning. The result partId is a new opaque surf id, not the previously active part. When script is set, that script runs before the call returns (ok, errors, failures, status); a failed script still leaves the part. Agent calls default to the assembly origin; pass position [x,y,z] mm to place it. Working copy only: nothing reaches git without git_save.",
11348
+ "description": "Add a part and make it the active part before returning. The part starts empty (no seed cube): the first insert_* creates the body. The result partId is a new opaque surf id, not the previously active part. When script is set, that script runs before the call returns (ok, errors, failures, status); a failed script still leaves the part. Agent calls default to the assembly origin; pass position [x,y,z] mm to place it. Working copy only: nothing reaches git without git_save.",
11287
11349
  "args": {
11288
11350
  "type": "object",
11289
11351
  "additionalProperties": false,
@@ -11679,7 +11741,7 @@
11679
11741
  },
11680
11742
  {
11681
11743
  "name": "list_assemblies",
11682
- "description": "List vault assemblies as [{ id, name }]. id is an opaque surf id; name is a label, not a key. No path field. Git-only.",
11744
+ "description": "List the assemblies the Open picker shows as [{ id, name, open }]: saved v2 assemblies, the open working copy (also when it is not saved yet, or local), and on a legacy vault its name-only folders as { id: null, name, legacy: true }. id is an opaque surf id; name is a label, not a key. No path field.",
11683
11745
  "args": {
11684
11746
  "type": "object",
11685
11747
  "additionalProperties": false,
@@ -11690,7 +11752,6 @@
11690
11752
  "additionalProperties": true
11691
11753
  },
11692
11754
  "errors": [
11693
- "git_only",
11694
11755
  "git_blocked",
11695
11756
  "internal"
11696
11757
  ],
@@ -15557,7 +15618,7 @@
15557
15618
  },
15558
15619
  {
15559
15620
  "name": "git_upgrade_vault",
15560
- "description": "Upgrade a legacy (v1 folder-layout) vault to v2 in one commit of remote tip bytes, then Save a dirty working copy as a second commit under the same confirmation. Requires confirm: true. Never runs on load. Off by default in this build (upgrade_unavailable) until v2 open/save land; tests and the Vite dev server can opt in. On v2 returns already_upgraded. Success is a summary: status, commit SHAs, assemblyIds, counts, leftoverFiles paths, and warnings — not the full plan, file contents, meshes, partBindings paths, or rekey.scripts.",
15621
+ "description": "Upgrade a legacy (v1 folder-layout) vault to v2 in one commit of remote tip bytes, then Save a dirty working copy as a second commit under the same confirmation. Requires confirm: true. Never runs on load. On v2 returns already_upgraded. Success is a summary: status, commit SHAs, assemblyIds, counts, leftoverFiles paths, and warnings — not the full plan, file contents, meshes, partBindings paths, or rekey.scripts.",
15561
15622
  "args": {
15562
15623
  "type": "object",
15563
15624
  "additionalProperties": false,