@mhome/app-facade-protocol 1.5.0 → 1.7.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/README.md +13 -0
- package/fixtures/device-topology.partial.json +111 -0
- package/fixtures/device-topology.snapshot.json +172 -0
- package/manifest/app-facade.v1.json +11 -1
- package/manifest/routing.v1.json +2 -1
- package/manifest/targets.v1.json +1 -1
- package/package.json +1 -1
- package/protocol.json +3 -2
- package/schema/device-topology.v1.schema.json +309 -0
- package/schema/topology.v1.schema.json +1 -1
package/README.md
CHANGED
|
@@ -34,6 +34,19 @@ sessions. Durable relations remain present while disconnected and carry an
|
|
|
34
34
|
explicit observation state so clients can distinguish expected topology from
|
|
35
35
|
the currently observed path.
|
|
36
36
|
|
|
37
|
+
`device_topology` exposes the Scope-owned Device Integration relationship graph.
|
|
38
|
+
Device Integration, Provider, Connection, Plugin Instance, source device, and
|
|
39
|
+
Device identities are independent vertices joined by typed edges. Edge direction
|
|
40
|
+
only describes relation semantics: the graph does not require a fixed layer order,
|
|
41
|
+
a single parent, containment, or acyclicity. Durable relations remain present
|
|
42
|
+
while unavailable, and partial snapshots preserve confirmed structure when one
|
|
43
|
+
source cannot be observed.
|
|
44
|
+
|
|
45
|
+
`artifact` exposes the MeowLink-facing `/app/artifact/resolve` operation. Its
|
|
46
|
+
domain input and output reuse `mhome-artifact-api`; Node runtimes use the
|
|
47
|
+
separate transport-neutral `/artifact/*` targets and never enter the App
|
|
48
|
+
Facade.
|
|
49
|
+
|
|
37
50
|
## Routing contract
|
|
38
51
|
|
|
39
52
|
`manifest/routing.v1.json` is the canonical client-side routing policy for the
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
{
|
|
2
|
+
"contract": "mhome.device.topology.v1",
|
|
3
|
+
"scopeId": "space-1",
|
|
4
|
+
"generation": "generation-1",
|
|
5
|
+
"revision": 8,
|
|
6
|
+
"observedAtMs": 1777777778000,
|
|
7
|
+
"completeness": "partial",
|
|
8
|
+
"issues": [
|
|
9
|
+
{
|
|
10
|
+
"code": "matterUnavailable",
|
|
11
|
+
"message": "Matter device details are temporarily unavailable",
|
|
12
|
+
"entityId": "connection:mlinkMatter.device:matter-1"
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"entities": [
|
|
16
|
+
{
|
|
17
|
+
"kind": "deviceIntegration",
|
|
18
|
+
"id": "integration:basic.device",
|
|
19
|
+
"integrationId": "basic.device",
|
|
20
|
+
"displayName": "Devices"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"kind": "provider",
|
|
24
|
+
"id": "provider:mlinkMatter.device",
|
|
25
|
+
"integrationId": "mlinkMatter.device",
|
|
26
|
+
"displayName": "Matter",
|
|
27
|
+
"mode": "local",
|
|
28
|
+
"multiConnect": false
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"kind": "connection",
|
|
32
|
+
"id": "connection:mlinkMatter.device:matter-1",
|
|
33
|
+
"integrationId": "mlinkMatter.device",
|
|
34
|
+
"connectionId": "matter-1",
|
|
35
|
+
"displayName": "Living Room Mac",
|
|
36
|
+
"runtime": {
|
|
37
|
+
"state": "offline",
|
|
38
|
+
"reason": "Service unavailable",
|
|
39
|
+
"updatedAtMs": 1777777778000
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"kind": "pluginInstance",
|
|
44
|
+
"id": "plugin:matter-1",
|
|
45
|
+
"nodeId": "matter-1",
|
|
46
|
+
"nodeType": "matter",
|
|
47
|
+
"hostId": "host-1",
|
|
48
|
+
"serviceInstanceId": "service-1",
|
|
49
|
+
"displayName": "Matter Service",
|
|
50
|
+
"hostDisplayName": "Living Room Mac",
|
|
51
|
+
"runtime": {
|
|
52
|
+
"state": "offline",
|
|
53
|
+
"reason": "Service unavailable",
|
|
54
|
+
"updatedAtMs": 1777777778000
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
],
|
|
58
|
+
"edges": [
|
|
59
|
+
{
|
|
60
|
+
"id": "edge:integration-provider",
|
|
61
|
+
"source": "integration:basic.device",
|
|
62
|
+
"target": "provider:mlinkMatter.device",
|
|
63
|
+
"relation": "integration-provider",
|
|
64
|
+
"basis": "integrationInstall",
|
|
65
|
+
"durability": "durable",
|
|
66
|
+
"observation": {
|
|
67
|
+
"state": "connected",
|
|
68
|
+
"observedAtMs": 1777777778000
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"id": "edge:provider-connection",
|
|
73
|
+
"source": "provider:mlinkMatter.device",
|
|
74
|
+
"target": "connection:mlinkMatter.device:matter-1",
|
|
75
|
+
"relation": "provider-connection",
|
|
76
|
+
"basis": "connectionOwnership",
|
|
77
|
+
"durability": "durable",
|
|
78
|
+
"observation": {
|
|
79
|
+
"state": "disconnected",
|
|
80
|
+
"observedAtMs": 1777777778000,
|
|
81
|
+
"reason": "Service unavailable"
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"id": "edge:plugin-provider",
|
|
86
|
+
"source": "plugin:matter-1",
|
|
87
|
+
"target": "provider:mlinkMatter.device",
|
|
88
|
+
"relation": "plugin-provider",
|
|
89
|
+
"basis": "pluginBinding",
|
|
90
|
+
"durability": "durable",
|
|
91
|
+
"observation": {
|
|
92
|
+
"state": "disconnected",
|
|
93
|
+
"observedAtMs": 1777777778000,
|
|
94
|
+
"reason": "Service unavailable"
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"id": "edge:plugin-connection",
|
|
99
|
+
"source": "plugin:matter-1",
|
|
100
|
+
"target": "connection:mlinkMatter.device:matter-1",
|
|
101
|
+
"relation": "plugin-connection",
|
|
102
|
+
"basis": "pluginBinding",
|
|
103
|
+
"durability": "durable",
|
|
104
|
+
"observation": {
|
|
105
|
+
"state": "disconnected",
|
|
106
|
+
"observedAtMs": 1777777778000,
|
|
107
|
+
"reason": "Service unavailable"
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
]
|
|
111
|
+
}
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
{
|
|
2
|
+
"contract": "mhome.device.topology.v1",
|
|
3
|
+
"scopeId": "space-1",
|
|
4
|
+
"generation": "generation-1",
|
|
5
|
+
"revision": 7,
|
|
6
|
+
"observedAtMs": 1777777777000,
|
|
7
|
+
"completeness": "complete",
|
|
8
|
+
"issues": [],
|
|
9
|
+
"entities": [
|
|
10
|
+
{
|
|
11
|
+
"kind": "deviceIntegration",
|
|
12
|
+
"id": "integration:basic.device",
|
|
13
|
+
"integrationId": "basic.device",
|
|
14
|
+
"displayName": "Devices"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"kind": "provider",
|
|
18
|
+
"id": "provider:mlinkMatter.device",
|
|
19
|
+
"integrationId": "mlinkMatter.device",
|
|
20
|
+
"displayName": "Matter",
|
|
21
|
+
"mode": "local",
|
|
22
|
+
"multiConnect": false
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"kind": "connection",
|
|
26
|
+
"id": "connection:mlinkMatter.device:matter-1",
|
|
27
|
+
"integrationId": "mlinkMatter.device",
|
|
28
|
+
"connectionId": "matter-1",
|
|
29
|
+
"displayName": "Living Room Mac",
|
|
30
|
+
"runtime": {
|
|
31
|
+
"state": "healthy",
|
|
32
|
+
"updatedAtMs": 1777777777000
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"kind": "pluginInstance",
|
|
37
|
+
"id": "plugin:matter-1",
|
|
38
|
+
"nodeId": "matter-1",
|
|
39
|
+
"nodeType": "matter",
|
|
40
|
+
"hostId": "host-1",
|
|
41
|
+
"serviceInstanceId": "service-1",
|
|
42
|
+
"displayName": "Matter Service",
|
|
43
|
+
"hostDisplayName": "Living Room Mac",
|
|
44
|
+
"runtime": {
|
|
45
|
+
"state": "healthy",
|
|
46
|
+
"updatedAtMs": 1777777777000
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"kind": "sourceDevice",
|
|
51
|
+
"id": "source:matter:node-123",
|
|
52
|
+
"sourceType": "matter",
|
|
53
|
+
"sourceId": "node-123",
|
|
54
|
+
"displayName": "Aqara Matter Bridge",
|
|
55
|
+
"role": "bridge",
|
|
56
|
+
"runtime": {
|
|
57
|
+
"state": "healthy",
|
|
58
|
+
"updatedAtMs": 1777777777000
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"kind": "device",
|
|
63
|
+
"id": "device:desk-light",
|
|
64
|
+
"entityId": "desk-light",
|
|
65
|
+
"integrationId": "mlinkMatter.device",
|
|
66
|
+
"displayName": "Desk Light",
|
|
67
|
+
"enabled": true,
|
|
68
|
+
"runtime": {
|
|
69
|
+
"state": "healthy",
|
|
70
|
+
"updatedAtMs": 1777777777000
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
],
|
|
74
|
+
"edges": [
|
|
75
|
+
{
|
|
76
|
+
"id": "edge:integration-provider",
|
|
77
|
+
"source": "integration:basic.device",
|
|
78
|
+
"target": "provider:mlinkMatter.device",
|
|
79
|
+
"relation": "integration-provider",
|
|
80
|
+
"basis": "integrationInstall",
|
|
81
|
+
"durability": "durable",
|
|
82
|
+
"observation": {
|
|
83
|
+
"state": "connected",
|
|
84
|
+
"observedAtMs": 1777777777000
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"id": "edge:plugin-provider",
|
|
89
|
+
"source": "plugin:matter-1",
|
|
90
|
+
"target": "provider:mlinkMatter.device",
|
|
91
|
+
"relation": "plugin-provider",
|
|
92
|
+
"basis": "pluginBinding",
|
|
93
|
+
"durability": "durable",
|
|
94
|
+
"observation": {
|
|
95
|
+
"state": "connected",
|
|
96
|
+
"observedAtMs": 1777777777000
|
|
97
|
+
}
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
"id": "edge:plugin-connection",
|
|
101
|
+
"source": "plugin:matter-1",
|
|
102
|
+
"target": "connection:mlinkMatter.device:matter-1",
|
|
103
|
+
"relation": "plugin-connection",
|
|
104
|
+
"basis": "pluginBinding",
|
|
105
|
+
"durability": "durable",
|
|
106
|
+
"observation": {
|
|
107
|
+
"state": "connected",
|
|
108
|
+
"observedAtMs": 1777777777000
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
"id": "edge:provider-connection",
|
|
113
|
+
"source": "provider:mlinkMatter.device",
|
|
114
|
+
"target": "connection:mlinkMatter.device:matter-1",
|
|
115
|
+
"relation": "provider-connection",
|
|
116
|
+
"basis": "connectionOwnership",
|
|
117
|
+
"durability": "durable",
|
|
118
|
+
"observation": {
|
|
119
|
+
"state": "connected",
|
|
120
|
+
"observedAtMs": 1777777777000
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"id": "edge:connection-source",
|
|
125
|
+
"source": "connection:mlinkMatter.device:matter-1",
|
|
126
|
+
"target": "source:matter:node-123",
|
|
127
|
+
"relation": "connection-source",
|
|
128
|
+
"basis": "sourceProjection",
|
|
129
|
+
"durability": "durable",
|
|
130
|
+
"observation": {
|
|
131
|
+
"state": "connected",
|
|
132
|
+
"observedAtMs": 1777777777000
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
"id": "edge:source-device",
|
|
137
|
+
"source": "source:matter:node-123",
|
|
138
|
+
"target": "device:desk-light",
|
|
139
|
+
"relation": "source-device",
|
|
140
|
+
"basis": "sourceProjection",
|
|
141
|
+
"durability": "durable",
|
|
142
|
+
"observation": {
|
|
143
|
+
"state": "connected",
|
|
144
|
+
"observedAtMs": 1777777777000
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
"id": "edge:provider-device",
|
|
149
|
+
"source": "provider:mlinkMatter.device",
|
|
150
|
+
"target": "device:desk-light",
|
|
151
|
+
"relation": "provider-device",
|
|
152
|
+
"basis": "twinSource",
|
|
153
|
+
"durability": "durable",
|
|
154
|
+
"observation": {
|
|
155
|
+
"state": "connected",
|
|
156
|
+
"observedAtMs": 1777777777000
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
"id": "edge:connection-device",
|
|
161
|
+
"source": "connection:mlinkMatter.device:matter-1",
|
|
162
|
+
"target": "device:desk-light",
|
|
163
|
+
"relation": "connection-device",
|
|
164
|
+
"basis": "twinSource",
|
|
165
|
+
"durability": "durable",
|
|
166
|
+
"observation": {
|
|
167
|
+
"state": "connected",
|
|
168
|
+
"observedAtMs": 1777777777000
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
]
|
|
172
|
+
}
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"manifest": "mhome.app-facade.v1",
|
|
3
|
-
"contractVersion": "1.
|
|
3
|
+
"contractVersion": "1.7.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",
|
|
7
7
|
"domains": {
|
|
8
|
+
"artifact": {
|
|
9
|
+
"contract": "mhome.artifact.v1",
|
|
10
|
+
"requestTargets": ["/app/artifact/resolve"]
|
|
11
|
+
},
|
|
8
12
|
"hub": {
|
|
9
13
|
"targets": "manifest/hub-targets.v1.json",
|
|
10
14
|
"cloudStateTarget": "/app/hub/get",
|
|
@@ -42,6 +46,12 @@
|
|
|
42
46
|
"requestTargets": ["/app/topology/get"],
|
|
43
47
|
"eventTargets": ["/app/topology/changed"]
|
|
44
48
|
},
|
|
49
|
+
"deviceTopology": {
|
|
50
|
+
"contract": "mhome.device.topology.v1",
|
|
51
|
+
"schema": "schema/device-topology.v1.schema.json",
|
|
52
|
+
"requestTargets": ["/app/device/topology/get"],
|
|
53
|
+
"eventTargets": ["/app/device/topology/changed"]
|
|
54
|
+
},
|
|
45
55
|
"interactionFlow": {
|
|
46
56
|
"schema": "schema/interaction-flow-app.v1.schema.json",
|
|
47
57
|
"requestTargets": [
|
package/manifest/routing.v1.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"manifest": "mhome.app-facade.routing.v1",
|
|
3
|
-
"contractVersion": "1.
|
|
3
|
+
"contractVersion": "1.7.0",
|
|
4
4
|
"targetPrefix": "/app/",
|
|
5
5
|
"default": {
|
|
6
6
|
"execution": "scopeMode",
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
"/app/timeline/entity/latest/list"
|
|
24
24
|
],
|
|
25
25
|
"scopeModeTargets": [
|
|
26
|
+
"/app/artifact/resolve",
|
|
26
27
|
"/app/scope/context/get"
|
|
27
28
|
],
|
|
28
29
|
"hubPrefixes": [
|
package/manifest/targets.v1.json
CHANGED
package/package.json
CHANGED
package/protocol.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"protocol": "mhome.app-facade",
|
|
3
|
-
"contractVersion": "1.
|
|
3
|
+
"contractVersion": "1.7.0",
|
|
4
4
|
"manifest": "manifest/app-facade.v1.json",
|
|
5
5
|
"schemas": {
|
|
6
6
|
"call": "schema/facade-call.v1.schema.json",
|
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
"routing": "schema/routing.v1.schema.json",
|
|
10
10
|
"hubState": "schema/hub-state.v1.schema.json",
|
|
11
11
|
"localHubState": "schema/local-hub-state.v1.schema.json",
|
|
12
|
-
"topology": "schema/topology.v1.schema.json"
|
|
12
|
+
"topology": "schema/topology.v1.schema.json",
|
|
13
|
+
"deviceTopology": "schema/device-topology.v1.schema.json"
|
|
13
14
|
},
|
|
14
15
|
"fixtures": {
|
|
15
16
|
"valid": "fixtures",
|
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mhome.ai/schema/device-topology.v1.schema.json",
|
|
4
|
+
"title": "MeowLink Device Topology",
|
|
5
|
+
"description": "A Device Integration relationship graph. Edge direction is semantic and does not imply hierarchy, containment, single-parent ownership, or acyclicity.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"contract",
|
|
10
|
+
"scopeId",
|
|
11
|
+
"generation",
|
|
12
|
+
"revision",
|
|
13
|
+
"observedAtMs",
|
|
14
|
+
"completeness",
|
|
15
|
+
"issues",
|
|
16
|
+
"entities",
|
|
17
|
+
"edges"
|
|
18
|
+
],
|
|
19
|
+
"properties": {
|
|
20
|
+
"contract": { "const": "mhome.device.topology.v1" },
|
|
21
|
+
"scopeId": { "type": "string", "minLength": 1 },
|
|
22
|
+
"generation": { "type": "string", "minLength": 1 },
|
|
23
|
+
"revision": { "type": "integer", "minimum": 0 },
|
|
24
|
+
"observedAtMs": { "type": "integer", "minimum": 0 },
|
|
25
|
+
"completeness": { "enum": ["complete", "partial"] },
|
|
26
|
+
"issues": {
|
|
27
|
+
"type": "array",
|
|
28
|
+
"items": { "$ref": "#/$defs/issue" }
|
|
29
|
+
},
|
|
30
|
+
"entities": {
|
|
31
|
+
"type": "array",
|
|
32
|
+
"items": { "$ref": "#/$defs/entity" },
|
|
33
|
+
"contains": {
|
|
34
|
+
"type": "object",
|
|
35
|
+
"required": ["kind"],
|
|
36
|
+
"properties": {
|
|
37
|
+
"kind": { "const": "deviceIntegration" }
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"minContains": 1,
|
|
41
|
+
"maxContains": 1
|
|
42
|
+
},
|
|
43
|
+
"edges": {
|
|
44
|
+
"type": "array",
|
|
45
|
+
"items": { "$ref": "#/$defs/edge" }
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"allOf": [
|
|
49
|
+
{
|
|
50
|
+
"if": {
|
|
51
|
+
"properties": {
|
|
52
|
+
"completeness": { "const": "complete" }
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"then": {
|
|
56
|
+
"properties": {
|
|
57
|
+
"issues": { "maxItems": 0 }
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"if": {
|
|
63
|
+
"properties": {
|
|
64
|
+
"completeness": { "const": "partial" }
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"then": {
|
|
68
|
+
"properties": {
|
|
69
|
+
"issues": { "minItems": 1 }
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
],
|
|
74
|
+
"$defs": {
|
|
75
|
+
"runtime": {
|
|
76
|
+
"type": "object",
|
|
77
|
+
"additionalProperties": false,
|
|
78
|
+
"required": ["state"],
|
|
79
|
+
"properties": {
|
|
80
|
+
"state": { "enum": ["healthy", "degraded", "offline", "unknown"] },
|
|
81
|
+
"reason": { "type": "string" },
|
|
82
|
+
"updatedAtMs": { "type": "integer", "minimum": 0 }
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
"observation": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"additionalProperties": false,
|
|
88
|
+
"required": ["state", "observedAtMs"],
|
|
89
|
+
"properties": {
|
|
90
|
+
"state": { "enum": ["connected", "disconnected", "unknown"] },
|
|
91
|
+
"observedAtMs": { "type": "integer", "minimum": 0 },
|
|
92
|
+
"reason": { "type": "string" }
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
"issue": {
|
|
96
|
+
"type": "object",
|
|
97
|
+
"additionalProperties": false,
|
|
98
|
+
"required": ["code", "message"],
|
|
99
|
+
"properties": {
|
|
100
|
+
"code": { "type": "string", "minLength": 1 },
|
|
101
|
+
"message": { "type": "string", "minLength": 1 },
|
|
102
|
+
"entityId": { "type": "string", "minLength": 1 }
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"entity": {
|
|
106
|
+
"oneOf": [
|
|
107
|
+
{
|
|
108
|
+
"type": "object",
|
|
109
|
+
"additionalProperties": false,
|
|
110
|
+
"required": ["id", "kind", "integrationId", "displayName"],
|
|
111
|
+
"properties": {
|
|
112
|
+
"id": { "type": "string", "minLength": 1 },
|
|
113
|
+
"kind": { "const": "deviceIntegration" },
|
|
114
|
+
"integrationId": { "type": "string", "minLength": 1 },
|
|
115
|
+
"displayName": { "type": "string", "minLength": 1 }
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"type": "object",
|
|
120
|
+
"additionalProperties": false,
|
|
121
|
+
"required": [
|
|
122
|
+
"id",
|
|
123
|
+
"kind",
|
|
124
|
+
"integrationId",
|
|
125
|
+
"displayName",
|
|
126
|
+
"mode",
|
|
127
|
+
"multiConnect"
|
|
128
|
+
],
|
|
129
|
+
"properties": {
|
|
130
|
+
"id": { "type": "string", "minLength": 1 },
|
|
131
|
+
"kind": { "const": "provider" },
|
|
132
|
+
"integrationId": { "type": "string", "minLength": 1 },
|
|
133
|
+
"displayName": { "type": "string", "minLength": 1 },
|
|
134
|
+
"mode": { "type": "string", "minLength": 1 },
|
|
135
|
+
"multiConnect": { "type": "boolean" }
|
|
136
|
+
}
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
"type": "object",
|
|
140
|
+
"additionalProperties": false,
|
|
141
|
+
"required": [
|
|
142
|
+
"id",
|
|
143
|
+
"kind",
|
|
144
|
+
"integrationId",
|
|
145
|
+
"connectionId",
|
|
146
|
+
"displayName",
|
|
147
|
+
"runtime"
|
|
148
|
+
],
|
|
149
|
+
"properties": {
|
|
150
|
+
"id": { "type": "string", "minLength": 1 },
|
|
151
|
+
"kind": { "const": "connection" },
|
|
152
|
+
"integrationId": { "type": "string", "minLength": 1 },
|
|
153
|
+
"connectionId": { "type": "string", "minLength": 1 },
|
|
154
|
+
"displayName": { "type": "string", "minLength": 1 },
|
|
155
|
+
"runtime": { "$ref": "#/$defs/runtime" }
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"type": "object",
|
|
160
|
+
"additionalProperties": false,
|
|
161
|
+
"required": [
|
|
162
|
+
"id",
|
|
163
|
+
"kind",
|
|
164
|
+
"nodeId",
|
|
165
|
+
"nodeType",
|
|
166
|
+
"hostId",
|
|
167
|
+
"serviceInstanceId",
|
|
168
|
+
"displayName",
|
|
169
|
+
"runtime"
|
|
170
|
+
],
|
|
171
|
+
"properties": {
|
|
172
|
+
"id": { "type": "string", "minLength": 1 },
|
|
173
|
+
"kind": { "const": "pluginInstance" },
|
|
174
|
+
"nodeId": { "type": "string", "minLength": 1 },
|
|
175
|
+
"nodeType": { "type": "string", "minLength": 1 },
|
|
176
|
+
"hostId": { "type": "string", "minLength": 1 },
|
|
177
|
+
"serviceInstanceId": { "type": "string", "minLength": 1 },
|
|
178
|
+
"displayName": { "type": "string", "minLength": 1 },
|
|
179
|
+
"hostDisplayName": { "type": "string", "minLength": 1 },
|
|
180
|
+
"runtime": { "$ref": "#/$defs/runtime" }
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
"type": "object",
|
|
185
|
+
"additionalProperties": false,
|
|
186
|
+
"required": [
|
|
187
|
+
"id",
|
|
188
|
+
"kind",
|
|
189
|
+
"sourceType",
|
|
190
|
+
"sourceId",
|
|
191
|
+
"displayName",
|
|
192
|
+
"role",
|
|
193
|
+
"runtime"
|
|
194
|
+
],
|
|
195
|
+
"properties": {
|
|
196
|
+
"id": { "type": "string", "minLength": 1 },
|
|
197
|
+
"kind": { "const": "sourceDevice" },
|
|
198
|
+
"sourceType": { "type": "string", "minLength": 1 },
|
|
199
|
+
"sourceId": { "type": "string", "minLength": 1 },
|
|
200
|
+
"displayName": { "type": "string", "minLength": 1 },
|
|
201
|
+
"role": { "enum": ["bridge", "device", "unknown"] },
|
|
202
|
+
"runtime": { "$ref": "#/$defs/runtime" }
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"type": "object",
|
|
207
|
+
"additionalProperties": false,
|
|
208
|
+
"required": [
|
|
209
|
+
"id",
|
|
210
|
+
"kind",
|
|
211
|
+
"entityId",
|
|
212
|
+
"integrationId",
|
|
213
|
+
"displayName",
|
|
214
|
+
"enabled",
|
|
215
|
+
"runtime"
|
|
216
|
+
],
|
|
217
|
+
"properties": {
|
|
218
|
+
"id": { "type": "string", "minLength": 1 },
|
|
219
|
+
"kind": { "const": "device" },
|
|
220
|
+
"entityId": { "type": "string", "minLength": 1 },
|
|
221
|
+
"integrationId": { "type": "string", "minLength": 1 },
|
|
222
|
+
"displayName": { "type": "string", "minLength": 1 },
|
|
223
|
+
"enabled": { "type": "boolean" },
|
|
224
|
+
"runtime": { "$ref": "#/$defs/runtime" }
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
]
|
|
228
|
+
},
|
|
229
|
+
"edge": {
|
|
230
|
+
"type": "object",
|
|
231
|
+
"additionalProperties": false,
|
|
232
|
+
"required": [
|
|
233
|
+
"id",
|
|
234
|
+
"source",
|
|
235
|
+
"target",
|
|
236
|
+
"relation",
|
|
237
|
+
"basis",
|
|
238
|
+
"durability",
|
|
239
|
+
"observation"
|
|
240
|
+
],
|
|
241
|
+
"properties": {
|
|
242
|
+
"id": { "type": "string", "minLength": 1 },
|
|
243
|
+
"source": { "type": "string", "minLength": 1 },
|
|
244
|
+
"target": { "type": "string", "minLength": 1 },
|
|
245
|
+
"relation": {
|
|
246
|
+
"enum": [
|
|
247
|
+
"integration-provider",
|
|
248
|
+
"plugin-provider",
|
|
249
|
+
"plugin-connection",
|
|
250
|
+
"provider-connection",
|
|
251
|
+
"provider-device",
|
|
252
|
+
"connection-device",
|
|
253
|
+
"connection-source",
|
|
254
|
+
"source-device"
|
|
255
|
+
]
|
|
256
|
+
},
|
|
257
|
+
"basis": {
|
|
258
|
+
"enum": [
|
|
259
|
+
"integrationInstall",
|
|
260
|
+
"pluginBinding",
|
|
261
|
+
"connectionOwnership",
|
|
262
|
+
"twinSource",
|
|
263
|
+
"sourceProjection"
|
|
264
|
+
]
|
|
265
|
+
},
|
|
266
|
+
"durability": { "enum": ["durable", "ephemeral"] },
|
|
267
|
+
"observation": { "$ref": "#/$defs/observation" }
|
|
268
|
+
},
|
|
269
|
+
"oneOf": [
|
|
270
|
+
{
|
|
271
|
+
"properties": {
|
|
272
|
+
"relation": { "const": "integration-provider" },
|
|
273
|
+
"basis": { "const": "integrationInstall" }
|
|
274
|
+
}
|
|
275
|
+
},
|
|
276
|
+
{
|
|
277
|
+
"properties": {
|
|
278
|
+
"relation": {
|
|
279
|
+
"enum": ["plugin-provider", "plugin-connection"]
|
|
280
|
+
},
|
|
281
|
+
"basis": { "const": "pluginBinding" }
|
|
282
|
+
}
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
"properties": {
|
|
286
|
+
"relation": { "const": "provider-connection" },
|
|
287
|
+
"basis": { "const": "connectionOwnership" }
|
|
288
|
+
}
|
|
289
|
+
},
|
|
290
|
+
{
|
|
291
|
+
"properties": {
|
|
292
|
+
"relation": {
|
|
293
|
+
"enum": ["provider-device", "connection-device"]
|
|
294
|
+
},
|
|
295
|
+
"basis": { "const": "twinSource" }
|
|
296
|
+
}
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"properties": {
|
|
300
|
+
"relation": {
|
|
301
|
+
"enum": ["connection-source", "source-device"]
|
|
302
|
+
},
|
|
303
|
+
"basis": { "const": "sourceProjection" }
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
]
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"$id": "https://mhome.ai/schema/space-topology.v1.schema.json",
|
|
4
|
-
"title": "
|
|
4
|
+
"title": "MeowLink Space Topology",
|
|
5
5
|
"type": "object",
|
|
6
6
|
"additionalProperties": false,
|
|
7
7
|
"required": [
|