@mega-yfue/eufy-sdk 0.5.0-beta.63 → 0.5.0-beta.64

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,6 +1,6 @@
1
1
  import type { Command } from "../../core/contracts.js";
2
2
  import { type Surface } from "./members.js";
3
- import type { CapabilityModule, CommandContext } from "./types.js";
3
+ import type { AvailabilityContext, CapabilityModule, CommandContext } from "./types.js";
4
4
  /** The state params this capability owns — its OWN vocabulary, used by no other capability. */
5
5
  export declare const RTSP_PARAM: {
6
6
  /**
@@ -93,6 +93,13 @@ export type RtspRecordingModeValue = (typeof RtspRecordingMode)[keyof typeof Rts
93
93
  * and the served effect on each endpoint with an RTSP `DESCRIBE`: 401 = challenged, 200 = open.
94
94
  */
95
95
  export type RtspActions = Surface<typeof RTSP_MEMBERS>;
96
+ /**
97
+ * Whether the publish switch has a wire to this camera. A HomeBase S1 Pro (`STATION_9000`) carries an
98
+ * attached camera's commands over its WebRTC control channel, which takes only the `1350` and `1700`
99
+ * envelopes; the switch is a plain scalar, and no other frame for it is captured there. Gating the
100
+ * `published` member drops its read with its setter, since one availability decision covers both.
101
+ */
102
+ declare function publishable(ctx: AvailabilityContext): boolean;
96
103
  /**
97
104
  * Every `rtsp` feature, declared once.
98
105
  *
@@ -127,6 +134,7 @@ export declare const RTSP_MEMBERS: {
127
134
  readonly publish: true;
128
135
  readonly withdraw: false;
129
136
  };
137
+ readonly available: typeof publishable;
130
138
  };
131
139
  /**
132
140
  * The device-reported RTSP URL — the full `rtsp://user:pass@host/path`, carrying the credentials the
@@ -179,9 +187,13 @@ export declare const RTSP_MEMBERS: {
179
187
  readonly description: string;
180
188
  };
181
189
  /** Persistently publish this camera's stream. The enabling caller owns withdrawing it when done. */
182
- readonly publish: import("./members.js").MethodMember<() => Promise<void>>;
190
+ readonly publish: import("./members.js").MethodMember<() => Promise<void>> & {
191
+ available: (ctx: CommandContext) => boolean;
192
+ };
183
193
  /** Withdraw this camera's persistent publication; consumer retries do not ask the SDK to republish it. */
184
- readonly withdraw: import("./members.js").MethodMember<() => Promise<void>>;
194
+ readonly withdraw: import("./members.js").MethodMember<() => Promise<void>> & {
195
+ available: (ctx: CommandContext) => boolean;
196
+ };
185
197
  /**
186
198
  * Store credentials and request authentication on this camera's stream. Served enforcement is
187
199
  * topology-dependent and must be verified with `DESCRIBE` (401 = challenged, 200 = open).
@@ -219,3 +231,4 @@ export declare const RTSP_MEMBERS: {
219
231
  * rather than a model table.
220
232
  */
221
233
  export declare const RTSP: CapabilityModule;
234
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mega-yfue/eufy-sdk",
3
- "version": "0.5.0-beta.63",
3
+ "version": "0.5.0-beta.64",
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",