@wave-av/sdk 2.0.0 → 2.0.2

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 (162) hide show
  1. package/CHANGELOG.md +1 -1
  2. package/README.md +27 -23
  3. package/dist/audience.js +93 -0
  4. package/dist/audience.mjs +9 -0
  5. package/dist/camera-control.js +95 -0
  6. package/dist/camera-control.mjs +71 -0
  7. package/dist/captions-types.js +18 -0
  8. package/dist/captions-types.mjs +0 -0
  9. package/dist/captions.js +266 -0
  10. package/dist/captions.mjs +9 -0
  11. package/dist/chapters-types.js +18 -0
  12. package/dist/chapters-types.mjs +0 -0
  13. package/dist/chapters.js +280 -0
  14. package/dist/chapters.mjs +9 -0
  15. package/dist/chunk-362MRITF.mjs +46 -0
  16. package/dist/chunk-3ZLK4J3V.mjs +69 -0
  17. package/dist/chunk-4DG4OBRD.mjs +52 -0
  18. package/dist/chunk-4G7FMCMJ.mjs +68 -0
  19. package/dist/chunk-4KD5F6E3.mjs +0 -0
  20. package/dist/chunk-7M6XVUUK.mjs +241 -0
  21. package/dist/chunk-A344OOT7.mjs +243 -0
  22. package/dist/chunk-AI64YR5W.mjs +173 -0
  23. package/dist/chunk-C2GQ756E.mjs +57 -0
  24. package/dist/chunk-CO2VB72Z.mjs +255 -0
  25. package/dist/chunk-DWXWAILB.mjs +44 -0
  26. package/dist/chunk-FLEFYLDM.mjs +71 -0
  27. package/dist/chunk-H2YYTNUH.mjs +266 -0
  28. package/dist/chunk-IGDBED5P.mjs +246 -0
  29. package/dist/chunk-IL2SGWBC.mjs +0 -0
  30. package/dist/chunk-IVFZ5X4W.mjs +68 -0
  31. package/dist/chunk-JC32PG3T.mjs +114 -0
  32. package/dist/chunk-K5X42NLD.mjs +54 -0
  33. package/dist/chunk-KCEPNS2U.mjs +276 -0
  34. package/dist/chunk-LVOVF6XC.mjs +54 -0
  35. package/dist/chunk-M4Z33V3N.mjs +247 -0
  36. package/dist/chunk-M6FKIX75.mjs +0 -0
  37. package/dist/chunk-M744Z327.mjs +244 -0
  38. package/dist/chunk-MRFDPPFK.mjs +61 -0
  39. package/dist/chunk-MXU3Q23F.mjs +68 -0
  40. package/dist/chunk-NCVUZ746.mjs +60 -0
  41. package/dist/chunk-NLQVD2LF.mjs +210 -0
  42. package/dist/chunk-O6DOGYP5.mjs +238 -0
  43. package/dist/chunk-S25NY5GE.mjs +124 -0
  44. package/dist/chunk-TFHXBICQ.mjs +305 -0
  45. package/dist/chunk-TXWOA2VR.mjs +57 -0
  46. package/dist/chunk-UCDSNV22.mjs +63 -0
  47. package/dist/chunk-V5DWA5P4.mjs +279 -0
  48. package/dist/chunk-VLQQDYGP.mjs +173 -0
  49. package/dist/chunk-VPKZUXZW.mjs +53 -0
  50. package/dist/chunk-WS3PEFYJ.mjs +60 -0
  51. package/dist/chunk-XGAYMWRH.mjs +74 -0
  52. package/dist/chunk-XMM5J57W.mjs +0 -0
  53. package/dist/chunk-XWABBOSX.mjs +278 -0
  54. package/dist/chunk-Y6FXYEAI.mjs +10 -0
  55. package/dist/chunk-YBLXHI3M.mjs +257 -0
  56. package/dist/chunk-YEK26SSO.mjs +100 -0
  57. package/dist/chunk-YLCQKCZL.mjs +0 -0
  58. package/dist/chunk-YRKO4XI7.mjs +0 -0
  59. package/dist/chunk-ZJO7AP4Q.mjs +0 -0
  60. package/dist/client-types.js +18 -0
  61. package/dist/client-types.mjs +0 -0
  62. package/dist/client.js +311 -0
  63. package/dist/client.mjs +14 -0
  64. package/dist/clips-types.js +18 -0
  65. package/dist/clips-types.mjs +0 -0
  66. package/dist/clips.js +198 -0
  67. package/dist/clips.mjs +9 -0
  68. package/dist/cloud-switcher.js +80 -0
  69. package/dist/cloud-switcher.mjs +56 -0
  70. package/dist/collab-types.js +18 -0
  71. package/dist/collab-types.mjs +1 -0
  72. package/dist/collab.js +304 -0
  73. package/dist/collab.mjs +10 -0
  74. package/dist/connect.js +85 -0
  75. package/dist/connect.mjs +9 -0
  76. package/dist/creator.js +79 -0
  77. package/dist/creator.mjs +9 -0
  78. package/dist/desktop.js +77 -0
  79. package/dist/desktop.mjs +9 -0
  80. package/dist/distribution.js +88 -0
  81. package/dist/distribution.mjs +9 -0
  82. package/dist/drm.js +85 -0
  83. package/dist/drm.mjs +9 -0
  84. package/dist/edge.js +93 -0
  85. package/dist/edge.mjs +9 -0
  86. package/dist/editor-types.js +18 -0
  87. package/dist/editor-types.mjs +1 -0
  88. package/dist/editor.js +330 -0
  89. package/dist/editor.mjs +10 -0
  90. package/dist/fleet.js +149 -0
  91. package/dist/fleet.mjs +9 -0
  92. package/dist/ghost.js +139 -0
  93. package/dist/ghost.mjs +9 -0
  94. package/dist/index.js +0 -250
  95. package/dist/index.mjs +161 -5445
  96. package/dist/marketplace.js +82 -0
  97. package/dist/marketplace.mjs +9 -0
  98. package/dist/mesh.js +198 -0
  99. package/dist/mesh.mjs +9 -0
  100. package/dist/notifications.js +79 -0
  101. package/dist/notifications.mjs +9 -0
  102. package/dist/phone-types.js +18 -0
  103. package/dist/phone-types.mjs +0 -0
  104. package/dist/phone.js +269 -0
  105. package/dist/phone.mjs +9 -0
  106. package/dist/pipeline-types.js +18 -0
  107. package/dist/pipeline-types.mjs +0 -0
  108. package/dist/pipeline.js +263 -0
  109. package/dist/pipeline.mjs +9 -0
  110. package/dist/podcast.js +94 -0
  111. package/dist/podcast.mjs +9 -0
  112. package/dist/prism.js +82 -0
  113. package/dist/prism.mjs +9 -0
  114. package/dist/prompter.js +99 -0
  115. package/dist/prompter.mjs +76 -0
  116. package/dist/pulse.js +99 -0
  117. package/dist/pulse.mjs +9 -0
  118. package/dist/qr.js +71 -0
  119. package/dist/qr.mjs +9 -0
  120. package/dist/replay.js +62 -0
  121. package/dist/replay.mjs +38 -0
  122. package/dist/scene-types.js +18 -0
  123. package/dist/scene-types.mjs +1 -0
  124. package/dist/scene.js +271 -0
  125. package/dist/scene.mjs +10 -0
  126. package/dist/search-types.js +18 -0
  127. package/dist/search-types.mjs +1 -0
  128. package/dist/search.js +268 -0
  129. package/dist/search.mjs +10 -0
  130. package/dist/sentiment-types.js +18 -0
  131. package/dist/sentiment-types.mjs +0 -0
  132. package/dist/sentiment.js +235 -0
  133. package/dist/sentiment.mjs +9 -0
  134. package/dist/signage.js +93 -0
  135. package/dist/signage.mjs +9 -0
  136. package/dist/slides.js +78 -0
  137. package/dist/slides.mjs +9 -0
  138. package/dist/studio-ai-types.js +18 -0
  139. package/dist/studio-ai-types.mjs +1 -0
  140. package/dist/studio-ai.js +301 -0
  141. package/dist/studio-ai.mjs +10 -0
  142. package/dist/studio-types.js +18 -0
  143. package/dist/studio-types.mjs +1 -0
  144. package/dist/studio.js +303 -0
  145. package/dist/studio.mjs +10 -0
  146. package/dist/telemetry.js +124 -0
  147. package/dist/telemetry.mjs +15 -0
  148. package/dist/transcribe-types.js +18 -0
  149. package/dist/transcribe-types.mjs +1 -0
  150. package/dist/transcribe.js +282 -0
  151. package/dist/transcribe.mjs +10 -0
  152. package/dist/usb.js +69 -0
  153. package/dist/usb.mjs +9 -0
  154. package/dist/vault.js +96 -0
  155. package/dist/vault.mjs +9 -0
  156. package/dist/voice-types.js +18 -0
  157. package/dist/voice-types.mjs +0 -0
  158. package/dist/voice.js +272 -0
  159. package/dist/voice.mjs +9 -0
  160. package/dist/zoom.js +86 -0
  161. package/dist/zoom.mjs +9 -0
  162. package/package.json +3 -3
@@ -0,0 +1,63 @@
1
+ // src/distribution.ts
2
+ var DistributionAPI = class {
3
+ client;
4
+ basePath = "/v1/distribution";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ async listDestinations(params) {
9
+ return this.client.get(`${this.basePath}/destinations`, {
10
+ params
11
+ });
12
+ }
13
+ async getDestination(destId) {
14
+ return this.client.get(`${this.basePath}/destinations/${destId}`);
15
+ }
16
+ async addDestination(request) {
17
+ return this.client.post(`${this.basePath}/destinations`, request);
18
+ }
19
+ async updateDestination(destId, updates) {
20
+ return this.client.patch(`${this.basePath}/destinations/${destId}`, updates);
21
+ }
22
+ async removeDestination(destId) {
23
+ await this.client.delete(`${this.basePath}/destinations/${destId}`);
24
+ }
25
+ async startSimulcast(streamId, destinationIds) {
26
+ return this.client.post(`${this.basePath}/simulcast`, {
27
+ stream_id: streamId,
28
+ destination_ids: destinationIds
29
+ });
30
+ }
31
+ async stopSimulcast(streamId) {
32
+ return this.client.post(`${this.basePath}/simulcast/stop`, {
33
+ stream_id: streamId
34
+ });
35
+ }
36
+ async getSimulcastStatus(streamId) {
37
+ return this.client.get(`${this.basePath}/simulcast/${streamId}`);
38
+ }
39
+ async schedulePost(request) {
40
+ return this.client.post(`${this.basePath}/posts`, request);
41
+ }
42
+ async listScheduledPosts(params) {
43
+ return this.client.get(`${this.basePath}/posts`, {
44
+ params
45
+ });
46
+ }
47
+ async cancelScheduledPost(postId) {
48
+ await this.client.delete(`${this.basePath}/posts/${postId}`);
49
+ }
50
+ async getDistributionAnalytics(params) {
51
+ return this.client.get(`${this.basePath}/analytics`, {
52
+ params
53
+ });
54
+ }
55
+ };
56
+ function createDistributionAPI(client) {
57
+ return new DistributionAPI(client);
58
+ }
59
+
60
+ export {
61
+ DistributionAPI,
62
+ createDistributionAPI
63
+ };
@@ -0,0 +1,279 @@
1
+ // src/collab.ts
2
+ var CollabAPI = class {
3
+ client;
4
+ basePath = "/v1/collab";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ // Rooms
9
+ /**
10
+ * Create a collaboration room
11
+ *
12
+ * Requires: collab:create permission
13
+ */
14
+ async createRoom(request) {
15
+ return this.client.post(`${this.basePath}/rooms`, request);
16
+ }
17
+ /**
18
+ * Get a room by ID
19
+ *
20
+ * Requires: collab:read permission
21
+ */
22
+ async getRoom(roomId) {
23
+ return this.client.get(`${this.basePath}/rooms/${roomId}`);
24
+ }
25
+ /**
26
+ * Update a room
27
+ *
28
+ * Requires: collab:update permission
29
+ */
30
+ async updateRoom(roomId, request) {
31
+ return this.client.patch(
32
+ `${this.basePath}/rooms/${roomId}`,
33
+ request
34
+ );
35
+ }
36
+ /**
37
+ * Close a room
38
+ *
39
+ * Requires: collab:manage permission
40
+ */
41
+ async closeRoom(roomId) {
42
+ return this.client.post(`${this.basePath}/rooms/${roomId}/close`);
43
+ }
44
+ /**
45
+ * Archive a room
46
+ *
47
+ * Requires: collab:manage permission (server-side RBAC enforced)
48
+ */
49
+ async archiveRoom(roomId) {
50
+ await this.client.delete(
51
+ `${this.basePath}/rooms/${roomId}`,
52
+ { method: "DELETE" }
53
+ );
54
+ }
55
+ /**
56
+ * List rooms
57
+ *
58
+ * Requires: collab:read permission
59
+ */
60
+ async listRooms(params) {
61
+ return this.client.get(
62
+ `${this.basePath}/rooms`,
63
+ { params }
64
+ );
65
+ }
66
+ /**
67
+ * Get join token for real-time connection
68
+ *
69
+ * Requires: collab:join permission
70
+ */
71
+ async getJoinToken(roomId, options) {
72
+ return this.client.post(`${this.basePath}/rooms/${roomId}/token`, options);
73
+ }
74
+ // Participants
75
+ /**
76
+ * List participants in a room
77
+ *
78
+ * Requires: collab:read permission
79
+ */
80
+ async listParticipants(roomId, params) {
81
+ return this.client.get(
82
+ `${this.basePath}/rooms/${roomId}/participants`,
83
+ { params }
84
+ );
85
+ }
86
+ /**
87
+ * Get a participant
88
+ *
89
+ * Requires: collab:read permission
90
+ */
91
+ async getParticipant(roomId, participantId) {
92
+ return this.client.get(
93
+ `${this.basePath}/rooms/${roomId}/participants/${participantId}`
94
+ );
95
+ }
96
+ /**
97
+ * Update a participant's role
98
+ *
99
+ * Requires: collab:manage permission
100
+ */
101
+ async updateParticipant(roomId, participantId, updates) {
102
+ return this.client.patch(
103
+ `${this.basePath}/rooms/${roomId}/participants/${participantId}`,
104
+ updates
105
+ );
106
+ }
107
+ /**
108
+ * Remove a participant from a room
109
+ *
110
+ * Requires: collab:manage permission (server-side RBAC enforced)
111
+ */
112
+ async removeParticipant(roomId, participantId) {
113
+ await this.client.delete(
114
+ `${this.basePath}/rooms/${roomId}/participants/${participantId}`,
115
+ { method: "DELETE" }
116
+ );
117
+ }
118
+ /**
119
+ * Invite users to a room
120
+ *
121
+ * Requires: collab:invite permission
122
+ */
123
+ async invite(roomId, invites) {
124
+ return this.client.post(`${this.basePath}/rooms/${roomId}/invite`, { invites });
125
+ }
126
+ // Comments
127
+ /**
128
+ * Add a comment
129
+ *
130
+ * Requires: collab:comment permission
131
+ */
132
+ async addComment(roomId, comment) {
133
+ return this.client.post(
134
+ `${this.basePath}/rooms/${roomId}/comments`,
135
+ comment
136
+ );
137
+ }
138
+ /**
139
+ * List comments
140
+ *
141
+ * Requires: collab:read permission
142
+ */
143
+ async listComments(roomId, params) {
144
+ return this.client.get(
145
+ `${this.basePath}/rooms/${roomId}/comments`,
146
+ { params }
147
+ );
148
+ }
149
+ /**
150
+ * Update a comment
151
+ *
152
+ * Requires: collab:comment permission (own comments) or collab:manage
153
+ */
154
+ async updateComment(roomId, commentId, updates) {
155
+ return this.client.patch(
156
+ `${this.basePath}/rooms/${roomId}/comments/${commentId}`,
157
+ updates
158
+ );
159
+ }
160
+ /**
161
+ * Remove a comment
162
+ *
163
+ * Requires: collab:comment permission (own) or collab:manage (server-side RBAC enforced)
164
+ */
165
+ async removeComment(roomId, commentId) {
166
+ await this.client.delete(
167
+ `${this.basePath}/rooms/${roomId}/comments/${commentId}`,
168
+ { method: "DELETE" }
169
+ );
170
+ }
171
+ /**
172
+ * Add a reaction to a comment
173
+ *
174
+ * Requires: collab:comment permission
175
+ */
176
+ async addReaction(roomId, commentId, emoji) {
177
+ return this.client.post(
178
+ `${this.basePath}/rooms/${roomId}/comments/${commentId}/reactions`,
179
+ { emoji }
180
+ );
181
+ }
182
+ /**
183
+ * Remove a reaction from a comment
184
+ *
185
+ * Requires: collab:comment permission (server-side RBAC enforced)
186
+ */
187
+ async removeReaction(roomId, commentId, emoji) {
188
+ await this.client.delete(
189
+ `${this.basePath}/rooms/${roomId}/comments/${commentId}/reactions`,
190
+ { method: "DELETE", params: { emoji } }
191
+ );
192
+ }
193
+ // Annotations
194
+ /**
195
+ * Add an annotation
196
+ *
197
+ * Requires: collab:annotate permission
198
+ */
199
+ async addAnnotation(roomId, annotation) {
200
+ return this.client.post(
201
+ `${this.basePath}/rooms/${roomId}/annotations`,
202
+ annotation
203
+ );
204
+ }
205
+ /**
206
+ * List annotations
207
+ *
208
+ * Requires: collab:read permission
209
+ */
210
+ async listAnnotations(roomId, params) {
211
+ return this.client.get(
212
+ `${this.basePath}/rooms/${roomId}/annotations`,
213
+ { params }
214
+ );
215
+ }
216
+ /**
217
+ * Update an annotation
218
+ *
219
+ * Requires: collab:annotate permission (own) or collab:manage
220
+ */
221
+ async updateAnnotation(roomId, annotationId, updates) {
222
+ return this.client.patch(
223
+ `${this.basePath}/rooms/${roomId}/annotations/${annotationId}`,
224
+ updates
225
+ );
226
+ }
227
+ /**
228
+ * Remove an annotation
229
+ *
230
+ * Requires: collab:annotate permission (own) or collab:manage (server-side RBAC enforced)
231
+ */
232
+ async removeAnnotation(roomId, annotationId) {
233
+ await this.client.delete(
234
+ `${this.basePath}/rooms/${roomId}/annotations/${annotationId}`,
235
+ { method: "DELETE" }
236
+ );
237
+ }
238
+ /**
239
+ * Clear all annotations
240
+ *
241
+ * Requires: collab:manage permission
242
+ */
243
+ async clearAnnotations(roomId) {
244
+ return this.client.post(`${this.basePath}/rooms/${roomId}/annotations/clear`);
245
+ }
246
+ // Recording
247
+ /**
248
+ * Start recording the collaboration session
249
+ *
250
+ * Requires: collab:record permission
251
+ */
252
+ async startRecording(roomId) {
253
+ return this.client.post(`${this.basePath}/rooms/${roomId}/recording/start`);
254
+ }
255
+ /**
256
+ * Stop recording
257
+ *
258
+ * Requires: collab:record permission
259
+ */
260
+ async stopRecording(roomId) {
261
+ return this.client.post(`${this.basePath}/rooms/${roomId}/recording/stop`);
262
+ }
263
+ /**
264
+ * Get recording status
265
+ *
266
+ * Requires: collab:read permission
267
+ */
268
+ async getRecordingStatus(roomId) {
269
+ return this.client.get(`${this.basePath}/rooms/${roomId}/recording`);
270
+ }
271
+ };
272
+ function createCollabAPI(client) {
273
+ return new CollabAPI(client);
274
+ }
275
+
276
+ export {
277
+ CollabAPI,
278
+ createCollabAPI
279
+ };
@@ -0,0 +1,173 @@
1
+ // src/mesh.ts
2
+ var MeshAPI = class {
3
+ client;
4
+ basePath = "/v1/mesh";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ // ==========================================================================
9
+ // Regions
10
+ // ==========================================================================
11
+ /**
12
+ * List mesh regions with optional filters
13
+ *
14
+ * Requires: mesh:read permission
15
+ */
16
+ async listRegions(params) {
17
+ const queryParams = {
18
+ limit: params?.limit,
19
+ offset: params?.offset,
20
+ cursor: params?.cursor,
21
+ status: params?.status,
22
+ provider: params?.provider
23
+ };
24
+ return this.client.get(`${this.basePath}/regions`, {
25
+ params: queryParams
26
+ });
27
+ }
28
+ /**
29
+ * Get a region by ID
30
+ *
31
+ * Requires: mesh:read permission
32
+ */
33
+ async getRegion(regionId) {
34
+ return this.client.get(`${this.basePath}/regions/${regionId}`);
35
+ }
36
+ /**
37
+ * Get health details for a region
38
+ *
39
+ * Requires: mesh:read permission
40
+ */
41
+ async getRegionHealth(regionId) {
42
+ return this.client.get(`${this.basePath}/regions/${regionId}/health`);
43
+ }
44
+ // ==========================================================================
45
+ // Peers
46
+ // ==========================================================================
47
+ /**
48
+ * List mesh peers, optionally filtered by region
49
+ *
50
+ * Requires: mesh:read permission
51
+ */
52
+ async listPeers(regionId) {
53
+ const queryParams = {
54
+ region_id: regionId
55
+ };
56
+ return this.client.get(`${this.basePath}/peers`, {
57
+ params: queryParams
58
+ });
59
+ }
60
+ /**
61
+ * Add a peer to a region
62
+ *
63
+ * Requires: mesh:create permission
64
+ */
65
+ async addPeer(regionId, endpoint) {
66
+ return this.client.post(`${this.basePath}/peers`, {
67
+ region_id: regionId,
68
+ endpoint
69
+ });
70
+ }
71
+ /**
72
+ * Remove a peer
73
+ *
74
+ * Requires: mesh:remove permission (server-side RBAC enforced)
75
+ */
76
+ async removePeer(peerId) {
77
+ await this.client.delete(`${this.basePath}/peers/${peerId}`);
78
+ }
79
+ // ==========================================================================
80
+ // Failover Policies
81
+ // ==========================================================================
82
+ /**
83
+ * Create a failover policy
84
+ *
85
+ * Requires: mesh:create permission
86
+ */
87
+ async createPolicy(request) {
88
+ return this.client.post(`${this.basePath}/policies`, request);
89
+ }
90
+ /**
91
+ * Update a failover policy
92
+ *
93
+ * Requires: mesh:update permission
94
+ */
95
+ async updatePolicy(policyId, updates) {
96
+ return this.client.patch(`${this.basePath}/policies/${policyId}`, updates);
97
+ }
98
+ /**
99
+ * Remove a failover policy
100
+ *
101
+ * Requires: mesh:remove permission (server-side RBAC enforced)
102
+ */
103
+ async removePolicy(policyId) {
104
+ await this.client.delete(`${this.basePath}/policies/${policyId}`);
105
+ }
106
+ /**
107
+ * List failover policies
108
+ *
109
+ * Requires: mesh:read permission
110
+ */
111
+ async listPolicies(params) {
112
+ return this.client.get(`${this.basePath}/policies`, {
113
+ params
114
+ });
115
+ }
116
+ // ==========================================================================
117
+ // Failover Operations
118
+ // ==========================================================================
119
+ /**
120
+ * Trigger a manual failover to a target region
121
+ *
122
+ * Requires: mesh:failover permission
123
+ */
124
+ async triggerFailover(policyId, targetRegion) {
125
+ return this.client.post(`${this.basePath}/policies/${policyId}/failover`, {
126
+ target_region: targetRegion
127
+ });
128
+ }
129
+ /**
130
+ * Get failover event history for a policy
131
+ *
132
+ * Requires: mesh:read permission
133
+ */
134
+ async getFailoverHistory(policyId, params) {
135
+ return this.client.get(
136
+ `${this.basePath}/policies/${policyId}/events`,
137
+ { params }
138
+ );
139
+ }
140
+ // ==========================================================================
141
+ // Replication & Topology
142
+ // ==========================================================================
143
+ /**
144
+ * Get replication status between regions
145
+ *
146
+ * Requires: mesh:read permission
147
+ */
148
+ async getReplicationStatus(sourceRegion, targetRegion) {
149
+ const queryParams = {
150
+ source_region: sourceRegion,
151
+ target_region: targetRegion
152
+ };
153
+ return this.client.get(`${this.basePath}/replication`, {
154
+ params: queryParams
155
+ });
156
+ }
157
+ /**
158
+ * Get the full mesh topology (regions, peers, and policies)
159
+ *
160
+ * Requires: mesh:read permission
161
+ */
162
+ async getTopology() {
163
+ return this.client.get(`${this.basePath}/topology`);
164
+ }
165
+ };
166
+ function createMeshAPI(client) {
167
+ return new MeshAPI(client);
168
+ }
169
+
170
+ export {
171
+ MeshAPI,
172
+ createMeshAPI
173
+ };
@@ -0,0 +1,53 @@
1
+ // src/slides.ts
2
+ var SlidesAPI = class {
3
+ client;
4
+ basePath = "/v1/slides";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ async convert(request) {
9
+ return this.client.post(this.basePath, request);
10
+ }
11
+ async get(conversionId) {
12
+ return this.client.get(`${this.basePath}/${conversionId}`);
13
+ }
14
+ async list(params) {
15
+ return this.client.get(this.basePath, {
16
+ params
17
+ });
18
+ }
19
+ async remove(conversionId) {
20
+ await this.client.delete(`${this.basePath}/${conversionId}`);
21
+ }
22
+ async getProgress(conversionId) {
23
+ return this.client.get(
24
+ `${this.basePath}/${conversionId}/progress`
25
+ );
26
+ }
27
+ async addNarration(conversionId, narrations) {
28
+ return this.client.post(`${this.basePath}/${conversionId}/narration`, {
29
+ narrations
30
+ });
31
+ }
32
+ async waitForReady(conversionId, options) {
33
+ const pollInterval = options?.pollInterval || 3e3;
34
+ const timeout = options?.timeout || 6e5;
35
+ const startTime = Date.now();
36
+ while (Date.now() - startTime < timeout) {
37
+ const conversion = await this.get(conversionId);
38
+ if (conversion.status === "ready") return conversion;
39
+ if (conversion.status === "failed")
40
+ throw new Error(`Conversion failed: ${conversion.error || "Unknown"}`);
41
+ await new Promise((r) => setTimeout(r, pollInterval));
42
+ }
43
+ throw new Error(`Conversion timed out after ${timeout}ms`);
44
+ }
45
+ };
46
+ function createSlidesAPI(client) {
47
+ return new SlidesAPI(client);
48
+ }
49
+
50
+ export {
51
+ SlidesAPI,
52
+ createSlidesAPI
53
+ };
@@ -0,0 +1,60 @@
1
+ // src/drm.ts
2
+ var DrmAPI = class {
3
+ client;
4
+ basePath = "/v1/drm";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ /** Create a DRM policy. */
9
+ async createPolicy(request) {
10
+ return this.client.post(`${this.basePath}/policies`, request);
11
+ }
12
+ /** Get a DRM policy by ID. */
13
+ async getPolicy(policyId) {
14
+ return this.client.get(`${this.basePath}/policies/${policyId}`);
15
+ }
16
+ /** List DRM policies. */
17
+ async listPolicies(params) {
18
+ return this.client.get(`${this.basePath}/policies`, {
19
+ params
20
+ });
21
+ }
22
+ /** Update a DRM policy. */
23
+ async updatePolicy(policyId, updates) {
24
+ return this.client.patch(`${this.basePath}/policies/${policyId}`, updates);
25
+ }
26
+ /** Delete a DRM policy. */
27
+ async removePolicy(policyId) {
28
+ await this.client.delete(`${this.basePath}/policies/${policyId}`);
29
+ }
30
+ /** Get a DRM certificate for a provider. */
31
+ async getCertificate(provider) {
32
+ return this.client.get(`${this.basePath}/certificate/${provider}`);
33
+ }
34
+ /** Issue a license for an asset. */
35
+ async issueLicense(assetId, policyId, deviceId) {
36
+ return this.client.post(`${this.basePath}/license`, {
37
+ asset_id: assetId,
38
+ policy_id: policyId,
39
+ device_id: deviceId
40
+ });
41
+ }
42
+ /** Revoke a license. */
43
+ async revokeLicense(licenseId) {
44
+ return this.client.post(`${this.basePath}/license/${licenseId}/revoke`);
45
+ }
46
+ /** List licenses for an asset or user. */
47
+ async listLicenses(params) {
48
+ return this.client.get(`${this.basePath}/licenses`, {
49
+ params
50
+ });
51
+ }
52
+ };
53
+ function createDrmAPI(client) {
54
+ return new DrmAPI(client);
55
+ }
56
+
57
+ export {
58
+ DrmAPI,
59
+ createDrmAPI
60
+ };
@@ -0,0 +1,74 @@
1
+ // src/pulse.ts
2
+ var PulseAPI = class {
3
+ client;
4
+ basePath = "/v1/analytics";
5
+ constructor(client) {
6
+ this.client = client;
7
+ }
8
+ async getStreamAnalytics(streamId, params) {
9
+ return this.client.get(`${this.basePath}/streams/${streamId}`, {
10
+ params
11
+ });
12
+ }
13
+ async getViewerAnalytics(params) {
14
+ return this.client.get(`${this.basePath}/viewers`, {
15
+ params
16
+ });
17
+ }
18
+ async getQualityMetrics(params) {
19
+ return this.client.get(`${this.basePath}/quality`, {
20
+ params
21
+ });
22
+ }
23
+ async getEngagementMetrics(params) {
24
+ return this.client.get(`${this.basePath}/engagement`, {
25
+ params
26
+ });
27
+ }
28
+ async getRevenueMetrics(params) {
29
+ return this.client.get(`${this.basePath}/revenue`, {
30
+ params
31
+ });
32
+ }
33
+ async getTimeSeries(metric, params) {
34
+ return this.client.get(`${this.basePath}/timeseries/${metric}`, {
35
+ params
36
+ });
37
+ }
38
+ async createReport(request) {
39
+ return this.client.post(`${this.basePath}/reports`, request);
40
+ }
41
+ async getReport(reportId) {
42
+ return this.client.get(`${this.basePath}/reports/${reportId}`);
43
+ }
44
+ async listReports(params) {
45
+ return this.client.get(`${this.basePath}/reports`, {
46
+ params
47
+ });
48
+ }
49
+ async listDashboards(params) {
50
+ return this.client.get(`${this.basePath}/dashboards`, {
51
+ params
52
+ });
53
+ }
54
+ async createDashboard(request) {
55
+ return this.client.post(`${this.basePath}/dashboards`, request);
56
+ }
57
+ async getDashboard(dashboardId) {
58
+ return this.client.get(`${this.basePath}/dashboards/${dashboardId}`);
59
+ }
60
+ async updateDashboard(dashboardId, updates) {
61
+ return this.client.patch(`${this.basePath}/dashboards/${dashboardId}`, updates);
62
+ }
63
+ async removeDashboard(dashboardId) {
64
+ await this.client.delete(`${this.basePath}/dashboards/${dashboardId}`);
65
+ }
66
+ };
67
+ function createPulseAPI(client) {
68
+ return new PulseAPI(client);
69
+ }
70
+
71
+ export {
72
+ PulseAPI,
73
+ createPulseAPI
74
+ };
File without changes