@mega-yfue/eufy-sdk 0.5.0-beta.53 → 0.5.0-beta.54

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.
@@ -1,14 +1,9 @@
1
1
  /**
2
- * Inbound Tuya DP event parsing and routing for eufy Home/Clean (`eufy_home_tuya`) devices.
2
+ * Inbound Tuya DP parsing and routing for eufy Home/Clean (`eufy_home_tuya`) devices.
3
3
  *
4
- * {@link parseTuyaDpReport} unwraps the Anker MQTT `{head, payload}` envelope and extracts the
5
- * raw DP map. {@link parseTuyaDpEvent} then validates and normalises it to a numeric-keyed record.
4
+ * {@link parseTuyaDpEvent} validates a Tuya cloud DP map and normalises it to a numeric-keyed record.
6
5
  * {@link TuyaDpRouter} delivers the result to the registered {@link TuyaDpInbound} listener so the
7
6
  * capability layer can consume Tuya state through the same typed getters as AIoT.
8
- *
9
- * Inbound messages arrive on `cmd/eufy_home/{model}/{sn}/res` with `sign_code: 0` (no additional
10
- * encryption — confirmed from clean-device captures). If a future capture shows `sign_code ≠ 0` the
11
- * payload will be AES-128-ECB encrypted with the device's localKey before the JSON can be parsed.
12
7
  */
13
8
  import type { TuyaDpInbound } from "../../core/contracts.js";
14
9
  /**
@@ -21,22 +16,6 @@ import type { TuyaDpInbound } from "../../core/contracts.js";
21
16
  * valid DP entry was found.
22
17
  */
23
18
  export declare function parseTuyaDpEvent(payload: unknown): Record<number, boolean | number | string> | null;
24
- /**
25
- * Extract a raw DP map from an inbound Anker MQTT message for a `eufy_home_tuya` device.
26
- *
27
- * Messages arrive in the same `{head, payload}` envelope the AIoT path uses, where `payload` is a
28
- * JSON **string**:
29
- * ```json
30
- * { "head": { "cmd": 65537, "cmd_status": 2, "sign_code": 0, ... },
31
- * "payload": "{\"t\":\"…\",\"protocol\":2,\"data\":{\"104\":80,\"106\":0}}" }
32
- * ```
33
- * Two DP layouts inside the decoded payload are handled: Tuya-native (`data.dps`) and AIoT-direct
34
- * (`data` with integer-keyed DP ids). Falls back to flat `envelope.dps` / `envelope.data.dps`
35
- * shapes for any pre-parsed delivery. Returns `undefined` when no recognised shape is found.
36
- *
37
- * @internal
38
- */
39
- export declare function parseTuyaDpReport(raw: unknown): Record<string, unknown> | undefined;
40
19
  /**
41
20
  * Routes validated inbound Tuya DP events to the registered {@link TuyaDpInbound} listener.
42
21
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mega-yfue/eufy-sdk",
3
- "version": "0.5.0-beta.53",
3
+ "version": "0.5.0-beta.54",
4
4
  "description": "One typed TypeScript client for the Anker eufy v6 cloud — capability-driven devices, realtime events over P2P/MQTT/push, and live media",
5
5
  "license": "Apache-2.0",
6
6
  "author": "mega-yfue",