@camstack/types 0.1.33 → 0.1.35

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 (52) hide show
  1. package/dist/capabilities/addons.cap.d.ts +176 -3
  2. package/dist/capabilities/addons.cap.d.ts.map +1 -1
  3. package/dist/capabilities/device-export.cap.d.ts +55 -1
  4. package/dist/capabilities/device-export.cap.d.ts.map +1 -1
  5. package/dist/capabilities/index.d.ts +4 -11
  6. package/dist/capabilities/index.d.ts.map +1 -1
  7. package/dist/capabilities/local-network.cap.d.ts +5 -5
  8. package/dist/capabilities/mesh-network.cap.d.ts +8 -2
  9. package/dist/capabilities/mesh-network.cap.d.ts.map +1 -1
  10. package/dist/capabilities/network-access.cap.d.ts +5 -4
  11. package/dist/capabilities/network-access.cap.d.ts.map +1 -1
  12. package/dist/capabilities/nodes.cap.d.ts +13 -0
  13. package/dist/capabilities/nodes.cap.d.ts.map +1 -1
  14. package/dist/enums/event-category.d.ts +10 -0
  15. package/dist/enums/event-category.d.ts.map +1 -1
  16. package/dist/generated/addon-api.d.ts +356 -516
  17. package/dist/generated/addon-api.d.ts.map +1 -1
  18. package/dist/generated/capability-router-map.d.ts +2 -14
  19. package/dist/generated/capability-router-map.d.ts.map +1 -1
  20. package/dist/generated/method-access-map.d.ts +1 -1
  21. package/dist/generated/method-access-map.d.ts.map +1 -1
  22. package/dist/generated/system-proxy.d.ts +3 -9
  23. package/dist/generated/system-proxy.d.ts.map +1 -1
  24. package/dist/{index-DRWlYskM.js → index-BkSgJYP7.js} +202 -257
  25. package/dist/index-BkSgJYP7.js.map +1 -0
  26. package/dist/{index-YnRVILXN.mjs → index-CWhQOnm9.mjs} +521 -576
  27. package/dist/index-CWhQOnm9.mjs.map +1 -0
  28. package/dist/index.js +24 -69
  29. package/dist/index.js.map +1 -1
  30. package/dist/index.mjs +294 -339
  31. package/dist/index.mjs.map +1 -1
  32. package/dist/interfaces/addon.d.ts +21 -0
  33. package/dist/interfaces/addon.d.ts.map +1 -1
  34. package/dist/interfaces/capability.d.ts +1 -6
  35. package/dist/interfaces/capability.d.ts.map +1 -1
  36. package/dist/interfaces/event-bus.d.ts +21 -1
  37. package/dist/interfaces/event-bus.d.ts.map +1 -1
  38. package/dist/interfaces/server-network.d.ts +8 -33
  39. package/dist/interfaces/server-network.d.ts.map +1 -1
  40. package/dist/node.js +1 -1
  41. package/dist/node.mjs +1 -1
  42. package/package.json +6 -1
  43. package/dist/capabilities/authentication.cap.d.ts +0 -73
  44. package/dist/capabilities/authentication.cap.d.ts.map +0 -1
  45. package/dist/capabilities/mesh-orchestrator.cap.d.ts +0 -151
  46. package/dist/capabilities/mesh-orchestrator.cap.d.ts.map +0 -1
  47. package/dist/capabilities/remote-access.cap.d.ts +0 -91
  48. package/dist/capabilities/remote-access.cap.d.ts.map +0 -1
  49. package/dist/capabilities/turn-orchestrator.cap.d.ts +0 -64
  50. package/dist/capabilities/turn-orchestrator.cap.d.ts.map +0 -1
  51. package/dist/index-DRWlYskM.js.map +0 -1
  52. package/dist/index-YnRVILXN.mjs.map +0 -1
@@ -1,91 +0,0 @@
1
- import { z } from 'zod';
2
- import { type InferProvider } from './capability-definition.js';
3
- declare const RemoteAccessEndpointSchema: z.ZodObject<{
4
- url: z.ZodString;
5
- hostname: z.ZodString;
6
- port: z.ZodNumber;
7
- protocol: z.ZodEnum<{
8
- http: "http";
9
- https: "https";
10
- }>;
11
- }, z.core.$strip>;
12
- /**
13
- * Remote-access provider summary, surfaced to the admin UI's
14
- * "Remote Access" page. One row per registered `network-access`
15
- * provider (Cloudflare Tunnel, ngrok, Tailscale, etc.).
16
- */
17
- declare const RemoteAccessProviderInfoSchema: z.ZodObject<{
18
- addonId: z.ZodString;
19
- displayName: z.ZodString;
20
- enabled: z.ZodBoolean;
21
- connected: z.ZodBoolean;
22
- endpoint: z.ZodNullable<z.ZodObject<{
23
- url: z.ZodString;
24
- hostname: z.ZodString;
25
- port: z.ZodNumber;
26
- protocol: z.ZodEnum<{
27
- http: "http";
28
- https: "https";
29
- }>;
30
- }, z.core.$strip>>;
31
- error: z.ZodOptional<z.ZodString>;
32
- }, z.core.$strip>;
33
- export type RemoteAccessProviderInfo = z.infer<typeof RemoteAccessProviderInfoSchema>;
34
- /**
35
- * `remote-access` — singleton facade over the `network-access`
36
- * collection. Consumed by the admin UI's Remote Access page so an
37
- * operator can see at a glance which providers are configured, which
38
- * are connected, and which public endpoint each exposes.
39
- *
40
- * Mirrors the `authentication` / `turn-orchestrator` patterns: the
41
- * UI talks to the singleton, the singleton walks the collection.
42
- */
43
- export declare const remoteAccessCapability: {
44
- readonly name: "remote-access";
45
- readonly scope: "system";
46
- readonly mode: "singleton";
47
- readonly methods: {
48
- /** All registered remote-access providers + their live status. */
49
- readonly listProviders: import("./capability-definition.js").CapabilityMethodSchema<z.ZodVoid, z.ZodReadonly<z.ZodArray<z.ZodObject<{
50
- addonId: z.ZodString;
51
- displayName: z.ZodString;
52
- enabled: z.ZodBoolean;
53
- connected: z.ZodBoolean;
54
- endpoint: z.ZodNullable<z.ZodObject<{
55
- url: z.ZodString;
56
- hostname: z.ZodString;
57
- port: z.ZodNumber;
58
- protocol: z.ZodEnum<{
59
- http: "http";
60
- https: "https";
61
- }>;
62
- }, z.core.$strip>>;
63
- error: z.ZodOptional<z.ZodString>;
64
- }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
65
- /**
66
- * Start a specific provider's tunnel. Per-provider config still
67
- * lives on the addon's settings panel; this is just the on/off
68
- * trigger so the admin UI can manage the lifecycle from one place.
69
- */
70
- readonly startProvider: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
71
- addonId: z.ZodString;
72
- }, z.core.$strip>, z.ZodObject<{
73
- url: z.ZodString;
74
- hostname: z.ZodString;
75
- port: z.ZodNumber;
76
- protocol: z.ZodEnum<{
77
- http: "http";
78
- https: "https";
79
- }>;
80
- }, z.core.$strip>, "mutation">;
81
- /** Stop a specific provider's tunnel (idempotent on already-stopped). */
82
- readonly stopProvider: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
83
- addonId: z.ZodString;
84
- }, z.core.$strip>, z.ZodObject<{
85
- success: z.ZodLiteral<true>;
86
- }, z.core.$strip>, "mutation">;
87
- };
88
- };
89
- export type IRemoteAccessOrchestrator = InferProvider<typeof remoteAccessCapability>;
90
- export { RemoteAccessEndpointSchema, RemoteAccessProviderInfoSchema };
91
- //# sourceMappingURL=remote-access.cap.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"remote-access.cap.d.ts","sourceRoot":"","sources":["../../src/capabilities/remote-access.cap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAqC,KAAK,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAElG,QAAA,MAAM,0BAA0B;;;;;;;;iBAK9B,CAAA;AAEF;;;;GAIG;AACH,QAAA,MAAM,8BAA8B;;;;;;;;;;;;;;;iBAalC,CAAA;AAEF,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAA;AAErF;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB;;;;;QAK/B,kEAAkE;;;;;;;;;;;;;;;;;QAElE;;;;WAIG;;;;;;;;;;;;QAMH,yEAAyE;;;;;;;CAOpC,CAAA;AAEzC,MAAM,MAAM,yBAAyB,GAAG,aAAa,CAAC,OAAO,sBAAsB,CAAC,CAAA;AAEpF,OAAO,EAAE,0BAA0B,EAAE,8BAA8B,EAAE,CAAA"}
@@ -1,64 +0,0 @@
1
- import { z } from 'zod';
2
- import { type InferProvider } from './capability-definition.js';
3
- declare const TurnProviderInfoSchema: z.ZodObject<{
4
- addonId: z.ZodString;
5
- displayName: z.ZodString;
6
- enabled: z.ZodBoolean;
7
- serverCount: z.ZodNumber;
8
- urls: z.ZodReadonly<z.ZodArray<z.ZodString>>;
9
- error: z.ZodOptional<z.ZodString>;
10
- }, z.core.$strip>;
11
- export type TurnProviderInfo = z.infer<typeof TurnProviderInfoSchema>;
12
- /**
13
- * `turn-orchestrator` — singleton facade over the `turn-provider`
14
- * collection. Provides:
15
- * - listProviders() — admin UI inventory
16
- * - getAllServers() — combined list of TURN/STUN URLs across all
17
- * enabled providers (what the WebRTC layer actually consumes)
18
- *
19
- * Mirrors `authentication` / `remote-access` — UI consumers go
20
- * through the singleton, the singleton walks the collection.
21
- *
22
- * The WebRTC layer (broker / addon-go2rtc) historically called
23
- * `turn-provider` collection methods directly to build the ICE
24
- * server list per session. Going through this orchestrator instead
25
- * gives a single throughput point + lets the admin disable a
26
- * provider without uninstalling it.
27
- */
28
- export declare const turnOrchestratorCapability: {
29
- readonly name: "turn-orchestrator";
30
- readonly scope: "system";
31
- readonly mode: "singleton";
32
- readonly methods: {
33
- /** All registered TURN providers + per-provider stats. */
34
- readonly listProviders: import("./capability-definition.js").CapabilityMethodSchema<z.ZodVoid, z.ZodReadonly<z.ZodArray<z.ZodObject<{
35
- addonId: z.ZodString;
36
- displayName: z.ZodString;
37
- enabled: z.ZodBoolean;
38
- serverCount: z.ZodNumber;
39
- urls: z.ZodReadonly<z.ZodArray<z.ZodString>>;
40
- error: z.ZodOptional<z.ZodString>;
41
- }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
42
- /**
43
- * Combined list of TURN/STUN servers from all ENABLED providers.
44
- * Consumed by the WebRTC layer at session-creation time —
45
- * implementations may fetch fresh short-lived credentials each
46
- * call (e.g. Cloudflare API), so consumers SHOULD call per-session.
47
- */
48
- readonly getAllServers: import("./capability-definition.js").CapabilityMethodSchema<z.ZodVoid, z.ZodReadonly<z.ZodArray<z.ZodObject<{
49
- urls: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>;
50
- username: z.ZodOptional<z.ZodString>;
51
- credential: z.ZodOptional<z.ZodString>;
52
- }, z.core.$strip>>>, import("./capability-definition.js").CapabilityMethodKind>;
53
- /** Toggle a provider's enabled flag. */
54
- readonly setProviderEnabled: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
55
- addonId: z.ZodString;
56
- enabled: z.ZodBoolean;
57
- }, z.core.$strip>, z.ZodObject<{
58
- success: z.ZodLiteral<true>;
59
- }, z.core.$strip>, "mutation">;
60
- };
61
- };
62
- export type ITurnOrchestratorProvider = InferProvider<typeof turnOrchestratorCapability>;
63
- export { TurnProviderInfoSchema };
64
- //# sourceMappingURL=turn-orchestrator.cap.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"turn-orchestrator.cap.d.ts","sourceRoot":"","sources":["../../src/capabilities/turn-orchestrator.cap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAqC,KAAK,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAGlG,QAAA,MAAM,sBAAsB;;;;;;;iBAmB1B,CAAA;AAEF,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAA;AAErE;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,0BAA0B;;;;;QAKnC,0DAA0D;;;;;;;;;QAE1D;;;;;WAKG;;;;;;QAEH,wCAAwC;;;;;;;;CAOH,CAAA;AAEzC,MAAM,MAAM,yBAAyB,GAAG,aAAa,CAAC,OAAO,0BAA0B,CAAC,CAAA;AAExF,OAAO,EAAE,sBAAsB,EAAE,CAAA"}