@camstack/types 1.2.549 → 1.2.551

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.
Files changed (33) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist/addon/addon-instance.d.ts +23 -0
  3. package/dist/addon/build-addon-route-provider.d.ts +2 -0
  4. package/dist/addon.js +1 -1
  5. package/dist/addon.mjs +1 -1
  6. package/dist/automation/fired-trigger.d.ts +44 -0
  7. package/dist/automation/index.d.ts +8 -5
  8. package/dist/automation/recipe.d.ts +12105 -604
  9. package/dist/automation/scheduler.d.ts +7 -0
  10. package/dist/automation/step-runner.d.ts +70 -0
  11. package/dist/automation/trace.d.ts +254 -145
  12. package/dist/automation/wait-until.d.ts +32 -0
  13. package/dist/automation/when-site.d.ts +1 -1
  14. package/dist/automation/when.d.ts +39 -1
  15. package/dist/capabilities/actions.cap.d.ts +1 -178
  16. package/dist/capabilities/addon-routes.cap.d.ts +3 -0
  17. package/dist/capabilities/core-blocks.cap.d.ts +117 -8723
  18. package/dist/capabilities/event-emitter.cap.d.ts +99 -3
  19. package/dist/capabilities/event-vocabulary.d.ts +99 -0
  20. package/dist/capabilities/index.d.ts +1 -0
  21. package/dist/capabilities/oauth-integration.cap.d.ts +8 -0
  22. package/dist/capabilities/schedulers.cap.d.ts +1 -178
  23. package/dist/capabilities/sso-bridge.cap.d.ts +3 -0
  24. package/dist/capabilities/user-management.cap.d.ts +4 -0
  25. package/dist/generated/addon-cap-facts.d.ts +1 -1
  26. package/dist/index.d.ts +4 -2
  27. package/dist/index.js +1488 -156
  28. package/dist/index.mjs +1442 -157
  29. package/dist/interfaces/addon-routes.d.ts +13 -0
  30. package/dist/interfaces/config-ui.d.ts +15 -24
  31. package/dist/{sleep-Bn346wCJ.mjs → sleep-D0roI_CZ.mjs} +4 -0
  32. package/dist/{sleep-LFKpQ2_f.js → sleep-dcR4vBFG.js} +4 -0
  33. package/package.json +1 -1
@@ -8,6 +8,12 @@ export interface AddonHttpRequest {
8
8
  readonly query: Record<string, string>;
9
9
  readonly body: unknown;
10
10
  readonly headers: Record<string, string>;
11
+ /**
12
+ * The integration instance the request addresses, on a route declared
13
+ * `perInstance`. A path with no instance segment names the default instance,
14
+ * whose id is the addon id. Absent on every other route.
15
+ */
16
+ readonly instanceId?: string;
11
17
  /** Populated for 'authenticated' and 'admin' routes */
12
18
  readonly user?: {
13
19
  readonly id: string;
@@ -51,6 +57,13 @@ export interface IAddonHttpRoute {
51
57
  readonly access: RouteAccess;
52
58
  readonly description?: string;
53
59
  readonly rateLimit?: RouteRateLimit;
60
+ /**
61
+ * The route exists once per integration instance of the addon. The hub then
62
+ * serves it at `/addon/<addonId>/instances/<instanceId>/<path>` as well as at
63
+ * `/addon/<addonId>/<path>` (the default instance), and the handler reads
64
+ * which one from `request.instanceId`.
65
+ */
66
+ readonly perInstance?: boolean;
54
67
  readonly handler: (request: AddonHttpRequest, reply: AddonHttpReply) => Promise<void>;
55
68
  }
56
69
  /**
@@ -509,22 +509,21 @@ export interface ConfigNodeMultiSelectField extends ConfigFieldBase {
509
509
  maxItems?: number;
510
510
  }
511
511
  /**
512
- * Declarative, client-evaluated filter for `device-select` /
513
- * `device-multiselect`. The field carries ONLY this filter — the renderer
514
- * lists every system device (`deviceManager.listAll`) and narrows the
515
- * options CLIENT-SIDE. There is deliberately NO server-computed option
516
- * list (that path depended on `deviceManager.getAllBindings`, which returns
517
- * an empty set on the live cluster and left pickers blank).
512
+ * Declarative filter for `device-select` / `device-multiselect`. The field
513
+ * carries ONLY this filter; the renderer asks `deviceManager.search` for the
514
+ * devices that pass it. There is deliberately NO server-computed option list
515
+ * on the field (that path depended on `deviceManager.getAllBindings`, which
516
+ * returned an empty set on the live cluster and left pickers blank).
518
517
  *
519
- * Match rule (union — a device is kept when ANY provided clause matches;
520
- * an absent/empty filter matches every device):
521
- * - `caps` → the device's advertised `features` intersect this list.
518
+ * Match rule (every provided clause must hold; an absent/empty filter
519
+ * matches every device):
520
+ * - `caps` → the device provides ANY of these capabilities.
522
521
  * - `types` → the device's `type` is one of these.
523
- * `excludeDeviceId` is always subtracted last (typically the device whose
524
- * settings host the field — e.g. a camera must not list itself as a source).
522
+ * `excludeDeviceId` / `excludeTypes` are always subtracted (typically the
523
+ * device whose settings host the field — a camera must not list itself).
525
524
  */
526
525
  export interface DeviceSelectFilter {
527
- /** Keep devices whose `features` intersect ANY of these capability names. */
526
+ /** Keep devices that provide ANY of these capabilities. */
528
527
  readonly caps?: readonly string[];
529
528
  /** Keep devices whose `type` is one of these `DeviceType` strings. */
530
529
  readonly types?: readonly string[];
@@ -535,8 +534,8 @@ export interface DeviceSelectFilter {
535
534
  readonly excludeTypes?: readonly string[];
536
535
  }
537
536
  /**
538
- * Pick a SINGLE device from the live device catalogue. Options are the
539
- * result of `deviceManager.listAll` filtered client-side by `deviceFilter`.
537
+ * Pick a SINGLE device from the live device catalogue, narrowed by
538
+ * `deviceFilter` (see {@link DeviceSelectFilter}).
540
539
  * Stored value is the chosen device id as a string.
541
540
  */
542
541
  export interface ConfigDeviceSelectField extends ConfigFieldBase {
@@ -544,22 +543,14 @@ export interface ConfigDeviceSelectField extends ConfigFieldBase {
544
543
  deviceFilter?: DeviceSelectFilter;
545
544
  }
546
545
  /**
547
- * Pick MULTIPLE devices from the live device catalogue — the searchable
548
- * sibling of `device-select` (same client-side `deviceFilter`). Stored
546
+ * Pick MULTIPLE devices from the live device catalogue — the sibling of
547
+ * `device-select` (same `deviceFilter`). Stored
549
548
  * value is a `string[]` of device ids.
550
549
  */
551
550
  export interface ConfigDeviceMultiSelectField extends ConfigFieldBase {
552
551
  type: 'device-multiselect';
553
552
  deviceFilter?: DeviceSelectFilter;
554
553
  maxItems?: number;
555
- /**
556
- * Devices sharing this location are listed FIRST, under a "Suggested"
557
- * heading, and the location / type facet chips are shown — the shape the
558
- * linked-devices picker needs (D356): a catalogue of hundreds narrowed by
559
- * where and what before the free-text search, and the room's own devices
560
- * offered without being linked on anybody's behalf. `null` = no suggestion.
561
- */
562
- suggestLocation?: string | null;
563
554
  }
564
555
  /**
565
556
  * Pick a SINGLE `notification-output` target from the live catalog
@@ -13873,6 +13873,10 @@ var CAP_STATE_LEAVES = Object.freeze({
13873
13873
  "path": "lastEvent.eventType",
13874
13874
  "valueType": "string"
13875
13875
  },
13876
+ {
13877
+ "path": "lastEvent.sourceId",
13878
+ "valueType": "string"
13879
+ },
13876
13880
  {
13877
13881
  "path": "lastEvent.timestamp",
13878
13882
  "valueType": "number"
@@ -13873,6 +13873,10 @@ var CAP_STATE_LEAVES = Object.freeze({
13873
13873
  "path": "lastEvent.eventType",
13874
13874
  "valueType": "string"
13875
13875
  },
13876
+ {
13877
+ "path": "lastEvent.sourceId",
13878
+ "valueType": "string"
13879
+ },
13876
13880
  {
13877
13881
  "path": "lastEvent.timestamp",
13878
13882
  "valueType": "number"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/types",
3
- "version": "1.2.549",
3
+ "version": "1.2.551",
4
4
  "description": "Shared types, interfaces, and model catalogs for the CamStack detection ecosystem",
5
5
  "keywords": [
6
6
  "camstack",