@camstack/addon-provider-wyze 0.2.110 → 0.2.112

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/dist/addon.js CHANGED
@@ -12324,7 +12324,23 @@ var PickStreamRequirementsSchema = object({
12324
12324
  * This is what lets one picker serve both the bypass and the full source
12325
12325
  * choice, instead of a consumer scoring privately when the bypass misses.
12326
12326
  */
12327
- allowTranscode: boolean().optional()
12327
+ allowTranscode: boolean().optional(),
12328
+ /**
12329
+ * Consider ONLY streams the broker has bound to a profile slot.
12330
+ *
12331
+ * A consumer that dials the broker — which is every exporter, since none
12332
+ * of them may open the camera's own URL — can do nothing with a source
12333
+ * that has no slot: there is no restream to dial. Without this the picker
12334
+ * can name such a stream, and each consumer discovers the dead end for
12335
+ * itself: Alexa's `profileForCamStream` returns `null` and it quietly
12336
+ * falls back, and HomeKit would have had to grow the same function again.
12337
+ *
12338
+ * Default `false`, and deliberately so: the BROKER itself picks through
12339
+ * here when it decides which source to BIND to a slot
12340
+ * (`computeInitialAssignment`), and it must see the unbound ones or it
12341
+ * could never bind them.
12342
+ */
12343
+ requireProfileBound: boolean().optional()
12328
12344
  }).readonly();
12329
12345
  var PickStreamPreferencesSchema = object({
12330
12346
  /**
@@ -12365,7 +12381,43 @@ var PickedCamStreamSchema = object({
12365
12381
  */
12366
12382
  transcodes: boolean(),
12367
12383
  /** One-line explanation of why this stream won — for logs / debug UI. */
12368
- reason: string()
12384
+ reason: string(),
12385
+ /**
12386
+ * The broker profile slot this source is bound to, when it is bound.
12387
+ *
12388
+ * Answered HERE because every consumer needs it and none of them can get it
12389
+ * from the `camStreamId` alone. Alexa wrote `profileForCamStream` for it —
12390
+ * a second cap read plus a `null` branch — and HomeKit was about to write
12391
+ * the same function a second time.
12392
+ *
12393
+ * Absent when the source has no slot, which a caller passing
12394
+ * `requireProfileBound` can never see.
12395
+ */
12396
+ profile: CamProfileSchema.optional(),
12397
+ /** The broker id of that slot, for logs that must name what was dialled. */
12398
+ brokerId: string().optional(),
12399
+ /**
12400
+ * The broker restream URL to dial for this stream.
12401
+ *
12402
+ * An exporter must never open the camera's own URL — the broker is the one
12403
+ * that dials the camera, and every consumer goes through its restream. So
12404
+ * the picker answers with the thing a consumer may actually use, instead of
12405
+ * naming a source and leaving each caller to look the URL up.
12406
+ */
12407
+ url: string().optional(),
12408
+ /**
12409
+ * Frames per second this stream really delivers, and where the number came
12410
+ * from.
12411
+ *
12412
+ * It is here because getting it wrong is expensive and silent: a HomeKit
12413
+ * accessory advertised 720p at 24 fps while the slot serving it ran at 9,
12414
+ * and the controller rendered nothing at all. The source is carried with the
12415
+ * value for the same reason the bitrate evidence is: `published` is what the
12416
+ * publisher declares and `measured` is what the broker observed, and they
12417
+ * are not interchangeable.
12418
+ */
12419
+ fps: number().positive().optional(),
12420
+ fpsSource: _enum(["published", "measured"]).optional()
12369
12421
  });
12370
12422
  /**
12371
12423
  * Camera streams — device-scoped facade over the system `stream-broker`.
@@ -13565,6 +13617,70 @@ var LocationIconAssignmentSchema = object({
13565
13617
  locationKey: string(),
13566
13618
  icon: LocationIconIdSchema
13567
13619
  });
13620
+ /**
13621
+ * One (location, description) assignment as it travels.
13622
+ *
13623
+ * Same key discipline as {@link LocationIconAssignmentSchema}, and for the same
13624
+ * reason: this lived for a while in the post-analysis addon's own settings,
13625
+ * keyed by a HAND-TYPED label matched exactly and case-sensitively. A rename in
13626
+ * the Locations page carried the icon and silently orphaned the description —
13627
+ * two authorities for one thing, joined by two different rules. Now both hang
13628
+ * off the location itself, on `locationIconKey`.
13629
+ */
13630
+ var LocationDescriptionAssignmentSchema = object({
13631
+ locationKey: string(),
13632
+ description: string()
13633
+ });
13634
+ /**
13635
+ * A SITE ZONE — a named part of the property that several locations belong to.
13636
+ *
13637
+ * "Zona notte" holds every bedroom; "Zona giorno" the living room and the
13638
+ * kitchen. A camera belongs to exactly one location, and a location to at most
13639
+ * one zone, so a camera's zone is derived and never stored on the device: the
13640
+ * whole point of this entity is that grouping rooms touches no device row.
13641
+ *
13642
+ * ## Why not `zone`
13643
+ *
13644
+ * Because `zone` is already the most loaded word in this product: 612 source
13645
+ * files and 24 Italian strings where it means a DETECTION zone drawn on a
13646
+ * camera. The two are unrelated — one is a polygon in a frame, the other is a
13647
+ * set of rooms — and a reader who confuses them will look for a camera's
13648
+ * bedrooms. So the code says `siteZone` everywhere, and the UI frees the plain
13649
+ * word by calling the drawn one what it actually is: a detection zone.
13650
+ *
13651
+ * ## The key
13652
+ *
13653
+ * `siteZoneKey(label)` — trimmed, lower-cased, the SAME derivation locations
13654
+ * use (`locationIconKey`). Membership and the icon both hang off it, so a
13655
+ * case-only rename keeps them, which is exactly the orphaning that cost us a
13656
+ * silently-dropped location description.
13657
+ *
13658
+ * The icon vocabulary is the location one, unchanged: a zone is drawn on the
13659
+ * same two surfaces by the same glyph map, so a second vocabulary would be a
13660
+ * second thing to keep drawable (`scripts/check-location-icons-drawable.ts`).
13661
+ */
13662
+ /**
13663
+ * One zone as it travels: its key, the label the operator typed, its icon and
13664
+ * the locations inside it.
13665
+ *
13666
+ * The LABEL is carried alongside the key because the key is lossy on purpose —
13667
+ * a surface must show "Zona notte", not "zona notte". Locations are carried
13668
+ * here, rather than left to a second call, because every consumer wants both
13669
+ * at once and a viewer that asked twice could render a zone whose membership
13670
+ * it has not fetched yet.
13671
+ *
13672
+ * `icon: null` means nobody chose one, which is NOT the fallback pin: only one
13673
+ * of those two is a choice, and a picker has to draw them differently.
13674
+ */
13675
+ var SiteZoneSchema = object({
13676
+ zoneKey: string(),
13677
+ label: string(),
13678
+ icon: LocationIconIdSchema.nullable(),
13679
+ /** Folded location keys, sorted. A location listed here need not be
13680
+ * REGISTERED — devices carry labels nobody registered, and those rooms are
13681
+ * the ones that most want grouping. */
13682
+ locationKeys: array(string())
13683
+ });
13568
13684
  var ProviderStatusSchema = object({
13569
13685
  connected: boolean(),
13570
13686
  deviceCount: number(),
@@ -14163,6 +14279,33 @@ method(object({
14163
14279
  }), _void(), {
14164
14280
  kind: "mutation",
14165
14281
  auth: "admin"
14282
+ }), method(_void(), array(LocationDescriptionAssignmentSchema)), method(object({
14283
+ location: string(),
14284
+ description: string().max(400).nullable()
14285
+ }), _void(), {
14286
+ kind: "mutation",
14287
+ auth: "admin"
14288
+ }), method(_void(), array(SiteZoneSchema)), method(object({
14289
+ name: string(),
14290
+ icon: LocationIconIdSchema.nullable().optional()
14291
+ }), _void(), {
14292
+ kind: "mutation",
14293
+ auth: "admin"
14294
+ }), method(object({ name: string() }), _void(), {
14295
+ kind: "mutation",
14296
+ auth: "admin"
14297
+ }), method(object({
14298
+ from: string(),
14299
+ to: string()
14300
+ }), _void(), {
14301
+ kind: "mutation",
14302
+ auth: "admin"
14303
+ }), method(object({
14304
+ location: string(),
14305
+ zone: string().nullable()
14306
+ }), _void(), {
14307
+ kind: "mutation",
14308
+ auth: "admin"
14166
14309
  }), method(object({
14167
14310
  deviceId: number(),
14168
14311
  disabled: boolean()
@@ -37185,6 +37328,12 @@ Object.freeze({
37185
37328
  addonId: null,
37186
37329
  access: "view"
37187
37330
  },
37331
+ "deviceManager.listLocationDescriptions": {
37332
+ capName: "device-manager",
37333
+ capScope: "system",
37334
+ addonId: null,
37335
+ access: "view"
37336
+ },
37188
37337
  "deviceManager.listLocationIcons": {
37189
37338
  capName: "device-manager",
37190
37339
  capScope: "system",
@@ -37203,6 +37352,12 @@ Object.freeze({
37203
37352
  addonId: null,
37204
37353
  access: "view"
37205
37354
  },
37355
+ "deviceManager.listSiteZones": {
37356
+ capName: "device-manager",
37357
+ capScope: "system",
37358
+ addonId: null,
37359
+ access: "view"
37360
+ },
37206
37361
  "deviceManager.listWrappersForCap": {
37207
37362
  capName: "device-manager",
37208
37363
  capScope: "system",
@@ -37287,12 +37442,24 @@ Object.freeze({
37287
37442
  addonId: null,
37288
37443
  access: "delete"
37289
37444
  },
37445
+ "deviceManager.removeSiteZone": {
37446
+ capName: "device-manager",
37447
+ capScope: "system",
37448
+ addonId: null,
37449
+ access: "delete"
37450
+ },
37290
37451
  "deviceManager.renameLocation": {
37291
37452
  capName: "device-manager",
37292
37453
  capScope: "system",
37293
37454
  addonId: null,
37294
37455
  access: "create"
37295
37456
  },
37457
+ "deviceManager.renameSiteZone": {
37458
+ capName: "device-manager",
37459
+ capScope: "system",
37460
+ addonId: null,
37461
+ access: "create"
37462
+ },
37296
37463
  "deviceManager.runDeviceAction": {
37297
37464
  capName: "device-manager",
37298
37465
  capScope: "system",
@@ -37335,12 +37502,24 @@ Object.freeze({
37335
37502
  addonId: null,
37336
37503
  access: "create"
37337
37504
  },
37505
+ "deviceManager.setLocationDescription": {
37506
+ capName: "device-manager",
37507
+ capScope: "system",
37508
+ addonId: null,
37509
+ access: "create"
37510
+ },
37338
37511
  "deviceManager.setLocationIcon": {
37339
37512
  capName: "device-manager",
37340
37513
  capScope: "system",
37341
37514
  addonId: null,
37342
37515
  access: "create"
37343
37516
  },
37517
+ "deviceManager.setLocationZone": {
37518
+ capName: "device-manager",
37519
+ capScope: "system",
37520
+ addonId: null,
37521
+ access: "create"
37522
+ },
37344
37523
  "deviceManager.setMetadata": {
37345
37524
  capName: "device-manager",
37346
37525
  capScope: "system",
@@ -37371,6 +37550,12 @@ Object.freeze({
37371
37550
  addonId: null,
37372
37551
  access: "create"
37373
37552
  },
37553
+ "deviceManager.setSiteZone": {
37554
+ capName: "device-manager",
37555
+ capScope: "system",
37556
+ addonId: null,
37557
+ access: "create"
37558
+ },
37374
37559
  "deviceManager.setStreamProfileMap": {
37375
37560
  capName: "device-manager",
37376
37561
  capScope: "system",
package/dist/addon.mjs CHANGED
@@ -12303,7 +12303,23 @@ var PickStreamRequirementsSchema = object({
12303
12303
  * This is what lets one picker serve both the bypass and the full source
12304
12304
  * choice, instead of a consumer scoring privately when the bypass misses.
12305
12305
  */
12306
- allowTranscode: boolean().optional()
12306
+ allowTranscode: boolean().optional(),
12307
+ /**
12308
+ * Consider ONLY streams the broker has bound to a profile slot.
12309
+ *
12310
+ * A consumer that dials the broker — which is every exporter, since none
12311
+ * of them may open the camera's own URL — can do nothing with a source
12312
+ * that has no slot: there is no restream to dial. Without this the picker
12313
+ * can name such a stream, and each consumer discovers the dead end for
12314
+ * itself: Alexa's `profileForCamStream` returns `null` and it quietly
12315
+ * falls back, and HomeKit would have had to grow the same function again.
12316
+ *
12317
+ * Default `false`, and deliberately so: the BROKER itself picks through
12318
+ * here when it decides which source to BIND to a slot
12319
+ * (`computeInitialAssignment`), and it must see the unbound ones or it
12320
+ * could never bind them.
12321
+ */
12322
+ requireProfileBound: boolean().optional()
12307
12323
  }).readonly();
12308
12324
  var PickStreamPreferencesSchema = object({
12309
12325
  /**
@@ -12344,7 +12360,43 @@ var PickedCamStreamSchema = object({
12344
12360
  */
12345
12361
  transcodes: boolean(),
12346
12362
  /** One-line explanation of why this stream won — for logs / debug UI. */
12347
- reason: string()
12363
+ reason: string(),
12364
+ /**
12365
+ * The broker profile slot this source is bound to, when it is bound.
12366
+ *
12367
+ * Answered HERE because every consumer needs it and none of them can get it
12368
+ * from the `camStreamId` alone. Alexa wrote `profileForCamStream` for it —
12369
+ * a second cap read plus a `null` branch — and HomeKit was about to write
12370
+ * the same function a second time.
12371
+ *
12372
+ * Absent when the source has no slot, which a caller passing
12373
+ * `requireProfileBound` can never see.
12374
+ */
12375
+ profile: CamProfileSchema.optional(),
12376
+ /** The broker id of that slot, for logs that must name what was dialled. */
12377
+ brokerId: string().optional(),
12378
+ /**
12379
+ * The broker restream URL to dial for this stream.
12380
+ *
12381
+ * An exporter must never open the camera's own URL — the broker is the one
12382
+ * that dials the camera, and every consumer goes through its restream. So
12383
+ * the picker answers with the thing a consumer may actually use, instead of
12384
+ * naming a source and leaving each caller to look the URL up.
12385
+ */
12386
+ url: string().optional(),
12387
+ /**
12388
+ * Frames per second this stream really delivers, and where the number came
12389
+ * from.
12390
+ *
12391
+ * It is here because getting it wrong is expensive and silent: a HomeKit
12392
+ * accessory advertised 720p at 24 fps while the slot serving it ran at 9,
12393
+ * and the controller rendered nothing at all. The source is carried with the
12394
+ * value for the same reason the bitrate evidence is: `published` is what the
12395
+ * publisher declares and `measured` is what the broker observed, and they
12396
+ * are not interchangeable.
12397
+ */
12398
+ fps: number().positive().optional(),
12399
+ fpsSource: _enum(["published", "measured"]).optional()
12348
12400
  });
12349
12401
  /**
12350
12402
  * Camera streams — device-scoped facade over the system `stream-broker`.
@@ -13544,6 +13596,70 @@ var LocationIconAssignmentSchema = object({
13544
13596
  locationKey: string(),
13545
13597
  icon: LocationIconIdSchema
13546
13598
  });
13599
+ /**
13600
+ * One (location, description) assignment as it travels.
13601
+ *
13602
+ * Same key discipline as {@link LocationIconAssignmentSchema}, and for the same
13603
+ * reason: this lived for a while in the post-analysis addon's own settings,
13604
+ * keyed by a HAND-TYPED label matched exactly and case-sensitively. A rename in
13605
+ * the Locations page carried the icon and silently orphaned the description —
13606
+ * two authorities for one thing, joined by two different rules. Now both hang
13607
+ * off the location itself, on `locationIconKey`.
13608
+ */
13609
+ var LocationDescriptionAssignmentSchema = object({
13610
+ locationKey: string(),
13611
+ description: string()
13612
+ });
13613
+ /**
13614
+ * A SITE ZONE — a named part of the property that several locations belong to.
13615
+ *
13616
+ * "Zona notte" holds every bedroom; "Zona giorno" the living room and the
13617
+ * kitchen. A camera belongs to exactly one location, and a location to at most
13618
+ * one zone, so a camera's zone is derived and never stored on the device: the
13619
+ * whole point of this entity is that grouping rooms touches no device row.
13620
+ *
13621
+ * ## Why not `zone`
13622
+ *
13623
+ * Because `zone` is already the most loaded word in this product: 612 source
13624
+ * files and 24 Italian strings where it means a DETECTION zone drawn on a
13625
+ * camera. The two are unrelated — one is a polygon in a frame, the other is a
13626
+ * set of rooms — and a reader who confuses them will look for a camera's
13627
+ * bedrooms. So the code says `siteZone` everywhere, and the UI frees the plain
13628
+ * word by calling the drawn one what it actually is: a detection zone.
13629
+ *
13630
+ * ## The key
13631
+ *
13632
+ * `siteZoneKey(label)` — trimmed, lower-cased, the SAME derivation locations
13633
+ * use (`locationIconKey`). Membership and the icon both hang off it, so a
13634
+ * case-only rename keeps them, which is exactly the orphaning that cost us a
13635
+ * silently-dropped location description.
13636
+ *
13637
+ * The icon vocabulary is the location one, unchanged: a zone is drawn on the
13638
+ * same two surfaces by the same glyph map, so a second vocabulary would be a
13639
+ * second thing to keep drawable (`scripts/check-location-icons-drawable.ts`).
13640
+ */
13641
+ /**
13642
+ * One zone as it travels: its key, the label the operator typed, its icon and
13643
+ * the locations inside it.
13644
+ *
13645
+ * The LABEL is carried alongside the key because the key is lossy on purpose —
13646
+ * a surface must show "Zona notte", not "zona notte". Locations are carried
13647
+ * here, rather than left to a second call, because every consumer wants both
13648
+ * at once and a viewer that asked twice could render a zone whose membership
13649
+ * it has not fetched yet.
13650
+ *
13651
+ * `icon: null` means nobody chose one, which is NOT the fallback pin: only one
13652
+ * of those two is a choice, and a picker has to draw them differently.
13653
+ */
13654
+ var SiteZoneSchema = object({
13655
+ zoneKey: string(),
13656
+ label: string(),
13657
+ icon: LocationIconIdSchema.nullable(),
13658
+ /** Folded location keys, sorted. A location listed here need not be
13659
+ * REGISTERED — devices carry labels nobody registered, and those rooms are
13660
+ * the ones that most want grouping. */
13661
+ locationKeys: array(string())
13662
+ });
13547
13663
  var ProviderStatusSchema = object({
13548
13664
  connected: boolean(),
13549
13665
  deviceCount: number(),
@@ -14142,6 +14258,33 @@ method(object({
14142
14258
  }), _void(), {
14143
14259
  kind: "mutation",
14144
14260
  auth: "admin"
14261
+ }), method(_void(), array(LocationDescriptionAssignmentSchema)), method(object({
14262
+ location: string(),
14263
+ description: string().max(400).nullable()
14264
+ }), _void(), {
14265
+ kind: "mutation",
14266
+ auth: "admin"
14267
+ }), method(_void(), array(SiteZoneSchema)), method(object({
14268
+ name: string(),
14269
+ icon: LocationIconIdSchema.nullable().optional()
14270
+ }), _void(), {
14271
+ kind: "mutation",
14272
+ auth: "admin"
14273
+ }), method(object({ name: string() }), _void(), {
14274
+ kind: "mutation",
14275
+ auth: "admin"
14276
+ }), method(object({
14277
+ from: string(),
14278
+ to: string()
14279
+ }), _void(), {
14280
+ kind: "mutation",
14281
+ auth: "admin"
14282
+ }), method(object({
14283
+ location: string(),
14284
+ zone: string().nullable()
14285
+ }), _void(), {
14286
+ kind: "mutation",
14287
+ auth: "admin"
14145
14288
  }), method(object({
14146
14289
  deviceId: number(),
14147
14290
  disabled: boolean()
@@ -37164,6 +37307,12 @@ Object.freeze({
37164
37307
  addonId: null,
37165
37308
  access: "view"
37166
37309
  },
37310
+ "deviceManager.listLocationDescriptions": {
37311
+ capName: "device-manager",
37312
+ capScope: "system",
37313
+ addonId: null,
37314
+ access: "view"
37315
+ },
37167
37316
  "deviceManager.listLocationIcons": {
37168
37317
  capName: "device-manager",
37169
37318
  capScope: "system",
@@ -37182,6 +37331,12 @@ Object.freeze({
37182
37331
  addonId: null,
37183
37332
  access: "view"
37184
37333
  },
37334
+ "deviceManager.listSiteZones": {
37335
+ capName: "device-manager",
37336
+ capScope: "system",
37337
+ addonId: null,
37338
+ access: "view"
37339
+ },
37185
37340
  "deviceManager.listWrappersForCap": {
37186
37341
  capName: "device-manager",
37187
37342
  capScope: "system",
@@ -37266,12 +37421,24 @@ Object.freeze({
37266
37421
  addonId: null,
37267
37422
  access: "delete"
37268
37423
  },
37424
+ "deviceManager.removeSiteZone": {
37425
+ capName: "device-manager",
37426
+ capScope: "system",
37427
+ addonId: null,
37428
+ access: "delete"
37429
+ },
37269
37430
  "deviceManager.renameLocation": {
37270
37431
  capName: "device-manager",
37271
37432
  capScope: "system",
37272
37433
  addonId: null,
37273
37434
  access: "create"
37274
37435
  },
37436
+ "deviceManager.renameSiteZone": {
37437
+ capName: "device-manager",
37438
+ capScope: "system",
37439
+ addonId: null,
37440
+ access: "create"
37441
+ },
37275
37442
  "deviceManager.runDeviceAction": {
37276
37443
  capName: "device-manager",
37277
37444
  capScope: "system",
@@ -37314,12 +37481,24 @@ Object.freeze({
37314
37481
  addonId: null,
37315
37482
  access: "create"
37316
37483
  },
37484
+ "deviceManager.setLocationDescription": {
37485
+ capName: "device-manager",
37486
+ capScope: "system",
37487
+ addonId: null,
37488
+ access: "create"
37489
+ },
37317
37490
  "deviceManager.setLocationIcon": {
37318
37491
  capName: "device-manager",
37319
37492
  capScope: "system",
37320
37493
  addonId: null,
37321
37494
  access: "create"
37322
37495
  },
37496
+ "deviceManager.setLocationZone": {
37497
+ capName: "device-manager",
37498
+ capScope: "system",
37499
+ addonId: null,
37500
+ access: "create"
37501
+ },
37323
37502
  "deviceManager.setMetadata": {
37324
37503
  capName: "device-manager",
37325
37504
  capScope: "system",
@@ -37350,6 +37529,12 @@ Object.freeze({
37350
37529
  addonId: null,
37351
37530
  access: "create"
37352
37531
  },
37532
+ "deviceManager.setSiteZone": {
37533
+ capName: "device-manager",
37534
+ capScope: "system",
37535
+ addonId: null,
37536
+ access: "create"
37537
+ },
37353
37538
  "deviceManager.setStreamProfileMap": {
37354
37539
  capName: "device-manager",
37355
37540
  capScope: "system",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-wyze",
3
- "version": "0.2.110",
3
+ "version": "0.2.112",
4
4
  "description": "Wyze camera device-provider addon for CamStack — wraps the @apocaliss92/wyze-bridge-js P2P/DTLS client, feeding the stream-broker via the pull-rfc4571 lazy-publish path (a structural twin of addon-provider-reolink)",
5
5
  "keywords": [
6
6
  "camstack",