@mhome/app-facade-protocol 1.157.0 → 1.158.0

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.
@@ -202,7 +202,7 @@ The following are contract declarations, not a current support inventory.
202
202
  | `/app/suggestion/handle` | `HandleInput`: ID, expected version, declared action | Canonical business result, also stored in the resolution |
203
203
  | `/app/suggestion/feedback` | `FeedbackInput`: ID, expected version, `DISMISS`, optional comment | Updated Suggestion summary on completed success |
204
204
  | `/app/suggestion/settings/get` | Empty input | `SuggestionSettings` |
205
- | `/app/suggestion/settings/save` | `SuggestionSettings`: explicit `enabled` boolean | Saved `SuggestionSettings` |
205
+ | `/app/suggestion/settings/save` | `SaveSettingsInput`: one or both of `enabled`, `intervalMinutes` | Complete saved `SuggestionSettings` |
206
206
 
207
207
  An explicit unknown or no-longer-retained run ID returns `NOT_FOUND`; it must not
208
208
  silently return an unrelated run. Lists are bounded and omit script bundles,
@@ -210,9 +210,18 @@ evidence and resolutions; detail reads return the saved complete content.
210
210
  Business errors/partial or unknown outcomes use the canonical Facade result;
211
211
  marking handling finished must not replace that result with `success`.
212
212
 
213
- Settings belong to the authorized Space. Absent storage defaults to `enabled: true`.
213
+ Settings belong to the authorized Space. Absent storage defaults to `enabled: true`
214
+ and `intervalMinutes: 360` (six hours). The interval is a positive integer number
215
+ of minutes, bounded by the shared unsigned 32-bit field. Save updates only supplied
216
+ fields at the backend; omitted fields retain their value, and empty changes or
217
+ null values are rejected. Existing enabled-only calls remain valid. Stored settings
218
+ from before interval configuration use the same six-hour default.
214
219
  The switch controls periodic generation only; explicit authorized generation remains
215
- available. The UI places it in the existing Agent Settings page. Turning it off
220
+ available. The UI places these controls in a separate Agent Suggestion Settings page.
221
+ Automatic intervals are measured from the previous admitted automatic start,
222
+ regardless of completion time or outcome. Explicit runs never reset that clock.
223
+ This is an interval, not a calendar schedule or a promise of an exact next start.
224
+ Turning it off
216
225
  prevents future periodic admissions; it does not delete results or replay/cancel
217
226
  an admitted run. Settings follow the Space migration/deletion boundary. This adds
218
227
  no per-Suggestion timer, follow-up task or separate scheduler per output type.
@@ -747,6 +747,36 @@
747
747
  "value": {
748
748
  "enabled": false
749
749
  }
750
+ },
751
+ {
752
+ "name": "partial settings update {'enabled': False}",
753
+ "type": "SaveSettingsInput",
754
+ "value": {
755
+ "enabled": false
756
+ }
757
+ },
758
+ {
759
+ "name": "partial settings update {'intervalMinutes': 60}",
760
+ "type": "SaveSettingsInput",
761
+ "value": {
762
+ "intervalMinutes": 60
763
+ }
764
+ },
765
+ {
766
+ "name": "partial settings update {'enabled': True, 'intervalMinutes': 360}",
767
+ "type": "SaveSettingsInput",
768
+ "value": {
769
+ "enabled": true,
770
+ "intervalMinutes": 360
771
+ }
772
+ },
773
+ {
774
+ "name": "stored interval",
775
+ "type": "SuggestionSettings",
776
+ "value": {
777
+ "enabled": false,
778
+ "intervalMinutes": 90
779
+ }
750
780
  }
751
781
  ],
752
782
  "invalid": [
@@ -1437,6 +1467,108 @@
1437
1467
  "updatedAt": 3000,
1438
1468
  "outcome": "unknown"
1439
1469
  }
1470
+ },
1471
+ {
1472
+ "name": "invalid settings update {}",
1473
+ "type": "SaveSettingsInput",
1474
+ "value": {}
1475
+ },
1476
+ {
1477
+ "name": "invalid settings update {'enabled': None}",
1478
+ "type": "SaveSettingsInput",
1479
+ "value": {
1480
+ "enabled": null
1481
+ }
1482
+ },
1483
+ {
1484
+ "name": "invalid settings update {'intervalMinutes': None}",
1485
+ "type": "SaveSettingsInput",
1486
+ "value": {
1487
+ "intervalMinutes": null
1488
+ }
1489
+ },
1490
+ {
1491
+ "name": "invalid settings update {'intervalMinutes': 0}",
1492
+ "type": "SaveSettingsInput",
1493
+ "value": {
1494
+ "intervalMinutes": 0
1495
+ }
1496
+ },
1497
+ {
1498
+ "name": "invalid settings update {'intervalMinutes': -1}",
1499
+ "type": "SaveSettingsInput",
1500
+ "value": {
1501
+ "intervalMinutes": -1
1502
+ }
1503
+ },
1504
+ {
1505
+ "name": "invalid settings update {'intervalMinutes': 1.5}",
1506
+ "type": "SaveSettingsInput",
1507
+ "value": {
1508
+ "intervalMinutes": 1.5
1509
+ }
1510
+ },
1511
+ {
1512
+ "name": "invalid settings update {'intervalMinutes': 4294967296}",
1513
+ "type": "SaveSettingsInput",
1514
+ "value": {
1515
+ "intervalMinutes": 4294967296
1516
+ }
1517
+ },
1518
+ {
1519
+ "name": "invalid settings update {'intervalMinutes': '360'}",
1520
+ "type": "SaveSettingsInput",
1521
+ "value": {
1522
+ "intervalMinutes": "360"
1523
+ }
1524
+ },
1525
+ {
1526
+ "name": "invalid settings update {'enabled': True, 'spaceId': 'other'}",
1527
+ "type": "SaveSettingsInput",
1528
+ "value": {
1529
+ "enabled": true,
1530
+ "spaceId": "other"
1531
+ }
1532
+ },
1533
+ {
1534
+ "name": "invalid stored interval 0",
1535
+ "type": "SuggestionSettings",
1536
+ "value": {
1537
+ "enabled": true,
1538
+ "intervalMinutes": 0
1539
+ }
1540
+ },
1541
+ {
1542
+ "name": "invalid stored interval -1",
1543
+ "type": "SuggestionSettings",
1544
+ "value": {
1545
+ "enabled": true,
1546
+ "intervalMinutes": -1
1547
+ }
1548
+ },
1549
+ {
1550
+ "name": "invalid stored interval 1.5",
1551
+ "type": "SuggestionSettings",
1552
+ "value": {
1553
+ "enabled": true,
1554
+ "intervalMinutes": 1.5
1555
+ }
1556
+ },
1557
+ {
1558
+ "name": "invalid stored interval 4294967296",
1559
+ "type": "SuggestionSettings",
1560
+ "value": {
1561
+ "enabled": true,
1562
+ "intervalMinutes": 4294967296
1563
+ }
1564
+ },
1565
+ {
1566
+ "name": "invalid stored interval None",
1567
+ "type": "SuggestionSettings",
1568
+ "value": {
1569
+ "enabled": true,
1570
+ "intervalMinutes": null
1571
+ }
1440
1572
  }
1441
1573
  ]
1442
1574
  }
@@ -4,7 +4,8 @@
4
4
  "tenantId": "tenant",
5
5
  "spaceId": "space",
6
6
  "settings": {
7
- "enabled": false
7
+ "enabled": false,
8
+ "intervalMinutes": 90
8
9
  }
9
10
  },
10
11
  {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.app-facade.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "callSchema": "schema/facade-call.v1.schema.json",
5
5
  "routing": "manifest/routing.v1.json",
6
6
  "routingSchema": "schema/routing.v1.schema.json",
@@ -1,5 +1,5 @@
1
1
  {
2
- "contractVersion": "1.157.0",
2
+ "contractVersion": "1.158.0",
3
3
  "operations": {
4
4
  "/app/agent/context/get": "spaceRead",
5
5
  "/app/agent/conversation/get": "spaceRead",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.host-provision.targets.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "contract": "contract/host-provisioning-v1.md",
5
5
  "localTargets": [
6
6
  "/local/host/provision/start",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.hub.targets.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "appTargets": [
5
5
  "/app/hub/get",
6
6
  "/app/hub/remove"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.pod.targets.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "contract": "contract/pod-commissioning-v1.md",
5
5
  "localTargets": [
6
6
  "/local/pod/discovery/start",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.app-facade.routing.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "targetPrefix": "/app/",
5
5
  "default": {
6
6
  "execution": "spaceMode"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "manifest": "mhome.messaging.targets.v1",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "requestTargets": [
5
5
  "/app/messaging/provider/list",
6
6
  "/app/messaging/provider-account/list",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mhome/app-facade-protocol",
3
- "version": "1.157.0",
3
+ "version": "1.158.0",
4
4
  "description": "Build-time protocol artifacts for mhome.app-facade",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
package/protocol.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "protocol": "mhome.app-facade",
3
- "contractVersion": "1.157.0",
3
+ "contractVersion": "1.158.0",
4
4
  "manifest": "manifest/app-facade.v1.json",
5
5
  "schemas": {
6
6
  "dashboardCardAuthoring": "schema/dashboard-card-authoring.v1.schema.json",
@@ -1340,12 +1340,33 @@
1340
1340
  "enabled": {
1341
1341
  "type": "boolean",
1342
1342
  "default": true
1343
+ },
1344
+ "intervalMinutes": {
1345
+ "type": "integer",
1346
+ "minimum": 1,
1347
+ "maximum": 4294967295,
1348
+ "default": 360
1343
1349
  }
1344
1350
  },
1345
1351
  "required": [
1346
1352
  "enabled"
1347
1353
  ],
1348
1354
  "additionalProperties": false
1355
+ },
1356
+ "SaveSettingsInput": {
1357
+ "type": "object",
1358
+ "properties": {
1359
+ "enabled": {
1360
+ "type": "boolean"
1361
+ },
1362
+ "intervalMinutes": {
1363
+ "type": "integer",
1364
+ "minimum": 1,
1365
+ "maximum": 4294967295
1366
+ }
1367
+ },
1368
+ "minProperties": 1,
1369
+ "additionalProperties": false
1349
1370
  }
1350
1371
  }
1351
1372
  }