@mhome/app-facade-protocol 1.191.0 → 1.192.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.
- package/contract/entity-v1.md +7 -2
- package/contract/groups-v1.md +6 -0
- package/contract/reference-presentation-v1.md +6 -2
- package/contract/resource-read-failures-v1.md +2 -2
- package/contract/resource-read-v1.md +5 -0
- package/fixtures/group.conformance.json +97 -0
- package/fixtures/presentation/cases.json +82 -0
- package/manifest/app-facade.v1.json +1 -1
- package/manifest/authorization.v1.json +1 -1
- package/manifest/host-provision-targets.v1.json +1 -1
- package/manifest/hub-targets.v1.json +1 -1
- package/manifest/pod-targets.v1.json +1 -1
- package/manifest/routing.v1.json +1 -1
- package/manifest/targets.v1.json +1 -1
- package/package.json +1 -1
- package/protocol.json +1 -1
- package/schema/group.v1.schema.json +8 -0
package/contract/entity-v1.md
CHANGED
|
@@ -27,8 +27,13 @@ built-in Entity types; other types are Integration-defined.
|
|
|
27
27
|
`found: false, reason: "not_found"` and omit resource. No observations is not missing.
|
|
28
28
|
- `/app/entity/history/list` remains independent and returns all retained matching records, with optional explicit time bounds.
|
|
29
29
|
|
|
30
|
-
Metadata contains id, name, entityType, integration?, connectId?, active, capabilities, data,
|
|
30
|
+
Metadata contains id, name, entityType, integration?, connectId?, active, capabilities, visibleCapabilities, data,
|
|
31
31
|
tags (Blueprint IDs), availabilityStatus?, issue, group and entityIds (Group members).
|
|
32
|
+
`capabilities` retains the complete callable set; `visibleCapabilities` is the
|
|
33
|
+
default UI/Agent discovery set after author-declared shadow rules. Both use the
|
|
34
|
+
same capability-part notation. Explicit calls may still use a shadowed capability.
|
|
35
|
+
An empty visible list is authoritative; an omitted list means its projection is
|
|
36
|
+
unknown and must not fall back to the complete set. No caller recomputes shadow.
|
|
32
37
|
It contains no current capability values. Full retains the complete metadata.
|
|
33
38
|
Essential omits Blueprint tags, ordinary entityIds, absent optional values and
|
|
34
39
|
redundant built-in data identity fields. It preserves arbitrary Integration data,
|
|
@@ -60,7 +65,7 @@ Source synchronization remains `/app/integration/entity/refresh`; onboarding rea
|
|
|
60
65
|
standard Device metadata only after an explicitly successful synchronization.
|
|
61
66
|
|
|
62
67
|
General Entity list/detail and reference candidates retain Group definitions when
|
|
63
|
-
optional projection fails. `capabilities`, `tags`, `active` and `issue` are omitted
|
|
68
|
+
optional projection fails. `capabilities`, `visibleCapabilities`, `tags`, `active` and `issue` are omitted
|
|
64
69
|
when unknown, with `problem`; confirmed empty/false values remain valid. Selected
|
|
65
70
|
definition failures are unavailable items. Selected reference-name reads preserve
|
|
66
71
|
the same ID order and diagnostics. See [independent reads](resource-read-failures-v1.md).
|
package/contract/groups-v1.md
CHANGED
|
@@ -48,3 +48,9 @@ baseline policy. No startup conversion or automatic deletion is performed.
|
|
|
48
48
|
Selected definition failures carry `reason: unavailable` and an ID-scoped `problem`.
|
|
49
49
|
Member projection failures retain the definition, omit unknown derived fields and
|
|
50
50
|
carry `problem`. Outcomes follow [independent resource reads](resource-read-failures-v1.md).
|
|
51
|
+
|
|
52
|
+
Group detail keeps the complete callable `capabilities` entries with member counts.
|
|
53
|
+
`visibleCapabilities` contains full capability IDs for default UI/Agent choices,
|
|
54
|
+
derived from the same ready, revision-matched Twin projection and intersected with
|
|
55
|
+
current callable support. Both are omitted when the projection cannot be read;
|
|
56
|
+
an empty visible list is a confirmed result. Shadow changes presentation only.
|
|
@@ -8,12 +8,16 @@ Essential represents them as YAML.
|
|
|
8
8
|
| Target | Input | Business output |
|
|
9
9
|
| --- | --- | --- |
|
|
10
10
|
| `/app/presentation/reference/type/list` | `{}` | `{types:[{entityType,name,category}]}` |
|
|
11
|
-
| `/app/presentation/reference/item/list` | `{entityType}` | `{items:[{id,name,entityType,category,capabilities,
|
|
11
|
+
| `/app/presentation/reference/item/list` | `{entityType}` | `{items:[{id,name,entityType,category,capabilities?,visibleCapabilities?,group,problem?}]}` |
|
|
12
12
|
|
|
13
13
|
Inputs reject unknown fields. entityType is a nonblank string, trimmed at the
|
|
14
14
|
boundary. category is device, widget, automation or entity, derived by the server.
|
|
15
15
|
Candidate names do not replace IDs. Empty capabilities and false group values are
|
|
16
|
-
preserved.
|
|
16
|
+
preserved. `visibleCapabilities` carries the default discovery projection;
|
|
17
|
+
`capabilities` retains shadowed callable support. Empty visibility is authoritative;
|
|
18
|
+
omitted visibility is unknown and must not fall back to full support. Group
|
|
19
|
+
projection failures retain identity and `problem` while omitting unknown lists.
|
|
20
|
+
No business input selects another Space.
|
|
17
21
|
|
|
18
22
|
Types come from installed and auto-installed Integration standalone declarations,
|
|
19
23
|
deduplicated and sorted by entityType. Empty types are not hidden by counting their
|
|
@@ -40,7 +40,7 @@ retry is introduced. Required evidence for a dependent mutation remains required
|
|
|
40
40
|
## Current entrypoints
|
|
41
41
|
|
|
42
42
|
- Device list and detail retain Group definitions when their member/Twin
|
|
43
|
-
projection fails; the Group's capabilities and Blueprint IDs remain unknown.
|
|
43
|
+
projection fails; the Group's capabilities, visible capabilities and Blueprint IDs remain unknown.
|
|
44
44
|
- Automation detail uses `items: [{requestedId, found, reason?, automation?,
|
|
45
45
|
problem?}]`, not an uncorrelated automations array. The list endpoint retains
|
|
46
46
|
its automations summaries array. Automation definitions use the entire Automation
|
|
@@ -58,7 +58,7 @@ retry is introduced. Required evidence for a dependent mutation remains required
|
|
|
58
58
|
the caller's requestedId in diagnostics.
|
|
59
59
|
|
|
60
60
|
- Group detail, general Entity list/detail and reference candidates retain known
|
|
61
|
-
definitions when member/runtime projection fails; unknown capabilities, tags,
|
|
61
|
+
definitions when member/runtime projection fails; unknown capabilities, visible capabilities, tags,
|
|
62
62
|
active and issue are omitted. Selected Group definition/name failures use
|
|
63
63
|
unavailable items, never not_found.
|
|
64
64
|
- Integration batch detail completes mandatory shared context reads before
|
|
@@ -29,6 +29,11 @@ Twin lookup; `ready` confirms application, not member reachability. Group diagno
|
|
|
29
29
|
and application errors are available through Group detail. Device enable/disable
|
|
30
30
|
accepts physical IDs only. This does not add Group enablement or alter lifecycle writes.
|
|
31
31
|
|
|
32
|
+
Device discovery keeps full callable `capabilities` and separate default
|
|
33
|
+
`visibleCapabilities` after schema shadow. Empty visibility is authoritative;
|
|
34
|
+
unknown projections omit it without falling back to full support. Both Full and
|
|
35
|
+
Essential preserve this distinction. See [Entity discovery](entity-v1.md).
|
|
36
|
+
|
|
32
37
|
See [Device lifecycle outcomes](device-lifecycle-v1.md) for batch writes and retry behavior.
|
|
33
38
|
|
|
34
39
|
Observation batches accept one or more IDs, reject blanks, trim and deduplicate preserving
|
|
@@ -317,6 +317,70 @@
|
|
|
317
317
|
"a"
|
|
318
318
|
]
|
|
319
319
|
}
|
|
320
|
+
},
|
|
321
|
+
{
|
|
322
|
+
"definition": "GroupDetail",
|
|
323
|
+
"value": {
|
|
324
|
+
"groupId": "g:11111111-1111-4111-8111-111111111111",
|
|
325
|
+
"name": "Lights",
|
|
326
|
+
"entityType": "basic.device.Device",
|
|
327
|
+
"memberCount": 2,
|
|
328
|
+
"revision": 3,
|
|
329
|
+
"applyState": "ready",
|
|
330
|
+
"createdAt": 1900000000000,
|
|
331
|
+
"updatedAt": 1900000001000,
|
|
332
|
+
"entityIds": [
|
|
333
|
+
"lamp-a",
|
|
334
|
+
"lamp-b"
|
|
335
|
+
],
|
|
336
|
+
"capabilities": [
|
|
337
|
+
{
|
|
338
|
+
"id": "basic.device.command.onOff",
|
|
339
|
+
"memberCount": 1
|
|
340
|
+
}
|
|
341
|
+
],
|
|
342
|
+
"memberProblems": [
|
|
343
|
+
{
|
|
344
|
+
"entityId": "lamp-b",
|
|
345
|
+
"code": "MEMBER_UNAVAILABLE",
|
|
346
|
+
"message": "Member is unavailable"
|
|
347
|
+
}
|
|
348
|
+
],
|
|
349
|
+
"visibleCapabilities": []
|
|
350
|
+
}
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
"definition": "GroupDetail",
|
|
354
|
+
"value": {
|
|
355
|
+
"groupId": "g:11111111-1111-4111-8111-111111111111",
|
|
356
|
+
"name": "Lights",
|
|
357
|
+
"entityType": "basic.device.Device",
|
|
358
|
+
"memberCount": 2,
|
|
359
|
+
"revision": 3,
|
|
360
|
+
"applyState": "ready",
|
|
361
|
+
"createdAt": 1900000000000,
|
|
362
|
+
"updatedAt": 1900000001000,
|
|
363
|
+
"entityIds": [
|
|
364
|
+
"lamp-a",
|
|
365
|
+
"lamp-b"
|
|
366
|
+
],
|
|
367
|
+
"capabilities": [
|
|
368
|
+
{
|
|
369
|
+
"id": "basic.device.command.onOff",
|
|
370
|
+
"memberCount": 1
|
|
371
|
+
}
|
|
372
|
+
],
|
|
373
|
+
"memberProblems": [
|
|
374
|
+
{
|
|
375
|
+
"entityId": "lamp-b",
|
|
376
|
+
"code": "MEMBER_UNAVAILABLE",
|
|
377
|
+
"message": "Member is unavailable"
|
|
378
|
+
}
|
|
379
|
+
],
|
|
380
|
+
"visibleCapabilities": [
|
|
381
|
+
"basic.device.command.onOff"
|
|
382
|
+
]
|
|
383
|
+
}
|
|
320
384
|
}
|
|
321
385
|
],
|
|
322
386
|
"invalid": [
|
|
@@ -422,6 +486,39 @@
|
|
|
422
486
|
],
|
|
423
487
|
"expectedRevision": 1
|
|
424
488
|
}
|
|
489
|
+
},
|
|
490
|
+
{
|
|
491
|
+
"definition": "GroupDetail",
|
|
492
|
+
"value": {
|
|
493
|
+
"groupId": "g:11111111-1111-4111-8111-111111111111",
|
|
494
|
+
"name": "Lights",
|
|
495
|
+
"entityType": "basic.device.Device",
|
|
496
|
+
"memberCount": 2,
|
|
497
|
+
"revision": 3,
|
|
498
|
+
"applyState": "ready",
|
|
499
|
+
"createdAt": 1900000000000,
|
|
500
|
+
"updatedAt": 1900000001000,
|
|
501
|
+
"entityIds": [
|
|
502
|
+
"lamp-a",
|
|
503
|
+
"lamp-b"
|
|
504
|
+
],
|
|
505
|
+
"capabilities": [
|
|
506
|
+
{
|
|
507
|
+
"id": "basic.device.command.onOff",
|
|
508
|
+
"memberCount": 1
|
|
509
|
+
}
|
|
510
|
+
],
|
|
511
|
+
"memberProblems": [
|
|
512
|
+
{
|
|
513
|
+
"entityId": "lamp-b",
|
|
514
|
+
"code": "MEMBER_UNAVAILABLE",
|
|
515
|
+
"message": "Member is unavailable"
|
|
516
|
+
}
|
|
517
|
+
],
|
|
518
|
+
"visibleCapabilities": [
|
|
519
|
+
false
|
|
520
|
+
]
|
|
521
|
+
}
|
|
425
522
|
}
|
|
426
523
|
]
|
|
427
524
|
}
|
|
@@ -7070,5 +7070,87 @@
|
|
|
7070
7070
|
"accepted": true,
|
|
7071
7071
|
"stateStatus": "unknown"
|
|
7072
7072
|
}
|
|
7073
|
+
},
|
|
7074
|
+
{
|
|
7075
|
+
"name": "device-shadow-enhanced",
|
|
7076
|
+
"target": "/app/device/list",
|
|
7077
|
+
"status": "success",
|
|
7078
|
+
"data": {
|
|
7079
|
+
"devices": [
|
|
7080
|
+
{
|
|
7081
|
+
"entityId": "camera",
|
|
7082
|
+
"name": "Door",
|
|
7083
|
+
"group": false,
|
|
7084
|
+
"active": true,
|
|
7085
|
+
"lifecycle": "enabled",
|
|
7086
|
+
"integration": "mlinkMatter.device",
|
|
7087
|
+
"capabilities": [
|
|
7088
|
+
"command.captureSnapshots",
|
|
7089
|
+
"command.cameraSnapshots"
|
|
7090
|
+
],
|
|
7091
|
+
"visibleCapabilities": [
|
|
7092
|
+
"command.cameraSnapshots"
|
|
7093
|
+
]
|
|
7094
|
+
}
|
|
7095
|
+
]
|
|
7096
|
+
},
|
|
7097
|
+
"essential": {
|
|
7098
|
+
"devices": [
|
|
7099
|
+
{
|
|
7100
|
+
"entityId": "camera",
|
|
7101
|
+
"name": "Door",
|
|
7102
|
+
"group": false,
|
|
7103
|
+
"active": true,
|
|
7104
|
+
"lifecycle": "enabled",
|
|
7105
|
+
"integration": "mlinkMatter.device",
|
|
7106
|
+
"capabilities": [
|
|
7107
|
+
"command.captureSnapshots",
|
|
7108
|
+
"command.cameraSnapshots"
|
|
7109
|
+
],
|
|
7110
|
+
"visibleCapabilities": [
|
|
7111
|
+
"command.cameraSnapshots"
|
|
7112
|
+
]
|
|
7113
|
+
}
|
|
7114
|
+
]
|
|
7115
|
+
}
|
|
7116
|
+
},
|
|
7117
|
+
{
|
|
7118
|
+
"name": "device-shadow-empty",
|
|
7119
|
+
"target": "/app/device/list",
|
|
7120
|
+
"status": "success",
|
|
7121
|
+
"data": {
|
|
7122
|
+
"devices": [
|
|
7123
|
+
{
|
|
7124
|
+
"entityId": "camera",
|
|
7125
|
+
"name": "Door",
|
|
7126
|
+
"group": false,
|
|
7127
|
+
"active": true,
|
|
7128
|
+
"lifecycle": "enabled",
|
|
7129
|
+
"integration": "mlinkMatter.device",
|
|
7130
|
+
"capabilities": [
|
|
7131
|
+
"command.captureSnapshots",
|
|
7132
|
+
"command.cameraSnapshots"
|
|
7133
|
+
],
|
|
7134
|
+
"visibleCapabilities": []
|
|
7135
|
+
}
|
|
7136
|
+
]
|
|
7137
|
+
},
|
|
7138
|
+
"essential": {
|
|
7139
|
+
"devices": [
|
|
7140
|
+
{
|
|
7141
|
+
"entityId": "camera",
|
|
7142
|
+
"name": "Door",
|
|
7143
|
+
"group": false,
|
|
7144
|
+
"active": true,
|
|
7145
|
+
"lifecycle": "enabled",
|
|
7146
|
+
"integration": "mlinkMatter.device",
|
|
7147
|
+
"capabilities": [
|
|
7148
|
+
"command.captureSnapshots",
|
|
7149
|
+
"command.cameraSnapshots"
|
|
7150
|
+
],
|
|
7151
|
+
"visibleCapabilities": []
|
|
7152
|
+
}
|
|
7153
|
+
]
|
|
7154
|
+
}
|
|
7073
7155
|
}
|
|
7074
7156
|
]
|
package/manifest/routing.v1.json
CHANGED
package/manifest/targets.v1.json
CHANGED
package/package.json
CHANGED
package/protocol.json
CHANGED