@mhome/app-facade-protocol 1.137.1 → 1.138.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/host-provisioning-v1.md +22 -16
- package/contract/widget-presentation-v1.md +3 -2
- package/contract/widget-writes-v1.md +7 -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
|
@@ -85,8 +85,8 @@ Fallback characteristic UUIDs: the standard endpoints as for pods, `host-info`
|
|
|
85
85
|
```
|
|
86
86
|
|
|
87
87
|
`productId` is optional. `onboardingRequired` reports whether this Host still
|
|
88
|
-
awaits its first claim. `networkOnline` reports current LAN
|
|
89
|
-
|
|
88
|
+
awaits its first claim and is required. `networkOnline` reports current LAN
|
|
89
|
+
readiness. A securely paired Host with `networkOnline: true`
|
|
90
90
|
and `onboardingRequired: true` can finish without resubmitting Wi-Fi. `finish`
|
|
91
91
|
issues a fresh first-claim token after checking authoritative Host ownership.
|
|
92
92
|
Already claimed Hosts never issue a new first-claim token.
|
|
@@ -102,7 +102,8 @@ Fallback characteristic UUIDs: the standard endpoints as for pods, `host-info`
|
|
|
102
102
|
established and the Host is not recovering an unfinished claim on a working
|
|
103
103
|
network. Refusal keeps the current setup session open. The Client reports
|
|
104
104
|
completion only after a positive receipt, with a valid token when the secured
|
|
105
|
-
Host information indicated that first claim was pending.
|
|
105
|
+
Host information indicated that first claim was pending. A receipt that
|
|
106
|
+
unexpectedly carries a token for an already claimed Host also fails.
|
|
106
107
|
`finish` ends the central's setup session. Without it, the Host disconnects the
|
|
107
108
|
central 30 seconds after a successful join; the commissioner retries `finish`
|
|
108
109
|
within that window. Network readiness and mDNS announcement do not establish
|
|
@@ -120,11 +121,12 @@ and stop at `result_count` or on an empty page. This also works with ESP-IDF
|
|
|
120
121
|
devices, which return exactly the requested entries (commissioners ask for at
|
|
121
122
|
most 4 at a time).
|
|
122
123
|
|
|
123
|
-
`prov-config` status reports `connected` with the IPv4 address
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
124
|
+
`prov-config` status reports `connected` with the IPv4 address after the Host
|
|
125
|
+
has saved the new profile. The Linux backend first activates a temporary
|
|
126
|
+
profile. On failure or local cancellation it removes that profile and attempts
|
|
127
|
+
to reactivate the previous one. `connection_failed` may distinguish
|
|
128
|
+
`auth_error` or `network_not_found`. After a failed join the commissioner sends
|
|
129
|
+
`prov-ctrl` reset before the next `set_config`.
|
|
128
130
|
|
|
129
131
|
## 4. Native Client targets
|
|
130
132
|
|
|
@@ -161,9 +163,12 @@ Session states, in order: `connecting`, `awaiting_code`, `securing`,
|
|
|
161
163
|
`timed_out`, `cancelled`; transitional `cancelling`. `completed` carries `host`, the reported `addresses`
|
|
162
164
|
(IPv4 only, possibly empty) and `claimToken` from the `finish` response; the
|
|
163
165
|
commissioner sends `finish` (up to 3 times while the secure session lasts)
|
|
164
|
-
before reporting it.
|
|
165
|
-
|
|
166
|
-
|
|
166
|
+
before reporting it. A missing or refused `finish` is a failed session. The
|
|
167
|
+
first-claim handoff includes `claimToken`. A completed Wi-Fi update on an
|
|
168
|
+
already claimed Host omits it. An account change can redact the token from a
|
|
169
|
+
terminal event, so confirm a tokenless completion through the native status
|
|
170
|
+
target before displaying the Wi-Fi update as successful. No other state
|
|
171
|
+
carries `claimToken`.
|
|
167
172
|
|
|
168
173
|
The first claim (TOFU) after BLE provisioning must include the returned token.
|
|
169
174
|
Native `host.claim` passes it to `POST /v1/auth/claim`, alongside the environment,
|
|
@@ -194,13 +199,14 @@ The schema is `schema/host-provision.v1.schema.json`.
|
|
|
194
199
|
setup after restart, keeping saved Wi-Fi. Network readiness is not ownership.
|
|
195
200
|
An existing local claim, including one awaiting cloud confirmation, must never
|
|
196
201
|
reopen first-claim authority. An unreadable ownership store refuses recovery.
|
|
197
|
-
- Re-provision window: opened
|
|
198
|
-
|
|
202
|
+
- Re-provision window: opened on the target Host with `meow host provision open`.
|
|
203
|
+
The CLI talks directly to the Host's local control socket, without a Client
|
|
204
|
+
daemon. Mutating local provisioning commands (`open`,
|
|
199
205
|
`close`, `factory-reset`) require root or membership in the `meow-admin`
|
|
200
206
|
group (checked with the peer credentials of the local control socket); status
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
after 10 minutes.
|
|
207
|
+
is available with `meow host provision status`.
|
|
208
|
+
Host identity, owners and services are kept. The window closes after a
|
|
209
|
+
successful join, on `meow host provision close`, or after 10 minutes.
|
|
204
210
|
- Factory reset: from the local interface (`meowhostd factory-reset`). Stops
|
|
205
211
|
services, forgets saved Wi-Fi on BLE provisioning appliances, erases owners,
|
|
206
212
|
the Host security store and bootstrap key, and returns to first provisioning.
|
|
@@ -5,12 +5,13 @@ policy. They are not Agent/CLI/MCP tools. Inputs reject unknown fields.
|
|
|
5
5
|
|
|
6
6
|
| Target | Input | Business output and read boundary |
|
|
7
7
|
| --- | --- | --- |
|
|
8
|
-
| `/app/presentation/widget/list` | Required `{type: "data" \| "button" \| "circadian"}` | `{items, automationNames}`. Reads only that type's Widget table. Global standalone Widgets, defaults and Automation-owned parameters are included
|
|
8
|
+
| `/app/presentation/widget/list` | Required `{type: "data" \| "button" \| "circadian"}` | `{items, automationNames}`. Reads only that type's Widget table. Global standalone Widgets, defaults and Automation-owned parameters are included. Active card interiors, Twin and weather internals are excluded. Pending Data, Button and Circadian Widgets eligible for manual deletion are included for cleanup, regardless of their usual visibility. Owner labels use one selected metadata batch, only for returned Automation owners. No script, relation, history or all-type reads. |
|
|
9
9
|
| `/app/presentation/widget/names/get` | `{ids}`: 1–100 selected, trimmed, deduplicated IDs | `{names: {id: displayName}}`. Missing/blank names omitted. Only selected Widget rows; no legacy `name` fallback. |
|
|
10
10
|
| `/app/presentation/widget/defaults/get` | `{}` | `{items, automationNames:{}}`. Preserves the existing default Widget lookup and lazy initialization, then reads the selected Data Widgets. |
|
|
11
11
|
|
|
12
12
|
Rows carry ID, revision, displayName, description, source/baseId, global, tag,
|
|
13
|
-
current value, and type-specific control configuration.
|
|
13
|
+
current value, and type-specific control configuration. `pendingDeletion: true`
|
|
14
|
+
identifies a Widget whose deletion can be completed through the delete Facade. Circadian rows contain
|
|
14
15
|
only `curve`, `curvePreview` (active curve's UI points), current/next values and
|
|
15
16
|
`nextTimestamp`; they omit complete schedules, location and internal state.
|
|
16
17
|
Complete configuration uses `/app/widget/detail/get`; runtime uses
|
|
@@ -40,5 +40,12 @@ Create/configuration responses retain action, widgetId, type and displayName.
|
|
|
40
40
|
to preserve its previous deletion behavior. This migration does not change the
|
|
41
41
|
shared safe=true protection for Widgets referenced by Automations.
|
|
42
42
|
|
|
43
|
+
After validation, deletion marks each Widget before removing its associated
|
|
44
|
+
resources. A pending Widget remains readable and rejects controls, edits and
|
|
45
|
+
new Automation or Dashboard references. Its list/detail projections carry
|
|
46
|
+
`pendingDeletion: true`. Call the same delete endpoint with the original IDs
|
|
47
|
+
to finish the operation. Missing IDs are already complete. A validation failure
|
|
48
|
+
leaves unstarted Widgets available.
|
|
49
|
+
|
|
43
50
|
All legacy public /widget/* request Controllers are retired. /widget/reportUpdate
|
|
44
51
|
is a push event and internal /dispatch/widget/* operations retain their own roles.
|
package/manifest/routing.v1.json
CHANGED
package/manifest/targets.v1.json
CHANGED
package/package.json
CHANGED