@gravity-rail/sdk 0.36.1 → 0.40.0

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 (57) hide show
  1. package/README.md +44 -21
  2. package/dist/agui.d.cts +1 -1
  3. package/dist/agui.d.ts +1 -1
  4. package/dist/audio.d.cts +1 -1
  5. package/dist/audio.d.ts +1 -1
  6. package/dist/{chat-interaction-CbkSPz3m.d.cts → chat-interaction-BB3ap8_u.d.ts} +8866 -6155
  7. package/dist/{chat-interaction-DqjEfj7G.d.ts → chat-interaction-Bj1pciwo.d.cts} +8866 -6155
  8. package/dist/{chunk-P2E6LU7I.js → chunk-67QXTQVL.js} +1 -26
  9. package/dist/chunk-67QXTQVL.js.map +1 -0
  10. package/dist/chunk-6KPGCPGW.js +48 -0
  11. package/dist/chunk-6KPGCPGW.js.map +1 -0
  12. package/dist/{chunk-HRUMZ46V.js → chunk-72SWNLVD.js} +2 -1
  13. package/dist/chunk-72SWNLVD.js.map +1 -0
  14. package/dist/{chunk-R6S5RXW5.js → chunk-ZTUOB4V2.js} +1255 -201
  15. package/dist/chunk-ZTUOB4V2.js.map +1 -0
  16. package/dist/helpers.cjs +47 -0
  17. package/dist/helpers.cjs.map +1 -1
  18. package/dist/helpers.d.cts +4 -3
  19. package/dist/helpers.d.ts +4 -3
  20. package/dist/helpers.js +7 -1
  21. package/dist/helpers.js.map +1 -1
  22. package/dist/index.cjs +1365 -330
  23. package/dist/index.cjs.map +1 -1
  24. package/dist/index.d.cts +13 -35
  25. package/dist/index.d.ts +13 -35
  26. package/dist/index.js +110 -116
  27. package/dist/index.js.map +1 -1
  28. package/dist/internal.cjs +1279 -232
  29. package/dist/internal.cjs.map +1 -1
  30. package/dist/internal.d.cts +338 -79
  31. package/dist/internal.d.ts +338 -79
  32. package/dist/internal.js +66 -15
  33. package/dist/internal.js.map +1 -1
  34. package/dist/member-import-D8fZr2Pd.d.cts +46 -0
  35. package/dist/member-import-YNk9MlEl.d.ts +46 -0
  36. package/dist/realtime.cjs +91 -20
  37. package/dist/realtime.cjs.map +1 -1
  38. package/dist/realtime.d.cts +34 -9
  39. package/dist/realtime.d.ts +34 -9
  40. package/dist/realtime.js +90 -20
  41. package/dist/realtime.js.map +1 -1
  42. package/dist/{revision-state-92LHz1jQ.d.ts → revision-state-BaJTq3Or.d.ts} +270 -54
  43. package/dist/{revision-state-CSQ7J3ZU.d.cts → revision-state-CL11FA-T.d.cts} +270 -54
  44. package/dist/schemas.cjs +58 -81
  45. package/dist/schemas.cjs.map +1 -1
  46. package/dist/schemas.d.cts +88 -225
  47. package/dist/schemas.d.ts +88 -225
  48. package/dist/schemas.js +58 -76
  49. package/dist/schemas.js.map +1 -1
  50. package/dist/{tasks-CrF1qC4G.d.cts → tasks-ByJCQ5BI.d.cts} +2995 -2507
  51. package/dist/{tasks-CrF1qC4G.d.ts → tasks-ByJCQ5BI.d.ts} +2995 -2507
  52. package/dist/{types-0c6_NGU4.d.cts → types-DlfADjPR.d.cts} +17 -2
  53. package/dist/{types-0c6_NGU4.d.ts → types-DlfADjPR.d.ts} +17 -2
  54. package/package.json +9 -7
  55. package/dist/chunk-HRUMZ46V.js.map +0 -1
  56. package/dist/chunk-P2E6LU7I.js.map +0 -1
  57. package/dist/chunk-R6S5RXW5.js.map +0 -1
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  ApiError,
3
3
  BaseApiClient
4
- } from "./chunk-P2E6LU7I.js";
4
+ } from "./chunk-67QXTQVL.js";
5
5
 
6
6
  // src/api/abilities.ts
7
7
  var AbilitiesApi = class extends BaseApiClient {
@@ -71,6 +71,299 @@ var AbilitiesApi = class extends BaseApiClient {
71
71
  }
72
72
  };
73
73
 
74
+ // src/api/resource-workflows.ts
75
+ function resourceWorkflowsPath(wid, ...segments) {
76
+ const tail = segments.map((segment) => encodeURIComponent(String(segment))).join("/");
77
+ const base = `w/${encodeURIComponent(wid)}/resource-workflows`;
78
+ return tail ? `${base}/${tail}` : base;
79
+ }
80
+ var ResourceWorkflowsApi = class extends BaseApiClient {
81
+ /** One Workflow's summary, for a viewer that can see it. */
82
+ async getResourceWorkflow(wid, workflowUuid) {
83
+ return this.fetch(resourceWorkflowsPath(wid, workflowUuid));
84
+ }
85
+ /**
86
+ * One published revision.
87
+ *
88
+ * The response is a union: the owner (or a `full` grantee) receives the
89
+ * complete `ResourceWorkflowGraphResponse`, while a bounded grantee receives
90
+ * the `ResourceWorkflowDisclosureResponse` envelope. Branch on `publishedAt`
91
+ * being present — never assume the full shape. A retained revision stays
92
+ * readable here after a `stop_updates` revocation.
93
+ */
94
+ async getResourceWorkflowRevision(wid, workflowUuid, revisionUuid) {
95
+ return this.fetch(
96
+ resourceWorkflowsPath(wid, workflowUuid, "revisions", revisionUuid)
97
+ );
98
+ }
99
+ /**
100
+ * List published Workflows owned by or shared with this workspace.
101
+ *
102
+ * The Bundle draft editor reads `publishedRevisionUuid` from each summary to
103
+ * pin a Workflow item; archived Workflows are excluded unless asked for.
104
+ */
105
+ async listResourceWorkflows(wid, params) {
106
+ const query = new URLSearchParams();
107
+ if (params?.page !== void 0) query.set("page", String(params.page));
108
+ if (params?.pageSize !== void 0) query.set("pageSize", String(params.pageSize));
109
+ if (params?.includeArchived !== void 0) {
110
+ query.set("includeArchived", String(params.includeArchived));
111
+ }
112
+ const qs = query.toString();
113
+ return this.fetch(
114
+ `w/${encodeURIComponent(wid)}/resource-workflows${qs ? `?${qs}` : ""}`
115
+ );
116
+ }
117
+ };
118
+
119
+ // src/api/bundles.ts
120
+ function bundlesPath(wid, ...segments) {
121
+ const tail = segments.map((segment) => encodeURIComponent(String(segment))).join("/");
122
+ const base = `w/${encodeURIComponent(wid)}/bundles`;
123
+ return tail ? `${base}/${tail}` : base;
124
+ }
125
+ function pageQuery(params) {
126
+ const query = new URLSearchParams();
127
+ if (params?.page !== void 0) query.set("page", String(params.page));
128
+ if (params?.pageSize !== void 0) query.set("pageSize", String(params.pageSize));
129
+ const qs = query.toString();
130
+ return qs ? `?${qs}` : "";
131
+ }
132
+ var BundlesApi = class extends BaseApiClient {
133
+ /** Official solution metadata, independent of the default workspace Library. */
134
+ async getSolutionRelease(slug) {
135
+ return this.fetch(`solutions/${encodeURIComponent(slug)}`);
136
+ }
137
+ /** Read an authorized Bundle by UUID, including official solutions hidden from discovery. */
138
+ async getBundle(wid, bundleUuid) {
139
+ return this.fetch(bundlesPath(wid, bundleUuid));
140
+ }
141
+ async updateBundle(wid, bundleUuid, data) {
142
+ return this.fetch(
143
+ `w/${encodeURIComponent(wid)}/bundles/${encodeURIComponent(bundleUuid)}`,
144
+ {
145
+ method: "PATCH",
146
+ body: JSON.stringify(data)
147
+ }
148
+ );
149
+ }
150
+ async listBundleInstallations(wid, bundleUuid) {
151
+ return this.fetch(
152
+ `w/${encodeURIComponent(wid)}/bundles/${encodeURIComponent(bundleUuid)}/installations`
153
+ );
154
+ }
155
+ /**
156
+ * Bundles visible to this workspace through ownership, a live grant, or
157
+ * an administrator of the owning organization.
158
+ */
159
+ async listBundles(wid, params) {
160
+ return this.fetch(`${bundlesPath(wid)}${pageQuery(params)}`);
161
+ }
162
+ /**
163
+ * This workspace's Workflows for the Bundle picker. `eligible` pins
164
+ * `revisionUuid` (the active revision when published, else the newest
165
+ * published one); `unpublished` has nothing to pin. `dependenciesChecked` is
166
+ * false until a Bundle add has stored the revision's dependencies; that add
167
+ * surfaces any refusal as a 409 `workflow_not_shareable`. Requires
168
+ * `workflows:admin`.
169
+ */
170
+ async listBundleWorkflowCandidates(wid) {
171
+ return this.fetch(bundlesPath(wid, "workflow-candidates"));
172
+ }
173
+ /** Create an empty Bundle owned by this workspace. */
174
+ async createBundle(wid, data) {
175
+ return this.fetch(bundlesPath(wid), {
176
+ method: "POST",
177
+ body: JSON.stringify(data)
178
+ });
179
+ }
180
+ /**
181
+ * The unpublished draft for the owning workspace. A grantee is refused with
182
+ * 404: `version_detail` checks
183
+ * `root.workspace_uuid != viewer.workspace_uuid` for the null version
184
+ * (`lib/db/resources/bundles.py`), after the grantee-inclusive predicate has
185
+ * already admitted them to the Bundle itself.
186
+ *
187
+ * After publication, the next draft contains a copy of the published items.
188
+ * The owner receives it with 200; a grantee receives 404.
189
+ */
190
+ async getBundleDraft(wid, bundleUuid) {
191
+ return this.fetch(bundlesPath(wid, bundleUuid, "draft"));
192
+ }
193
+ /** Replace the whole draft item list. 409 when `expectedGeneration` is stale. */
194
+ async replaceBundleDraft(wid, bundleUuid, data) {
195
+ return this.fetch(bundlesPath(wid, bundleUuid, "draft"), {
196
+ method: "PUT",
197
+ body: JSON.stringify(data)
198
+ });
199
+ }
200
+ /** Cut a new immutable version from the draft. 409 when `expectedGeneration` is stale. */
201
+ async publishBundle(wid, bundleUuid, data) {
202
+ return this.fetch(bundlesPath(wid, bundleUuid, "publish"), {
203
+ method: "POST",
204
+ body: JSON.stringify(data)
205
+ });
206
+ }
207
+ /** Published versions, newest first. */
208
+ async listBundleVersions(wid, bundleUuid, params) {
209
+ return this.fetch(
210
+ `${bundlesPath(wid, bundleUuid, "versions")}${pageQuery(params)}`
211
+ );
212
+ }
213
+ /** One published version, with its items, declared settings and open slots. */
214
+ async getBundleVersion(wid, bundleUuid, version) {
215
+ return this.fetch(bundlesPath(wid, bundleUuid, "versions", version));
216
+ }
217
+ /** Who this Bundle is currently granted to. */
218
+ async listBundleGrants(wid, bundleUuid) {
219
+ return this.fetch(bundlesPath(wid, bundleUuid, "grants"));
220
+ }
221
+ /**
222
+ * Share throughout the publisher's organization with organization-admin authority.
223
+ * Workspace-specific and global author grants are refused. Official public
224
+ * solutions use the separate staff approval API.
225
+ */
226
+ async grantBundle(wid, bundleUuid, data) {
227
+ return this.fetch(bundlesPath(wid, bundleUuid, "grants"), {
228
+ method: "POST",
229
+ body: JSON.stringify(data)
230
+ });
231
+ }
232
+ /** Revoke one grant by id. */
233
+ async revokeBundleGrant(wid, bundleUuid, grantId) {
234
+ return this.fetch(bundlesPath(wid, bundleUuid, "grants", grantId), {
235
+ method: "DELETE"
236
+ });
237
+ }
238
+ };
239
+
240
+ // src/api/installations.ts
241
+ function installationsPath(wid, ...segments) {
242
+ const tail = segments.map((segment) => encodeURIComponent(String(segment))).join("/");
243
+ const base = `w/${encodeURIComponent(wid)}/installations`;
244
+ return tail ? `${base}/${tail}` : base;
245
+ }
246
+ var InstallationsApi = class extends BaseApiClient {
247
+ /** Inspect one published release and its selected example dependencies. */
248
+ async preflightBundleInstallation(wid, bundleUuid, data) {
249
+ return this.fetch(
250
+ `w/${encodeURIComponent(wid)}/bundles/${encodeURIComponent(bundleUuid)}/installation-preflight`,
251
+ { method: "POST", body: JSON.stringify(data) }
252
+ );
253
+ }
254
+ /**
255
+ * Install a published Bundle version into this workspace.
256
+ *
257
+ * A key in `bindings` that this version has no slot or Form item for is
258
+ * refused; a **missing** required slot is not.
259
+ */
260
+ async installBundle(wid, bundleUuid, data) {
261
+ return this.fetch(
262
+ `w/${encodeURIComponent(wid)}/bundles/${encodeURIComponent(bundleUuid)}/installations`,
263
+ { method: "POST", body: JSON.stringify(data) }
264
+ );
265
+ }
266
+ /** Every installation this workspace holds, oldest first. */
267
+ async listInstallations(wid) {
268
+ return this.fetch(installationsPath(wid));
269
+ }
270
+ async getInstallation(wid, installationUuid) {
271
+ return this.fetch(installationsPath(wid, installationUuid));
272
+ }
273
+ /**
274
+ * Open slots, bindings whose target no longer resolves, Forms that drifted
275
+ * from their recipe, missing or changed Workflow dependencies, and archived
276
+ * items. Computed on read, never stored.
277
+ */
278
+ async getInstallationReadiness(wid, installationUuid) {
279
+ return this.fetch(
280
+ installationsPath(wid, installationUuid, "readiness")
281
+ );
282
+ }
283
+ /**
284
+ * What moving to version `to` would change: per-item differences, the slots
285
+ * that would still be unbound, and the release notes of every version in
286
+ * between. `to` must be newer than the version the installation holds.
287
+ */
288
+ async previewInstallationUpgrade(wid, installationUuid, to) {
289
+ const query = new URLSearchParams({ to: String(to) });
290
+ return this.fetch(
291
+ `${installationsPath(wid, installationUuid, "upgrade-preview")}?${query.toString()}`
292
+ );
293
+ }
294
+ /**
295
+ * Move the installation onto a newer published version. The version it
296
+ * already holds, and any earlier one, are refused with 409.
297
+ */
298
+ async upgradeInstallation(wid, installationUuid, data) {
299
+ return this.fetch(installationsPath(wid, installationUuid, "upgrade"), {
300
+ method: "POST",
301
+ body: JSON.stringify(data)
302
+ });
303
+ }
304
+ /** Recreate one deleted Form from the version already installed. */
305
+ async restoreInstallationForm(wid, installationUuid, data) {
306
+ return this.fetch(
307
+ installationsPath(wid, installationUuid, "restore-form"),
308
+ {
309
+ method: "POST",
310
+ body: JSON.stringify(data)
311
+ }
312
+ );
313
+ }
314
+ /** Recreate missing dependency resources for an installed Workflow. */
315
+ async restoreInstallationWorkflowResources(wid, installationUuid, data) {
316
+ return this.fetch(
317
+ installationsPath(wid, installationUuid, "restore-workflow-resources"),
318
+ { method: "POST", body: JSON.stringify(data) }
319
+ );
320
+ }
321
+ /** `pinned` holds the installed version; `auto` follows each publication. */
322
+ async setInstallationPolicy(wid, installationUuid, data) {
323
+ return this.fetch(installationsPath(wid, installationUuid), {
324
+ method: "PATCH",
325
+ body: JSON.stringify(data)
326
+ });
327
+ }
328
+ /** Stop future Bundle updates while keeping the workspace's installed content. */
329
+ async unsubscribeInstallation(wid, installationUuid) {
330
+ return this.fetch(
331
+ installationsPath(wid, installationUuid, "unsubscribe"),
332
+ { method: "POST", body: JSON.stringify({}) }
333
+ );
334
+ }
335
+ /** Fill open slots. A slot that already carries a target is refused with 409. */
336
+ async bindInstallationSlots(wid, installationUuid, data) {
337
+ return this.fetch(
338
+ installationsPath(wid, installationUuid, "bindings"),
339
+ { method: "POST", body: JSON.stringify(data) }
340
+ );
341
+ }
342
+ /**
343
+ * Settle an installation left `pending` by an interrupted operation.
344
+ *
345
+ * The body is empty and required: a bodyless cookie-auth POST is forgeable
346
+ * by a cross-site form, so the route demands JSON.
347
+ */
348
+ async reconcileInstallation(wid, installationUuid) {
349
+ return this.fetch(
350
+ installationsPath(wid, installationUuid, "reconcile"),
351
+ { method: "POST", body: JSON.stringify({}) }
352
+ );
353
+ }
354
+ /**
355
+ * The settings a compiled theme declares, for labelling a Site item's slots
356
+ * before any Site exists. 404 for an unknown slug and for `source-site`,
357
+ * whose schema is a per-workspace build artifact rather than a catalog one.
358
+ * Requires `sites:read`; no Bundle installation authority is needed.
359
+ */
360
+ async getThemeSettingsSchema(wid, slug) {
361
+ return this.fetch(
362
+ `w/${encodeURIComponent(wid)}/themes/${encodeURIComponent(slug)}/settings-schema`
363
+ );
364
+ }
365
+ };
366
+
74
367
  // src/api/access-grants.ts
75
368
  var AccessGrantsApi = class extends BaseApiClient {
76
369
  /** List access grants received by the current member. */
@@ -203,7 +496,6 @@ var AgentsApi = class extends BaseApiClient {
203
496
  if (options.search) params.append("search", options.search);
204
497
  if (options.includeArchived)
205
498
  params.append("includeArchived", options.includeArchived.toString());
206
- if (options.owner) params.append("owner", options.owner);
207
499
  return this.fetch(
208
500
  `w/${wid}/agents${params.toString() ? `?${params.toString()}` : ""}`
209
501
  );
@@ -259,6 +551,18 @@ var AIModelsApi = class extends BaseApiClient {
259
551
  const url = queryString ? `ai-models/chat?${queryString}` : "ai-models/chat";
260
552
  return this.fetch(url);
261
553
  }
554
+ /**
555
+ * Get the models a member may pick for the Workspace Manager, in display
556
+ * order. Only models this deployment can serve are listed.
557
+ *
558
+ * `tokenMultiplier` is each model's input + output price per token relative
559
+ * to `baselineModelId`; `defaultModelId` is what the Manager runs with no
560
+ * pick. Send a pick on a Manager chat as `AppContext.managerModel` /
561
+ * `managerReasoningEffort`.
562
+ */
563
+ async getManagerModels() {
564
+ return this.fetch("ai-models/manager");
565
+ }
262
566
  /**
263
567
  * Get available realtime AI models
264
568
  */
@@ -710,6 +1014,19 @@ var AuthApi = class extends BaseApiClient {
710
1014
  body: JSON.stringify(request)
711
1015
  });
712
1016
  }
1017
+ /**
1018
+ * Mint a single-use, account-bound realtime login token (`gr_wst_`) with
1019
+ * this client's credential. Call once per realtime connect attempt; the
1020
+ * token is spent on first use and expires in seconds. Only the full browser
1021
+ * session may mint one — an API key is refused.
1022
+ */
1023
+ async createRealtimeLoginToken() {
1024
+ return this.fetch("auth/realtime/ws-token", {
1025
+ method: "POST",
1026
+ // The route requires a JSON body (its CSRF barrier); it reads nothing from it.
1027
+ body: JSON.stringify({})
1028
+ });
1029
+ }
713
1030
  /** Get the organization and workspace mapping for a custom domain. */
714
1031
  async getDomainMapping(customDomain) {
715
1032
  return this.fetch(`s/mapping/${customDomain}`);
@@ -1369,6 +1686,26 @@ var ChatsApi = class extends BaseApiClient {
1369
1686
  async getChat(wid, id) {
1370
1687
  return this.fetch(`w/${wid}/chats/${id}`);
1371
1688
  }
1689
+ /**
1690
+ * Get a single chat by UUID.
1691
+ *
1692
+ * The uuid-addressed twin of `getChat`: same access check (own chat,
1693
+ * otherwise `chats:read`), same body; a chat the caller may not read is a
1694
+ * 404. Activity events and org webhooks name a chat by `uuid` only.
1695
+ */
1696
+ async getChatByUuid(wid, uuid) {
1697
+ return this.fetch(`w/${wid}/chats/by-uuid/${uuid}`);
1698
+ }
1699
+ async saveChatBrowserStorage(wid, chatId) {
1700
+ await this.fetchRaw(`w/${wid}/chats/${chatId}/browser/storage/save`, {
1701
+ method: "POST",
1702
+ keepalive: true,
1703
+ body: JSON.stringify({})
1704
+ });
1705
+ }
1706
+ async clearChatBrowserStorage(wid, chatId) {
1707
+ await this.fetchRaw(`w/${wid}/chats/${chatId}/browser/storage`, { method: "DELETE" });
1708
+ }
1372
1709
  /**
1373
1710
  * Get a short-lived, interactive AgentCore browser view for this Chat.
1374
1711
  *
@@ -2049,6 +2386,26 @@ var DataTypesApi = class extends BaseApiClient {
2049
2386
  `w/${wid}/data-types/${dataTypeId}/records${params?.toString() ? `?${params.toString()}` : ""}`
2050
2387
  );
2051
2388
  }
2389
+ /**
2390
+ * List an anonymous Form's submissions, newest first. Requires
2391
+ * `anonymous_submissions:read`. Submissions are immutable: there is no
2392
+ * update or delete method.
2393
+ */
2394
+ async listAnonymousFormSubmissions(wid, dataTypeId, options) {
2395
+ const params = new URLSearchParams();
2396
+ if (options?.page) params.append("page", options.page.toString());
2397
+ if (options?.pageSize) params.append("page_size", options.pageSize.toString());
2398
+ const qs = params.toString();
2399
+ return this.fetch(
2400
+ `w/${wid}/data-types/${dataTypeId}/anonymous-submissions${qs ? `?${qs}` : ""}`
2401
+ );
2402
+ }
2403
+ /** Get one anonymous Form submission by its uuid. Requires `anonymous_submissions:read`. */
2404
+ async getAnonymousFormSubmission(wid, dataTypeId, submissionUuid) {
2405
+ return this.fetch(
2406
+ `w/${wid}/data-types/${dataTypeId}/anonymous-submissions/${encodeURIComponent(submissionUuid)}`
2407
+ );
2408
+ }
2052
2409
  // Data-record filter APIs (saved Query IR predicates per form)
2053
2410
  /** List saved data-record filters, optionally scoped to one DataType. */
2054
2411
  async getDataRecordFilters(wid, options) {
@@ -2091,6 +2448,15 @@ var DataTypesApi = class extends BaseApiClient {
2091
2448
  async getDataRecord(wid, recordId) {
2092
2449
  return this.fetch(`w/${wid}/data-types/records/${recordId}`);
2093
2450
  }
2451
+ /**
2452
+ * Get a single data record by UUID.
2453
+ *
2454
+ * The uuid-addressed twin of `getDataRecord`: same access check, same body.
2455
+ * Activity events and org webhooks name a record by `uuid` only.
2456
+ */
2457
+ async getDataRecordByUuid(wid, uuid) {
2458
+ return this.fetch(`w/${wid}/data-types/records/by-uuid/${uuid}`);
2459
+ }
2094
2460
  /** Create a new data record under the specified data type. */
2095
2461
  async createDataRecord(wid, dataTypeId, record) {
2096
2462
  return this.fetch(`w/${wid}/data-types/${dataTypeId}/records`, {
@@ -2536,20 +2902,6 @@ var EventsApi = class extends BaseApiClient {
2536
2902
  body: JSON.stringify(request)
2537
2903
  });
2538
2904
  }
2539
- /**
2540
- * Preview which target-audience roles lack Workflow USE for the Workflows a
2541
- * draft Routine would start. Non-persisting, non-blocking authoring assist —
2542
- * returns warnings only (role/Workflow names + IDs; no Member data).
2543
- */
2544
- async previewRoutineWorkflowAccess(wid, request) {
2545
- return this.fetch(
2546
- `w/${wid}/routines/preview-workflow-access`,
2547
- {
2548
- method: "POST",
2549
- body: JSON.stringify(request)
2550
- }
2551
- );
2552
- }
2553
2905
  /**
2554
2906
  * Preview what would stop a draft Routine placing its scheduled outbound
2555
2907
  * calls — the Member voice opt-out, a missing member phone, or a
@@ -3143,6 +3495,19 @@ var FilesApi = class extends BaseApiClient {
3143
3495
  if (folderId != null) params.append("folderId", String(folderId));
3144
3496
  return this.fetch(`w/${wid}/files/resolve-path?${params.toString()}`);
3145
3497
  }
3498
+ /**
3499
+ * Download one file's bytes via GET ``.../files/{id}/contents/{filename}``.
3500
+ *
3501
+ * Uses this client's base URL (FastAPI on the app, same-origin ``/api/v2``
3502
+ * on scoped site sessions) so the payload does not transit the Next.js
3503
+ * ``/api/w/.../files/...`` Lambda proxy, which 500s above the 6MB sync cap.
3504
+ */
3505
+ async downloadFileContents(wid, id, filename) {
3506
+ const response = await this.fetchRaw(
3507
+ `w/${wid}/files/${id}/contents/${encodeURIComponent(filename)}`
3508
+ );
3509
+ return response.blob();
3510
+ }
3146
3511
  /**
3147
3512
  * Download the given files + folders (folders recursively) as a single ZIP.
3148
3513
  * Returns the raw archive bytes for the caller to save.
@@ -3894,7 +4259,21 @@ function throwMemberImportError(errorBody, fallback) {
3894
4259
  }
3895
4260
  throw new Error(typeof detail === "string" ? detail : fallback);
3896
4261
  }
4262
+ function memberImportUpload(file, roleId, options) {
4263
+ const body = new FormData();
4264
+ const filename = "name" in file && typeof file.name === "string" ? file.name : "members.csv";
4265
+ body.append("file", file, filename);
4266
+ if (options?.resolutions !== void 0) {
4267
+ body.append("resolutions", JSON.stringify(options.resolutions));
4268
+ }
4269
+ const params = new URLSearchParams({ new_member_role_id: String(roleId) });
4270
+ if (options?.autoPromoteUniqueContacts !== void 0) {
4271
+ params.set("auto_promote_unique_contacts", String(options.autoPromoteUniqueContacts));
4272
+ }
4273
+ return { body, params };
4274
+ }
3897
4275
  var MembersApi = class extends BaseApiClient {
4276
+ memberImportPlans = /* @__PURE__ */ new WeakMap();
3898
4277
  /** Get the currently authenticated member for a workspace. */
3899
4278
  async getCurrentMember(wid) {
3900
4279
  return this.fetch(`w/${wid}/me`);
@@ -3947,33 +4326,6 @@ var MembersApi = class extends BaseApiClient {
3947
4326
  `w/${wid}/me/records?${params.toString()}`
3948
4327
  );
3949
4328
  }
3950
- /**
3951
- * Get all members owned by the current member in this workspace.
3952
- * Returns the authenticated member plus any members they own (via owner_id).
3953
- * Used by the member switcher to show available identities.
3954
- */
3955
- async getOwnedMembers(wid) {
3956
- return this.fetch(`w/${wid}/members/owned`);
3957
- }
3958
- /**
3959
- * Switch to a different member identity owned by the current member.
3960
- * Sets the actingAsMemberUuid cookie for subsequent requests.
3961
- * Uses UUID (not ID) to prevent cross-workspace identity confusion.
3962
- */
3963
- async switchMember(wid, memberUuid) {
3964
- return this.fetch(`w/${wid}/members/switch`, {
3965
- method: "POST",
3966
- body: JSON.stringify({ memberUuid })
3967
- });
3968
- }
3969
- /**
3970
- * Clear the member switch and return to the authenticated member.
3971
- */
3972
- async clearMemberSwitch(wid) {
3973
- return this.fetch(`w/${wid}/members/switch`, {
3974
- method: "DELETE"
3975
- });
3976
- }
3977
4329
  /** Update the currently authenticated member's profile. */
3978
4330
  async updateCurrentMember(wid, member) {
3979
4331
  return this.fetch(`w/${wid}/me`, {
@@ -4013,6 +4365,16 @@ var MembersApi = class extends BaseApiClient {
4013
4365
  async getWorkspaceMember(wid, memberId) {
4014
4366
  return this.fetch(`w/${wid}/members/${memberId}`);
4015
4367
  }
4368
+ /**
4369
+ * Get a single workspace member by UUID.
4370
+ *
4371
+ * The uuid-addressed twin of `getWorkspaceMember`: same access check (self,
4372
+ * otherwise `members:read`), same body. Activity events and org webhooks
4373
+ * name a member by `uuid` only.
4374
+ */
4375
+ async getMemberByUuid(wid, uuid) {
4376
+ return this.fetch(`w/${wid}/members/by-uuid/${uuid}`);
4377
+ }
4016
4378
  /**
4017
4379
  * Get one member of an org's workspace, under `org:read`.
4018
4380
  *
@@ -4064,6 +4426,53 @@ var MembersApi = class extends BaseApiClient {
4064
4426
  method: "POST"
4065
4427
  });
4066
4428
  }
4429
+ /**
4430
+ * Update a workspace member addressed by its external id.
4431
+ *
4432
+ * The external-id twin of `updateMember`: for an integrator that keys on its
4433
+ * own `externalId` and never stores our numeric member id. Same authorization
4434
+ * (`members:write`) and same body as `updateMember`.
4435
+ */
4436
+ async updateMemberByExternalId(wid, externalId, data) {
4437
+ return this.fetch(
4438
+ `w/${wid}/members/by-external-id/${encodeURIComponent(externalId)}`,
4439
+ {
4440
+ method: "PUT",
4441
+ body: JSON.stringify(data)
4442
+ }
4443
+ );
4444
+ }
4445
+ /**
4446
+ * Archive a workspace member addressed by its external id.
4447
+ *
4448
+ * The external-id twin of `archiveMember`; same authorization
4449
+ * (`members:write` + `members:admin`) and same body.
4450
+ */
4451
+ async archiveMemberByExternalId(wid, externalId) {
4452
+ return this.fetch(
4453
+ `w/${wid}/members/by-external-id/${encodeURIComponent(externalId)}/archive`,
4454
+ {
4455
+ method: "POST",
4456
+ // Required empty JSON body is the route's CSRF barrier (GRA-6284).
4457
+ body: JSON.stringify({})
4458
+ }
4459
+ );
4460
+ }
4461
+ /**
4462
+ * Unarchive a workspace member addressed by its external id.
4463
+ *
4464
+ * The external-id twin of `unarchiveMember`; same authorization and body.
4465
+ */
4466
+ async unarchiveMemberByExternalId(wid, externalId) {
4467
+ return this.fetch(
4468
+ `w/${wid}/members/by-external-id/${encodeURIComponent(externalId)}/unarchive`,
4469
+ {
4470
+ method: "POST",
4471
+ // Required empty JSON body is the route's CSRF barrier (GRA-6284).
4472
+ body: JSON.stringify({})
4473
+ }
4474
+ );
4475
+ }
4067
4476
  /**
4068
4477
  * Send the member an SMS asking them to confirm their phone number. When they
4069
4478
  * reply, a trusted phone auth binding is created so they can use SMS as
@@ -4205,16 +4614,13 @@ var MembersApi = class extends BaseApiClient {
4205
4614
  * operator can decide whether to skip or explicitly overwrite before
4206
4615
  * committing. Requires MEMBERS_ADMIN and is bulk-PHI audited server-side.
4207
4616
  */
4208
- async previewImportMembers(wid, file, newMemberRoleId) {
4209
- const formData = new FormData();
4210
- formData.append("file", file);
4211
- const params = new URLSearchParams();
4212
- params.append("new_member_role_id", newMemberRoleId.toString());
4617
+ async previewImportMembers(wid, file, newMemberRoleId, options) {
4618
+ const { body, params } = memberImportUpload(file, newMemberRoleId, options);
4213
4619
  const response = await this.fetchRaw(
4214
4620
  `w/${wid}/members/import/preview?${params.toString()}`,
4215
4621
  {
4216
4622
  method: "POST",
4217
- body: formData
4623
+ body
4218
4624
  },
4219
4625
  [400, 413]
4220
4626
  );
@@ -4222,7 +4628,19 @@ var MembersApi = class extends BaseApiClient {
4222
4628
  const error = await response.json().catch(() => ({}));
4223
4629
  throwMemberImportError(error, "Import preview failed");
4224
4630
  }
4225
- return response.json();
4631
+ const preview = await response.json();
4632
+ if (preview.previewPlanToken) {
4633
+ this.memberImportPlans.set(file, {
4634
+ wid,
4635
+ role: newMemberRoleId,
4636
+ autoPromote: options?.autoPromoteUniqueContacts ?? true,
4637
+ token: preview.previewPlanToken,
4638
+ cachedAt: Date.now()
4639
+ });
4640
+ } else {
4641
+ this.memberImportPlans.delete(file);
4642
+ }
4643
+ return preview;
4226
4644
  }
4227
4645
  /**
4228
4646
  * Import members from a CSV file, streaming progress updates via callback.
@@ -4232,10 +4650,11 @@ var MembersApi = class extends BaseApiClient {
4232
4650
  * Send 'overwrite_identity_fields' only after the operator confirms a preview.
4233
4651
  */
4234
4652
  async importMembers(wid, file, newMemberRoleId, onProgress, options) {
4235
- const formData = new FormData();
4236
- formData.append("file", file);
4237
- const params = new URLSearchParams();
4238
- params.append("new_member_role_id", newMemberRoleId.toString());
4653
+ const { body, params } = memberImportUpload(file, newMemberRoleId, options);
4654
+ const cachedPlan = this.memberImportPlans.get(file);
4655
+ const autoPromote = options?.autoPromoteUniqueContacts ?? true;
4656
+ const previewPlanToken = options?.previewPlanToken ?? (cachedPlan?.wid === wid && cachedPlan.role === newMemberRoleId && cachedPlan.autoPromote === autoPromote && Date.now() - cachedPlan.cachedAt < 55 * 60 * 1e3 ? cachedPlan.token : (await this.previewImportMembers(wid, file, newMemberRoleId, options)).previewPlanToken);
4657
+ if (previewPlanToken) body.append("previewPlanToken", previewPlanToken);
4239
4658
  if (options?.identityConflictPolicy) {
4240
4659
  params.append("identity_conflict_policy", options.identityConflictPolicy);
4241
4660
  }
@@ -4243,7 +4662,7 @@ var MembersApi = class extends BaseApiClient {
4243
4662
  `w/${wid}/members/import?${params.toString()}`,
4244
4663
  {
4245
4664
  method: "POST",
4246
- body: formData
4665
+ body
4247
4666
  },
4248
4667
  [400, 413]
4249
4668
  );
@@ -4251,34 +4670,48 @@ var MembersApi = class extends BaseApiClient {
4251
4670
  const error = await response.json().catch(() => ({}));
4252
4671
  throwMemberImportError(error, "Import failed");
4253
4672
  }
4254
- if (onProgress && response.body) {
4255
- const reader = response.body.getReader();
4256
- const decoder = new TextDecoder();
4257
- let buffer = "";
4673
+ if (!response.body) throw new Error("Member import response has no progress stream");
4674
+ const reader = response.body.getReader();
4675
+ const decoder = new TextDecoder();
4676
+ let buffer = "";
4677
+ let result;
4678
+ let hadError = false;
4679
+ const consume = (line) => {
4680
+ if (!line.trim()) return;
4681
+ let event;
4682
+ try {
4683
+ event = JSON.parse(line);
4684
+ } catch {
4685
+ throw new Error("Invalid member import progress event");
4686
+ }
4687
+ if (event.type === "complete") result = event;
4688
+ if (event.type === "error") hadError = true;
4689
+ onProgress?.(event);
4690
+ };
4691
+ try {
4258
4692
  while (true) {
4259
4693
  const { done, value } = await reader.read();
4260
4694
  if (done) break;
4261
4695
  buffer += decoder.decode(value, { stream: true });
4262
4696
  const lines = buffer.split("\n");
4263
4697
  buffer = lines.pop() ?? "";
4264
- for (const line of lines) {
4265
- const trimmed = line.trim();
4266
- if (!trimmed) continue;
4267
- try {
4268
- onProgress(JSON.parse(trimmed));
4269
- } catch {
4270
- }
4271
- }
4272
- }
4273
- const tail = buffer.trim();
4274
- if (tail) {
4275
- try {
4276
- onProgress(JSON.parse(tail));
4277
- } catch {
4278
- }
4698
+ for (const line of lines) consume(line);
4279
4699
  }
4700
+ buffer += decoder.decode();
4701
+ consume(buffer);
4702
+ } catch (error) {
4703
+ await reader.cancel().catch(() => void 0);
4704
+ throw error;
4705
+ } finally {
4706
+ reader.releaseLock();
4280
4707
  }
4281
- return { success: true };
4708
+ if (!result) {
4709
+ throw new Error("Member import ended before completion; inspect members before retrying");
4710
+ }
4711
+ return {
4712
+ success: !hadError && (result.failed ?? 0) === 0 && (result.conflicted ?? 0) === 0,
4713
+ result
4714
+ };
4282
4715
  }
4283
4716
  /** Export members as a downloadable file with selected fields and data types. */
4284
4717
  async exportMembers(wid, selectedFields, selectedDataTypes, memberType) {
@@ -4684,6 +5117,21 @@ var MondayIntegrationApi = class extends BaseApiClient {
4684
5117
  method: "POST"
4685
5118
  });
4686
5119
  }
5120
+ /**
5121
+ * Managed-rule execution history for this connection (`GET /sync/logs`):
5122
+ * the connection's managed EventRule executions, newest first, with the
5123
+ * shared cursor pagination. Requires `apps:read`; works while the
5124
+ * connection is parked for re-authorization.
5125
+ */
5126
+ async getMondaySyncLogs(wid, params) {
5127
+ const query = new URLSearchParams();
5128
+ if (params?.pageSize) query.set("pageSize", String(params.pageSize));
5129
+ if (params?.cursor) query.set("cursor", params.cursor);
5130
+ const qs = query.toString() ? `?${query.toString()}` : "";
5131
+ return this.fetch(
5132
+ `w/${wid}/app-connections/monday/sync/logs${qs}`
5133
+ );
5134
+ }
4687
5135
  };
4688
5136
 
4689
5137
  // src/api/notification-rules.ts
@@ -4803,6 +5251,10 @@ var OrgApi = class extends BaseApiClient {
4803
5251
  async getCurrentOrgMember(orgIdOrUuid) {
4804
5252
  return this.fetch(`o/${orgIdOrUuid}/me`);
4805
5253
  }
5254
+ /** Bundles this organization owns — read-only catalog for `/o/{uuid}/library`. */
5255
+ async listOrgBundles(orgIdOrUuid) {
5256
+ return this.fetch(`o/${orgIdOrUuid}/bundles`);
5257
+ }
4806
5258
  /**
4807
5259
  * Update the settings an org admin owns: name, slug and contact details.
4808
5260
  *
@@ -4844,6 +5296,12 @@ var OrgApi = class extends BaseApiClient {
4844
5296
  * `subscriptionId` is the org-scoped row — never pick the customer's
4845
5297
  * newest subscription from the list endpoint. One customer can bill many
4846
5298
  * organizations.
5299
+ *
5300
+ * Returns the generated `OrgBillingCustomerResponse` — the contract the
5301
+ * route actually emits, `audiences` included. The hand-written mirror that
5302
+ * used to live here listed four fields and silently dropped `audiences`,
5303
+ * so callers could not see the commercial roles they hold (GRA-8792).
5304
+ * Regenerate the shape (`yarn generate:types`) rather than re-declaring it.
4847
5305
  */
4848
5306
  async getOrgBillingCustomer(orgIdOrUuid) {
4849
5307
  return this.fetch(`o/${orgIdOrUuid}/billing-customer`);
@@ -4880,7 +5338,10 @@ var OrgApi = class extends BaseApiClient {
4880
5338
  return this.fetch(`o/${orgUuid}/members/check/${accountUuid}`);
4881
5339
  }
4882
5340
  /**
4883
- * Update an organization member's role.
5341
+ * Update an organization member's role and/or org-level display name.
5342
+ *
5343
+ * `name` is the org's own label for the member (the OrgMember row and the
5344
+ * linked OrgAccount); it does not change the person's global Account name.
4884
5345
  */
4885
5346
  async updateOrganizationMember(orgIdOrUuid, memberId, data) {
4886
5347
  return this.fetch(`o/${orgIdOrUuid}/members/${memberId}`, {
@@ -5255,12 +5716,6 @@ var OrgApi = class extends BaseApiClient {
5255
5716
  // ============================================================================
5256
5717
  // Organization A2P Brand Registration API
5257
5718
  // ============================================================================
5258
- /**
5259
- * Get the org's A2P brand registration status.
5260
- */
5261
- async getA2PStatus(orgUuid) {
5262
- return this.fetch(`o/${orgUuid}/phone-numbers/a2p/status`);
5263
- }
5264
5719
  /** Return fixed phone-number and outbound-messaging prices. */
5265
5720
  async getPhoneBillingPricing(orgUuid) {
5266
5721
  return this.fetch(`o/${orgUuid}/phone-numbers/pricing`);
@@ -5269,11 +5724,30 @@ var OrgApi = class extends BaseApiClient {
5269
5724
  * Start A2P brand registration under a legal entity. `legalEntityUuid`
5270
5725
  * is required — brands register per legal entity (Customer Profile);
5271
5726
  * there is no primary-entity fallback.
5727
+ *
5728
+ * `soleProprietorMobile` is the proprietor's own mobile number, the one the
5729
+ * carrier sends the A2P one-time-password verification to. Required when the
5730
+ * entity's registration shape is a sole proprietorship (see
5731
+ * `LegalEntitySummaryResponse.requiredBrandType`); ignored otherwise.
5732
+ *
5733
+ * Three constraints belong to the customer, so the caller must state them:
5734
+ * it has to be a US or Canadian **mobile**, it cannot be a number acquired
5735
+ * from a CPaaS provider (so never one we provisioned — the carrier rejects
5736
+ * it), and the carrier allows it a lifetime maximum of three uses across all
5737
+ * A2P brand registrations, counting those made through other vendors.
5738
+ *
5739
+ * It is forwarded to the registration workflow to reach the carrier as an
5740
+ * EndUser attribute and is never stored on our side.
5272
5741
  */
5273
- async startA2PRegistration(orgUuid, legalEntityUuid, brandName, brandUuid = null) {
5742
+ async startA2PRegistration(orgUuid, legalEntityUuid, brandName, brandUuid = null, soleProprietorMobile = null) {
5274
5743
  return this.fetch(`o/${orgUuid}/phone-numbers/a2p/start`, {
5275
5744
  method: "POST",
5276
- body: JSON.stringify({ legalEntityUuid, brandName, brandUuid })
5745
+ body: JSON.stringify({
5746
+ legalEntityUuid,
5747
+ brandName,
5748
+ brandUuid,
5749
+ soleProprietorMobile
5750
+ })
5277
5751
  });
5278
5752
  }
5279
5753
  /**
@@ -5301,6 +5775,25 @@ var OrgApi = class extends BaseApiClient {
5301
5775
  }
5302
5776
  );
5303
5777
  }
5778
+ /**
5779
+ * Which legal entity's voice trust products (CNAM, SHAKEN/STIR, Voice
5780
+ * Integrity) each of the org's numbers carries, read live from Twilio.
5781
+ */
5782
+ async getPhoneVoiceTrust(orgUuid) {
5783
+ return this.fetch(`o/${orgUuid}/phone-numbers/voice-trust`);
5784
+ }
5785
+ /**
5786
+ * Put a number on a legal entity's Customer Profile and approved voice
5787
+ * trust products, taking it off any other legal entity's first. The
5788
+ * entity's business profile must be approved (400 otherwise).
5789
+ */
5790
+ async attachPhoneVoiceTrust(orgUuid, providerPhoneUuid, legalEntityUuid) {
5791
+ const body = { providerPhoneUuid, legalEntityUuid };
5792
+ return this.fetch(`o/${orgUuid}/phone-numbers/voice-trust/attach`, {
5793
+ method: "POST",
5794
+ body: JSON.stringify(body)
5795
+ });
5796
+ }
5304
5797
  // ============================================================================
5305
5798
  // Organization Business Profile API (Twilio Trust Hub Secondary CP)
5306
5799
  // ============================================================================
@@ -5470,6 +5963,16 @@ var OrgApi = class extends BaseApiClient {
5470
5963
  }
5471
5964
  );
5472
5965
  }
5966
+ /**
5967
+ * Resubmit a campaign the carrier rejected, with the brand's current
5968
+ * campaign copy. Edits the campaign in place, so no second vetting fee.
5969
+ */
5970
+ async resubmitA2PCampaign(orgUuid, brandUuid) {
5971
+ return this.fetch(
5972
+ `o/${orgUuid}/a2p-brands/${brandUuid}/resubmit-campaign`,
5973
+ { method: "POST" }
5974
+ );
5975
+ }
5473
5976
  /**
5474
5977
  * Published Sites across the org's workspaces that can be linked as this
5475
5978
  * brand's enrollment (opt-in) surface. Org-authorized, so it works even when
@@ -5482,7 +5985,7 @@ var OrgApi = class extends BaseApiClient {
5482
5985
  }
5483
5986
  /**
5484
5987
  * Link the brand to a published enrollment Site (sets `site_uuid`). Returns
5485
- * the refreshed campaign config so the editor's link state updates inline.
5988
+ * the refreshed campaign config.
5486
5989
  */
5487
5990
  async linkA2PEnrollmentSite(orgUuid, brandUuid, data) {
5488
5991
  return this.fetch(
@@ -5495,9 +5998,9 @@ var OrgApi = class extends BaseApiClient {
5495
5998
  }
5496
5999
  /**
5497
6000
  * Provision (or reuse) a patient-enrollment Site for the brand and link it —
5498
- * the one-click path behind the SMS Consent tab. `workspaceUuid` is required
5499
- * only when the org has multiple workspaces. Returns the refreshed campaign
5500
- * config so the editor's link state updates inline. Idempotent.
6001
+ * the explicit counterpart to the automatic provisioning at brand
6002
+ * registration. `workspaceUuid` is required only when the org has multiple
6003
+ * workspaces. Returns the refreshed campaign config. Idempotent.
5501
6004
  */
5502
6005
  async provisionA2PEnrollmentSite(orgUuid, brandUuid, data = {}) {
5503
6006
  return this.fetch(
@@ -5516,34 +6019,42 @@ var OrgApi = class extends BaseApiClient {
5516
6019
  );
5517
6020
  }
5518
6021
  /**
5519
- * The brand's enrollment-form template URL (carries `?brand=…`, no
5520
- * credential). `url` is null until a Site is linked. Do not append a
5521
- * patient identifier to this URL — use {@link mintA2PBrandEnrollmentLink}
5522
- * to get a patient-ready link instead.
6022
+ * Stage one A2P opt-in evidence file: get a presigned POST to send the bytes
6023
+ * straight to storage. Nothing is recorded on the brand until
6024
+ * {@link registerA2PEvidenceUpload} reads the object back and normalizes it.
5523
6025
  */
5524
- async getA2PBrandEnrollmentUrl(orgUuid, brandUuid) {
6026
+ async createA2PEvidenceUploadUrl(orgUuid, brandUuid, data) {
5525
6027
  return this.fetch(
5526
- `o/${orgUuid}/a2p-brands/${brandUuid}/enrollment-url`
6028
+ `o/${orgUuid}/a2p-brands/${brandUuid}/evidence-attachments/upload-url`,
6029
+ {
6030
+ method: "POST",
6031
+ body: JSON.stringify(data)
6032
+ }
5527
6033
  );
5528
6034
  }
5529
6035
  /**
5530
- * Mint a patient-ready enrollment link for one patient.
5531
- *
5532
- * The returned URL carries a fresh, expiring, single-use `?grant=…` bound to
5533
- * the member that `externalId` resolves to. `externalId` (the patient's
5534
- * CRM/EHR identifier) travels in the request body, never the query string,
5535
- * so it stays out of access logs. When it matches no member, the
5536
- * credential-free template URL is returned rather than an error.
6036
+ * Normalize a staged evidence upload and record it on the brand. Returns the
6037
+ * refreshed campaign config, so the editor's evidence list updates without a
6038
+ * second round trip.
5537
6039
  */
5538
- async mintA2PBrandEnrollmentLink(orgUuid, brandUuid, externalId) {
6040
+ async registerA2PEvidenceUpload(orgUuid, brandUuid, data) {
5539
6041
  return this.fetch(
5540
- `o/${orgUuid}/a2p-brands/${brandUuid}/enrollment-url`,
6042
+ `o/${orgUuid}/a2p-brands/${brandUuid}/evidence-attachments`,
5541
6043
  {
5542
6044
  method: "POST",
5543
- body: JSON.stringify({ externalId })
6045
+ body: JSON.stringify(data)
5544
6046
  }
5545
6047
  );
5546
6048
  }
6049
+ /** Remove one uploaded evidence artifact. */
6050
+ async deleteA2PEvidenceUpload(orgUuid, brandUuid, attachmentUuid) {
6051
+ return this.fetch(
6052
+ `o/${orgUuid}/a2p-brands/${brandUuid}/evidence-attachments/${encodeURIComponent(
6053
+ attachmentUuid
6054
+ )}`,
6055
+ { method: "DELETE" }
6056
+ );
6057
+ }
5547
6058
  /**
5548
6059
  * List available member roles for a workspace in the organization.
5549
6060
  */
@@ -5568,6 +6079,9 @@ var OrgApi = class extends BaseApiClient {
5568
6079
  async listOrgWebhookEndpoints(orgIdOrUuid) {
5569
6080
  return this.fetch(`o/${orgIdOrUuid}/webhooks`);
5570
6081
  }
6082
+ async getOrgWebhookEndpoint(orgIdOrUuid, endpointUuid) {
6083
+ return this.fetch(`o/${orgIdOrUuid}/webhooks/${endpointUuid}`);
6084
+ }
5571
6085
  /**
5572
6086
  * The subscribable event-type vocabulary for the org UI's event-type
5573
6087
  * picker — exactly what the create/update validators accept, so the UI
@@ -5626,6 +6140,39 @@ var OrgApi = class extends BaseApiClient {
5626
6140
  }
5627
6141
  );
5628
6142
  }
6143
+ // =========================================================================
6144
+ // Organization API keys (GRA-9043)
6145
+ // =========================================================================
6146
+ /**
6147
+ * List every API key bound to this organization. Never carries the secret.
6148
+ *
6149
+ * Org-bound keys authenticate as an org-local principal, so one key reaches
6150
+ * every current workspace of the organization and every workspace created
6151
+ * later. Gated by `org:api_keys`, which `org:admin` holds transitively.
6152
+ */
6153
+ async listOrgApiKeys(orgIdOrUuid) {
6154
+ return this.fetch(`o/${orgIdOrUuid}/api-keys`);
6155
+ }
6156
+ /**
6157
+ * Mint an org-bound API key.
6158
+ *
6159
+ * The payload is the same client-only {@link ApiKeyFormData} the workspace
6160
+ * and account routes take — `{name, expiresInDays, scopes}`, no workspace
6161
+ * id: the mint location is what binds the key. The response carries `key`,
6162
+ * the plaintext secret, which is readable exactly once.
6163
+ */
6164
+ async createOrgApiKey(orgIdOrUuid, apiKey) {
6165
+ return this.fetch(`o/${orgIdOrUuid}/api-keys`, {
6166
+ method: "POST",
6167
+ body: JSON.stringify(apiKey)
6168
+ });
6169
+ }
6170
+ /** Revoke an org-bound API key by its id. */
6171
+ async revokeOrgApiKey(orgIdOrUuid, keyId) {
6172
+ return this.fetch(`o/${orgIdOrUuid}/api-keys/${keyId}`, {
6173
+ method: "DELETE"
6174
+ });
6175
+ }
5629
6176
  };
5630
6177
  function businessProfilePath(orgUuid, legalEntityUuid) {
5631
6178
  return legalEntityUuid ? `o/${orgUuid}/legal-entities/${legalEntityUuid}/business-profile` : `o/${orgUuid}/business-profile`;
@@ -6162,6 +6709,14 @@ var QualificationsApi = class extends BaseApiClient {
6162
6709
  });
6163
6710
  }
6164
6711
  // ===== Test chat runs =====
6712
+ /**
6713
+ * List a Workflow's test chat runs, newest first (default 50, max 500).
6714
+ *
6715
+ * `workflowRevisionId` narrows to that revision before the limit applies.
6716
+ * `includeEarlierRevisions` widens the window to earlier published
6717
+ * revisions and runs whose revision was deleted, and requires
6718
+ * `workflowRevisionId`. Omitting both keeps the unfiltered list.
6719
+ */
6165
6720
  async listTestChatRuns(wid, workflowId, params) {
6166
6721
  const query = new URLSearchParams();
6167
6722
  if (params?.scenarioId !== void 0) query.set("scenarioId", String(params.scenarioId));
@@ -6169,11 +6724,36 @@ var QualificationsApi = class extends BaseApiClient {
6169
6724
  query.set("assistantChatModelId", params.assistantChatModelId);
6170
6725
  }
6171
6726
  if (params?.limit !== void 0) query.set("limit", String(params.limit));
6727
+ if (params?.workflowRevisionId !== void 0) {
6728
+ query.set("workflow_revision_id", String(params.workflowRevisionId));
6729
+ }
6730
+ if (params?.includeEarlierRevisions !== void 0) {
6731
+ query.set("include_earlier_revisions", String(params.includeEarlierRevisions));
6732
+ }
6172
6733
  const qs = query.toString() ? `?${query.toString()}` : "";
6173
6734
  return this.fetch(
6174
6735
  `w/${wid}/qualifications/workflows/${workflowId}/test-chat-runs${qs}`
6175
6736
  );
6176
6737
  }
6738
+ /**
6739
+ * Exact scenario health for one revision of a Workflow: every active
6740
+ * scenario's server-decided state, caption, counts and per-revision pass
6741
+ * rates, plus the board headline. Scenarios arrive in board order.
6742
+ *
6743
+ * Omit `workflowRevisionId` for the server's current revision (the newest
6744
+ * with runs, the Draft counting as newest); the response names the
6745
+ * revision it describes and whether it is the current one.
6746
+ */
6747
+ async listScenarioHealthSummaries(wid, workflowId, params) {
6748
+ const query = new URLSearchParams();
6749
+ if (params?.workflowRevisionId !== void 0) {
6750
+ query.set("workflow_revision_id", String(params.workflowRevisionId));
6751
+ }
6752
+ const qs = query.toString() ? `?${query.toString()}` : "";
6753
+ return this.fetch(
6754
+ `w/${wid}/qualifications/workflows/${workflowId}/scenario-health-summaries${qs}`
6755
+ );
6756
+ }
6177
6757
  async getTestChatRun(wid, runId) {
6178
6758
  return this.fetch(`w/${wid}/qualifications/test-chat-runs/${runId}`);
6179
6759
  }
@@ -6269,6 +6849,96 @@ var ReportsApi = class extends BaseApiClient {
6269
6849
  }
6270
6850
  };
6271
6851
 
6852
+ // src/types/generated/communication.ts
6853
+ var RoutingActionType = {
6854
+ answer_ai: "answer_ai",
6855
+ answer_human: "answer_human",
6856
+ answer_owner: "answer_owner",
6857
+ voicemail: "voicemail",
6858
+ play_message: "play_message",
6859
+ ignore: "ignore",
6860
+ signup: "signup"
6861
+ };
6862
+ var RoutingAudience = {
6863
+ anyone: "anyone",
6864
+ anonymous: "anonymous",
6865
+ members: "members"
6866
+ };
6867
+ var RoutingChannel = {
6868
+ pstn: "pstn",
6869
+ messaging: "messaging",
6870
+ email: "email"
6871
+ };
6872
+ var RoutingTimeWindow = {
6873
+ always: "always",
6874
+ business_hours: "business_hours",
6875
+ non_business_hours: "non_business_hours",
6876
+ custom: "custom"
6877
+ };
6878
+
6879
+ // src/api/routing-rules.ts
6880
+ function appendFilters(params, filters) {
6881
+ if (!filters) return;
6882
+ if (filters.channel !== void 0) params.set("channel", filters.channel);
6883
+ if (filters.phoneNumberId !== void 0)
6884
+ params.set("phoneNumberId", String(filters.phoneNumberId));
6885
+ if (filters.inboxId !== void 0) params.set("inboxId", String(filters.inboxId));
6886
+ if (filters.page !== void 0) params.set("page", String(filters.page));
6887
+ if (filters.pageSize !== void 0) params.set("pageSize", String(filters.pageSize));
6888
+ }
6889
+ var RoutingRulesApi = class extends BaseApiClient {
6890
+ /** List one endpoint's rules. Requires the rule's endpoint read permission (`phones:read`, or `inboxes:read`). */
6891
+ async getRoutingRules(wid, filters) {
6892
+ const params = new URLSearchParams();
6893
+ appendFilters(params, filters);
6894
+ const query = params.toString();
6895
+ return this.fetch(
6896
+ `w/${wid}/routing${query ? `?${query}` : ""}`
6897
+ );
6898
+ }
6899
+ /** Read one rule. Requires the rule's endpoint read permission (`phones:read`, or `inboxes:read`). */
6900
+ async getRoutingRule(wid, ruleUuid) {
6901
+ return this.fetch(`w/${wid}/routing/${ruleUuid}`);
6902
+ }
6903
+ /** Create a rule. Requires the rule's endpoint write permission (`phones:write`, or `inboxes:write`). */
6904
+ async createRoutingRule(wid, data) {
6905
+ return this.fetch(`w/${wid}/routing`, {
6906
+ method: "POST",
6907
+ body: JSON.stringify(data)
6908
+ });
6909
+ }
6910
+ /** Update a rule. Requires the rule's endpoint write permission (`phones:write`, or `inboxes:write`). */
6911
+ async updateRoutingRule(wid, ruleUuid, data) {
6912
+ return this.fetch(`w/${wid}/routing/${ruleUuid}`, {
6913
+ method: "PATCH",
6914
+ body: JSON.stringify(data)
6915
+ });
6916
+ }
6917
+ /** Hard-delete a rule. Requires the rule's endpoint write permission (`phones:write`, or `inboxes:write`); the server audits deletion. */
6918
+ async deleteRoutingRule(wid, ruleUuid) {
6919
+ return this.fetch(`w/${wid}/routing/${ruleUuid}`, {
6920
+ method: "DELETE"
6921
+ });
6922
+ }
6923
+ /** Atomically reorder one endpoint/channel scope. Requires the rule's endpoint write permission (`phones:write`, or `inboxes:write`). */
6924
+ async reorderRoutingRules(wid, ruleUuids) {
6925
+ return this.fetch(`w/${wid}/routing/reorder`, {
6926
+ method: "POST",
6927
+ body: JSON.stringify({ ruleUuids })
6928
+ });
6929
+ }
6930
+ /**
6931
+ * Dry-run rule evaluation without placing or sending anything. Requires
6932
+ * the rule's endpoint read permission (`phones:read`, or `inboxes:read`); previewing a named Member also requires `members:read`.
6933
+ */
6934
+ async previewRoutingRule(wid, data) {
6935
+ return this.fetch(`w/${wid}/routing/preview`, {
6936
+ method: "POST",
6937
+ body: JSON.stringify(data)
6938
+ });
6939
+ }
6940
+ };
6941
+
6272
6942
  // src/api/salesforce.ts
6273
6943
  var SalesforceApi = class extends BaseApiClient {
6274
6944
  /**
@@ -6349,6 +7019,20 @@ var SalesforceApi = class extends BaseApiClient {
6349
7019
  body: JSON.stringify(data)
6350
7020
  });
6351
7021
  }
7022
+ /**
7023
+ * Start a durable run that links unlinked members by Salesforce Id / email
7024
+ * and hydrates them. One run per connection; a second start while one is
7025
+ * in flight is 409.
7026
+ */
7027
+ async linkUnlinkedSalesforceMembersByIdentity(wid) {
7028
+ return this.fetch(
7029
+ `w/${wid}/app-connections/salesforce/reconciliation/link-unlinked-by-identity`,
7030
+ {
7031
+ method: "POST",
7032
+ body: JSON.stringify({})
7033
+ }
7034
+ );
7035
+ }
6352
7036
  async unlinkMemberFromSalesforce(wid, memberId) {
6353
7037
  return this.fetch(`w/${wid}/app-connections/salesforce/reconciliation/unlink/${memberId}`, {
6354
7038
  method: "DELETE"
@@ -6430,6 +7114,21 @@ var SalesforceApi = class extends BaseApiClient {
6430
7114
  }
6431
7115
  );
6432
7116
  }
7117
+ /**
7118
+ * Managed-rule execution history for this connection (`GET /sync/logs`):
7119
+ * the connection's managed EventRule executions, newest first, with the
7120
+ * shared cursor pagination. Requires `apps:read`; works while the
7121
+ * connection is parked for re-authorization.
7122
+ */
7123
+ async getSalesforceSyncLogs(wid, params) {
7124
+ const query = new URLSearchParams();
7125
+ if (params?.pageSize) query.set("pageSize", String(params.pageSize));
7126
+ if (params?.cursor) query.set("cursor", params.cursor);
7127
+ const qs = query.toString() ? `?${query.toString()}` : "";
7128
+ return this.fetch(
7129
+ `w/${wid}/app-connections/salesforce/sync/logs${qs}`
7130
+ );
7131
+ }
6433
7132
  };
6434
7133
 
6435
7134
  // src/api/connection-sync.ts
@@ -6620,12 +7319,19 @@ var HubspotApi = class extends BaseApiClient {
6620
7319
  async getHubspotManagedRules(wid) {
6621
7320
  return this.fetch(`w/${wid}/app-connections/hubspot/managed-rules`);
6622
7321
  }
7322
+ /**
7323
+ * Managed-rule execution history for this connection (`GET /sync/logs`).
7324
+ * Rows are the shared rule-execution response (the same shape the Salesforce
7325
+ * and Monday twins return), with cursor pagination.
7326
+ */
6623
7327
  async getHubspotSyncLogs(wid, params) {
6624
7328
  const query = new URLSearchParams();
6625
7329
  if (params?.pageSize) query.set("pageSize", String(params.pageSize));
6626
7330
  if (params?.cursor) query.set("cursor", params.cursor);
6627
7331
  const qs = query.toString() ? `?${query.toString()}` : "";
6628
- return this.fetch(`w/${wid}/app-connections/hubspot/sync/logs${qs}`);
7332
+ return this.fetch(
7333
+ `w/${wid}/app-connections/hubspot/sync/logs${qs}`
7334
+ );
6629
7335
  }
6630
7336
  async getHubspotTransformPresets(wid) {
6631
7337
  return this.fetch(
@@ -7539,6 +8245,33 @@ var JourneysApi = class extends BaseApiClient {
7539
8245
  body: JSON.stringify(data)
7540
8246
  });
7541
8247
  }
8248
+ /**
8249
+ * Discard a saved editor draft, keeping the runnable definition.
8250
+ *
8251
+ * Body-less: a DELETE carries no document, only the resource to remove and
8252
+ * `expectedUpdatedAt` — the Journey's `updatedAt` as the caller loaded it —
8253
+ * proving they are removing the draft they were looking at. Encoded through
8254
+ * `URLSearchParams` because an ISO timestamp with a positive UTC offset
8255
+ * contains a `+`, which a raw template string would deliver to the server as
8256
+ * a space and turn into a revision conflict nobody can explain.
8257
+ *
8258
+ * Returns the AUTHORING projection (`Journey`) with `authoringDraft: null`
8259
+ * and the advanced `updatedAt`, so the caller can re-derive from the stored
8260
+ * definition without a second read.
8261
+ *
8262
+ * Refusals match the PUT's vocabulary: `journey_v2_definition_conflict`
8263
+ * (someone saved first — nothing was removed),
8264
+ * `journey_v2_structural_edit_not_allowed` (the Journey is live or archived)
8265
+ * and `journey_v2_execution_model_mismatch` (it is legacy). A Journey that
8266
+ * has no saved draft is a success, not an error — the state the caller asked
8267
+ * for is the state it is in.
8268
+ */
8269
+ async deleteJourneyDraft(wid, journeyId, expectedUpdatedAt) {
8270
+ const query = new URLSearchParams({ expectedUpdatedAt });
8271
+ return this.fetch(`w/${wid}/journeys/${journeyId}/draft?${query.toString()}`, {
8272
+ method: "DELETE"
8273
+ });
8274
+ }
7542
8275
  /**
7543
8276
  * List journeys, optionally including archived, paginated.
7544
8277
  *
@@ -8036,11 +8769,6 @@ var WorkflowsApi = class extends BaseApiClient {
8036
8769
  `w/${wid}/workflows/${workflowId}/tasks/${taskId}/chats?${params.toString()}`
8037
8770
  );
8038
8771
  }
8039
- async getWorkflowAccessValidation(wid, workflowId) {
8040
- return this.fetch(
8041
- `w/${wid}/workflows/${workflowId}/validate-access`
8042
- );
8043
- }
8044
8772
  async getWorkflowConfigValidation(wid, workflowId) {
8045
8773
  return this.fetch(
8046
8774
  `w/${wid}/workflows/${workflowId}/validate-config`
@@ -8308,21 +9036,6 @@ function encodePermissions(permissions) {
8308
9036
  if (permissions.delete) accessMode |= PERMISSION_DELETE;
8309
9037
  return accessMode;
8310
9038
  }
8311
- var WORKFLOW_IMPLICIT_USE_SCOPE = "workflows:admin";
8312
- function roleImplicitWorkflowUseScope(role) {
8313
- return (role.grantedScopes ?? []).includes(WORKFLOW_IMPLICIT_USE_SCOPE) ? WORKFLOW_IMPLICIT_USE_SCOPE : null;
8314
- }
8315
- function roleWorkflowAccess(role, workflowId) {
8316
- const viaScope = roleImplicitWorkflowUseScope(role);
8317
- if (viaScope) {
8318
- return { accessMode: PERMISSION_USE | PERMISSION_EDIT, viaScope };
8319
- }
8320
- const entry = (role.workflowAccess ?? []).find((wa) => wa.workflowId === workflowId);
8321
- return { accessMode: entry?.accessMode ?? PERMISSION_NONE, viaScope: null };
8322
- }
8323
- function roleCanUseWorkflow(role, workflowId) {
8324
- return (roleWorkflowAccess(role, workflowId).accessMode & PERMISSION_USE) !== 0;
8325
- }
8326
9039
  var Scope = /* @__PURE__ */ ((Scope2) => {
8327
9040
  Scope2["WORKSPACE_READ"] = "workspace:read";
8328
9041
  Scope2["WORKSPACE_WRITE"] = "workspace:write";
@@ -8391,6 +9104,7 @@ var Scope = /* @__PURE__ */ ((Scope2) => {
8391
9104
  Scope2["LABELS_READ"] = "labels:read";
8392
9105
  Scope2["LABELS_WRITE"] = "labels:write";
8393
9106
  Scope2["ANALYTICS_READ"] = "analytics:read";
9107
+ Scope2["ANONYMOUS_SUBMISSIONS_READ"] = "anonymous_submissions:read";
8394
9108
  Scope2["OPERATOR_READ"] = "operator:read";
8395
9109
  Scope2["OPERATOR_WRITE"] = "operator:write";
8396
9110
  Scope2["EXPORT_READ"] = "export:read";
@@ -8414,6 +9128,8 @@ var BulkMemberResultStatus = {
8414
9128
  skipped: "skipped"
8415
9129
  };
8416
9130
  var MemberImportMatchInfoMatchType = {
9131
+ id: "id",
9132
+ uuid: "uuid",
8417
9133
  external_id: "external_id",
8418
9134
  email: "email",
8419
9135
  phone: "phone",
@@ -8435,6 +9151,36 @@ var MergeMemberRolesRequestAccessStrategy = {
8435
9151
  target_only: "target_only"
8436
9152
  };
8437
9153
 
9154
+ // src/types/generated/member_contact_point.ts
9155
+ var CreateMemberContactPointRequestContactType = {
9156
+ phone: "phone",
9157
+ email: "email"
9158
+ };
9159
+ var CreateMemberContactPointRequestPurpose = {
9160
+ general: "general",
9161
+ notification: "notification",
9162
+ billing: "billing"
9163
+ };
9164
+ var CreateMemberContactPointRequestSharing = {
9165
+ shared: "shared",
9166
+ individual: "individual",
9167
+ unknown: "unknown"
9168
+ };
9169
+ var UpdateMemberContactPointRequestContactType = {
9170
+ phone: "phone",
9171
+ email: "email"
9172
+ };
9173
+ var UpdateMemberContactPointRequestPurpose = {
9174
+ general: "general",
9175
+ notification: "notification",
9176
+ billing: "billing"
9177
+ };
9178
+ var UpdateMemberContactPointRequestSharing = {
9179
+ shared: "shared",
9180
+ individual: "individual",
9181
+ unknown: "unknown"
9182
+ };
9183
+
8438
9184
  // src/types/member-types.ts
8439
9185
  var MemberType = /* @__PURE__ */ ((MemberType2) => {
8440
9186
  MemberType2["ANONYMOUS"] = "anonymous";
@@ -8521,6 +9267,7 @@ var EventRuleEventType = /* @__PURE__ */ ((EventRuleEventType2) => {
8521
9267
  EventRuleEventType2["CHAT_CREATED"] = "chat:created";
8522
9268
  EventRuleEventType2["CHAT_SUMMARY"] = "chat:summary";
8523
9269
  EventRuleEventType2["MESSAGE_CREATED"] = "message:created";
9270
+ EventRuleEventType2["LINK_CLICKED"] = "link:clicked";
8524
9271
  EventRuleEventType2["CHAT_CALLBACK"] = "chat:callback";
8525
9272
  EventRuleEventType2["MEMBER_UPDATED"] = "member:updated";
8526
9273
  EventRuleEventType2["ROUTINE_TRIGGERED"] = "routine:triggered";
@@ -8584,6 +9331,20 @@ function eventRuleActionParams(params) {
8584
9331
  }
8585
9332
  var MASKED_SECRET_SENTINEL = "__SECRET_SET__";
8586
9333
 
9334
+ // src/types/generated/credit_stop_service.ts
9335
+ var SendingNextStep = {
9336
+ add_credits: "add_credits",
9337
+ subscribe: "subscribe",
9338
+ contact_billing_owner: "contact_billing_owner"
9339
+ };
9340
+ var SendingStopState = {
9341
+ ok: "ok",
9342
+ credits_suspended: "credits_suspended",
9343
+ out_of_credits: "out_of_credits",
9344
+ operator_suspension: "operator_suspension",
9345
+ billing_unresolved: "billing_unresolved"
9346
+ };
9347
+
8587
9348
  // src/types/billing-types.ts
8588
9349
  var WorkspaceFeature = /* @__PURE__ */ ((WorkspaceFeature2) => {
8589
9350
  WorkspaceFeature2["PHONE"] = "phone";
@@ -8599,7 +9360,6 @@ var WorkspaceFeature = /* @__PURE__ */ ((WorkspaceFeature2) => {
8599
9360
  WorkspaceFeature2["WEB_SEARCH"] = "web_search";
8600
9361
  WorkspaceFeature2["CALENDAR"] = "calendar";
8601
9362
  WorkspaceFeature2["JOURNEY_V2_EDITOR"] = "journey_v2_editor";
8602
- WorkspaceFeature2["EXPERIMENTS"] = "experiments";
8603
9363
  WorkspaceFeature2["MAILBOX_USER_INPUT"] = "mailbox_user_input";
8604
9364
  WorkspaceFeature2["FORKED_TRAJECTORIES"] = "forked_trajectories";
8605
9365
  WorkspaceFeature2["GMAIL"] = "gmail";
@@ -8620,6 +9380,7 @@ var WorkspaceFeature = /* @__PURE__ */ ((WorkspaceFeature2) => {
8620
9380
  WorkspaceFeature2["IMAGE_GENERATION"] = "image_generation";
8621
9381
  WorkspaceFeature2["CHARLESTON_NEPHROLOGY_PMD_PAGING"] = "charleston_nephrology_pmd_paging";
8622
9382
  WorkspaceFeature2["PATIENTSYNC_TRANSFER"] = "patientsync_transfer";
9383
+ WorkspaceFeature2["COSAN_PATHWAYS_SCHEDULING"] = "cosan_pathways_scheduling";
8623
9384
  return WorkspaceFeature2;
8624
9385
  })(WorkspaceFeature || {});
8625
9386
  var MemberFeature = /* @__PURE__ */ ((MemberFeature2) => {
@@ -8724,6 +9485,7 @@ var ModelProvider = {
8724
9485
  deepgram: "deepgram",
8725
9486
  xai: "xai",
8726
9487
  fireworks: "fireworks",
9488
+ vercel: "vercel",
8727
9489
  custom: "custom"
8728
9490
  };
8729
9491
  var ModelType = {
@@ -8775,7 +9537,26 @@ var FhirClientType = /* @__PURE__ */ ((FhirClientType2) => {
8775
9537
  return FhirClientType2;
8776
9538
  })(FhirClientType || {});
8777
9539
 
9540
+ // src/types/app-connection-types.ts
9541
+ var CrmActivityKind = /* @__PURE__ */ ((CrmActivityKind2) => {
9542
+ CrmActivityKind2["MESSAGE"] = "message";
9543
+ CrmActivityKind2["SUMMARY"] = "summary";
9544
+ CrmActivityKind2["CHAT_STARTED"] = "chat_started";
9545
+ CrmActivityKind2["CALL_STARTED"] = "call_started";
9546
+ CrmActivityKind2["CALL_ENDED"] = "call_ended";
9547
+ return CrmActivityKind2;
9548
+ })(CrmActivityKind || {});
9549
+
8778
9550
  // src/types/generated/qualification.ts
9551
+ var RunHealthCategory = {
9552
+ passed: "passed",
9553
+ failed: "failed",
9554
+ running: "running",
9555
+ not_applicable: "not_applicable",
9556
+ awaiting_evaluation: "awaiting_evaluation",
9557
+ ungradeable: "ungradeable",
9558
+ incomplete: "incomplete"
9559
+ };
8779
9560
  var TestChatRunLane = {
8780
9561
  text: "text",
8781
9562
  web_realtime: "web_realtime",
@@ -8793,6 +9574,44 @@ var TestChatRunOutcome = {
8793
9574
  instrument_failure: "instrument_failure"
8794
9575
  };
8795
9576
 
9577
+ // src/types/generated/qualification_health_service.ts
9578
+ var ScenarioHealthCaption = {
9579
+ recent_passes: "recent_passes",
9580
+ pass_ratio: "pass_ratio",
9581
+ could_not_grade: "could_not_grade",
9582
+ awaiting_evaluation: "awaiting_evaluation",
9583
+ running: "running",
9584
+ not_run_since_test_change: "not_run_since_test_change",
9585
+ not_run_on_revision: "not_run_on_revision",
9586
+ never_run: "never_run"
9587
+ };
9588
+ var ScenarioHealthHeadline = {
9589
+ needs_attention: "needs_attention",
9590
+ no_results: "no_results",
9591
+ all_passing: "all_passing",
9592
+ no_scenarios: "no_scenarios"
9593
+ };
9594
+ var ScenarioHealthSampleNote = {
9595
+ low_sample: "low_sample"
9596
+ };
9597
+ var ScenarioHealthState = {
9598
+ failing: "failing",
9599
+ flaky: "flaky",
9600
+ no_results: "no_results",
9601
+ passing: "passing"
9602
+ };
9603
+
9604
+ // src/types/generated/qualification_health_summary.ts
9605
+ var RevisionHistorySegment = {
9606
+ before_test_change: "before_test_change"
9607
+ };
9608
+
9609
+ // src/types/generated/qualification_run_identity.ts
9610
+ var ScenarioRunBlocker = {
9611
+ missing_persona: "missing_persona",
9612
+ archived_persona: "archived_persona"
9613
+ };
9614
+
8796
9615
  // src/types/qualification-types.ts
8797
9616
  var CriterionType = /* @__PURE__ */ ((CriterionType2) => {
8798
9617
  CriterionType2["EXPRESSION"] = "expression";
@@ -9087,8 +9906,6 @@ var CONFIG_HEALTH_FACADE_CHECK_SLUGS = [
9087
9906
  "workflow.config",
9088
9907
  "journey.authoring",
9089
9908
  "journey.v2_validation",
9090
- "workflow.access",
9091
- "routine.workflow_access",
9092
9909
  "workspace.validation"
9093
9910
  ];
9094
9911
  function isConfigHealthFacadeCheckSlug(value) {
@@ -9780,17 +10597,17 @@ var WorkspacesApi = class extends BaseApiClient {
9780
10597
  body: JSON.stringify(payload)
9781
10598
  });
9782
10599
  }
9783
- /** List available themes for a workspace. */
10600
+ /**
10601
+ * List available themes for a workspace.
10602
+ *
10603
+ * Read-only: `…/themes` serves GET and nothing else. `Workspace.themes` is
10604
+ * an entitlement allowlist — which non-global themes this workspace may
10605
+ * select. There was never a `PUT …/themes` route; the
10606
+ * `updateWorkspaceThemes` method that targeted one always 405'd (GRA-8892).
10607
+ */
9784
10608
  async getWorkspaceThemes(wid) {
9785
10609
  return this.fetch(`w/${wid}/themes`);
9786
10610
  }
9787
- /** Update the active themes for a workspace. */
9788
- async updateWorkspaceThemes(wid, themes) {
9789
- return this.fetch(`w/${wid}/themes`, {
9790
- method: "PUT",
9791
- body: JSON.stringify({ themes })
9792
- });
9793
- }
9794
10611
  /**
9795
10612
  * Get all workspace-grantable scopes that can be assigned to member roles.
9796
10613
  *
@@ -9856,10 +10673,18 @@ var DashboardsApi = class extends BaseApiClient {
9856
10673
  `w/${wid}/dashboards/stats/channels${query ? `?${query}` : ""}`
9857
10674
  );
9858
10675
  }
9859
- /** Assignment status rollup per root workflow. */
9860
- async getDashboardWorkflowAssignmentStats(wid) {
10676
+ /**
10677
+ * Assignment status rollup per root workflow.
10678
+ *
10679
+ * `hours` windows the rollup to runs STARTED within the last N hours.
10680
+ * Omit it (or pass null) for the all-time rollup.
10681
+ */
10682
+ async getDashboardWorkflowAssignmentStats(wid, options) {
10683
+ const params = new URLSearchParams();
10684
+ if (options?.hours != null) params.append("hours", options.hours.toString());
10685
+ const query = params.toString();
9861
10686
  return this.fetch(
9862
- `w/${wid}/dashboards/stats/workflow-assignments`
10687
+ `w/${wid}/dashboards/stats/workflow-assignments${query ? `?${query}` : ""}`
9863
10688
  );
9864
10689
  }
9865
10690
  /**
@@ -10599,6 +11424,25 @@ var TrackedLinksApi = class extends BaseApiClient {
10599
11424
  }
10600
11425
  };
10601
11426
 
11427
+ // src/types/generated/bundle_contract.ts
11428
+ var BundleGrantRequestGranteeType = {
11429
+ organization: "organization",
11430
+ global: "global"
11431
+ };
11432
+ var FormBundleItemRecordScope = {
11433
+ member: "member",
11434
+ workspace: "workspace",
11435
+ anonymous: "anonymous"
11436
+ };
11437
+ var SolutionReleaseResponseSlug = {
11438
+ "member-enrollment": "member-enrollment",
11439
+ "member-reengagement": "member-reengagement",
11440
+ "treatment-adherence": "treatment-adherence",
11441
+ "heart-health": "heart-health",
11442
+ "recovery-checkins": "recovery-checkins",
11443
+ "care-coordination": "care-coordination"
11444
+ };
11445
+
10602
11446
  // src/app-context.ts
10603
11447
  function formatAppContextAsMarkdown(context) {
10604
11448
  if (!context) {
@@ -10675,6 +11519,8 @@ function createApiModules(apiKey, baseUrl, customFetch) {
10675
11519
  assignments: new AssignmentsApi(apiKey, baseUrl, customFetch),
10676
11520
  auth: new AuthApi(apiKey, baseUrl, customFetch),
10677
11521
  builders: new BuildersApi(apiKey, baseUrl, customFetch),
11522
+ bundles: new BundlesApi(apiKey, baseUrl, customFetch),
11523
+ installations: new InstallationsApi(apiKey, baseUrl, customFetch),
10678
11524
  calendars: new CalendarsApi(apiKey, baseUrl, customFetch),
10679
11525
  calls: new CallsApi(apiKey, baseUrl, customFetch),
10680
11526
  cel: new CELApi(apiKey, baseUrl, customFetch),
@@ -10723,6 +11569,8 @@ function createApiModules(apiKey, baseUrl, customFetch) {
10723
11569
  metrics: new MetricsApi(apiKey, baseUrl, customFetch),
10724
11570
  queries: new QueriesApi(apiKey, baseUrl, customFetch),
10725
11571
  reports: new ReportsApi(apiKey, baseUrl, customFetch),
11572
+ resourceWorkflows: new ResourceWorkflowsApi(apiKey, baseUrl, customFetch),
11573
+ routingRules: new RoutingRulesApi(apiKey, baseUrl, customFetch),
10726
11574
  salesforce: new SalesforceApi(apiKey, baseUrl, customFetch),
10727
11575
  sites: new SitesApi(apiKey, baseUrl, customFetch),
10728
11576
  subscriptions: new SubscriptionsApi(apiKey, baseUrl, customFetch),
@@ -10752,6 +11600,7 @@ var WORKSPACE_METHOD_NAMES = [
10752
11600
  "archiveDataType",
10753
11601
  "archiveJourney",
10754
11602
  "archiveMember",
11603
+ "archiveMemberByExternalId",
10755
11604
  "archiveMemberRelationship",
10756
11605
  "archivePersona",
10757
11606
  "archivePhoneNumber",
@@ -10778,7 +11627,6 @@ var WORKSPACE_METHOD_NAMES = [
10778
11627
  "checkSiteSlugAvailability",
10779
11628
  "claimDevicePairing",
10780
11629
  "clearConnectionMemberExclusion",
10781
- "clearMemberSwitch",
10782
11630
  "clearTrackedLinkDestinations",
10783
11631
  "clickWorkspaceSupportRequestResource",
10784
11632
  "cloneDataType",
@@ -10801,6 +11649,9 @@ var WORKSPACE_METHOD_NAMES = [
10801
11649
  "createAgent",
10802
11650
  "createApiKey",
10803
11651
  "createAssignment",
11652
+ "bindInstallationSlots",
11653
+ "restoreInstallationForm",
11654
+ "createBundle",
10804
11655
  "createCalendar",
10805
11656
  "createCalendarEvent",
10806
11657
  "createCalendarEventType",
@@ -10849,6 +11700,7 @@ var WORKSPACE_METHOD_NAMES = [
10849
11700
  "createPhoneNumber",
10850
11701
  "createProduct",
10851
11702
  "createRoutine",
11703
+ "createRoutingRule",
10852
11704
  "createScenario",
10853
11705
  "createSignup",
10854
11706
  "createSite",
@@ -10899,6 +11751,7 @@ var WORKSPACE_METHOD_NAMES = [
10899
11751
  "deleteGoal",
10900
11752
  "deleteHubspot",
10901
11753
  "deleteInbox",
11754
+ "deleteJourneyDraft",
10902
11755
  "deleteJourneyNote",
10903
11756
  "deleteMcpServer",
10904
11757
  "deleteMember",
@@ -10916,6 +11769,7 @@ var WORKSPACE_METHOD_NAMES = [
10916
11769
  "deletePlatformApp",
10917
11770
  "deleteProduct",
10918
11771
  "deleteRoutine",
11772
+ "deleteRoutingRule",
10919
11773
  "deleteSalesforce",
10920
11774
  "deleteScenario",
10921
11775
  "deleteSite",
@@ -10948,6 +11802,7 @@ var WORKSPACE_METHOD_NAMES = [
10948
11802
  "dismissAllNotifications",
10949
11803
  "dismissNotification",
10950
11804
  "downloadEmailAttachment",
11805
+ "downloadFileContents",
10951
11806
  "downloadFilesZip",
10952
11807
  "downloadSiteSourceZip",
10953
11808
  "editWorkflowRevisionAsDraft",
@@ -11010,6 +11865,7 @@ var WORKSPACE_METHOD_NAMES = [
11010
11865
  "getAgentTasks",
11011
11866
  "getAgents",
11012
11867
  "getAnonymousResolution",
11868
+ "getAnonymousFormSubmission",
11013
11869
  "getAnonymousResolutions",
11014
11870
  "getApiKeys",
11015
11871
  "getArchiveBlockers",
@@ -11023,6 +11879,12 @@ var WORKSPACE_METHOD_NAMES = [
11023
11879
  "getAvailableActions",
11024
11880
  "getAvailablePhoneNumbers",
11025
11881
  "getAvailableSlots",
11882
+ "getInstallation",
11883
+ "getInstallationReadiness",
11884
+ "getThemeSettingsSchema",
11885
+ "getBundleDraft",
11886
+ "getBundle",
11887
+ "getBundleVersion",
11026
11888
  "getBusinessHoursStatus",
11027
11889
  "getCalendar",
11028
11890
  "getCalendarEvent",
@@ -11035,8 +11897,11 @@ var WORKSPACE_METHOD_NAMES = [
11035
11897
  "getCelContext",
11036
11898
  "getCharlestonTestDeliveryRecipients",
11037
11899
  "getChat",
11900
+ "getChatByUuid",
11038
11901
  "getChatAssignmentTasks",
11039
11902
  "getChatBrowserLiveView",
11903
+ "saveChatBrowserStorage",
11904
+ "clearChatBrowserStorage",
11040
11905
  "getChatCallbacks",
11041
11906
  "getChatEhrWritebackOutcomes",
11042
11907
  "getChatEmails",
@@ -11082,6 +11947,7 @@ var WORKSPACE_METHOD_NAMES = [
11082
11947
  "getDashboardWorkflowAssignmentStats",
11083
11948
  "getDashboards",
11084
11949
  "getDataRecord",
11950
+ "getDataRecordByUuid",
11085
11951
  "getDataRecordChanges",
11086
11952
  "getDataRecordFilter",
11087
11953
  "getDataRecordFilterCount",
@@ -11199,6 +12065,7 @@ var WORKSPACE_METHOD_NAMES = [
11199
12065
  "getMcpServerResources",
11200
12066
  "getMcpServerTools",
11201
12067
  "getMcpServers",
12068
+ "getMemberByUuid",
11202
12069
  "getMemberExperiments",
11203
12070
  "getMemberFieldDefinitions",
11204
12071
  "getMemberFields",
@@ -11230,6 +12097,7 @@ var WORKSPACE_METHOD_NAMES = [
11230
12097
  "getMondayConnectionStatus",
11231
12098
  "getMondayReconciliationMatches",
11232
12099
  "getMondaySyncConfig",
12100
+ "getMondaySyncLogs",
11233
12101
  "getMyCredentials",
11234
12102
  "getMyGivenGrants",
11235
12103
  "getMyReceivedGrants",
@@ -11240,7 +12108,6 @@ var WORKSPACE_METHOD_NAMES = [
11240
12108
  "getOperatorGroup",
11241
12109
  "getOperatorGroups",
11242
12110
  "getOrCreateQualificationForWorkflow",
11243
- "getOwnedMembers",
11244
12111
  "getPage",
11245
12112
  "getPageBySlug",
11246
12113
  "getPersona",
@@ -11270,11 +12137,14 @@ var WORKSPACE_METHOD_NAMES = [
11270
12137
  "getRoutineConfigEvents",
11271
12138
  "getRoutineRuns",
11272
12139
  "getRoutines",
12140
+ "getRoutingRule",
12141
+ "getRoutingRules",
11273
12142
  "getRuleExecutions",
11274
12143
  "getSMSUsageReport",
11275
12144
  "getSalesforceReconciliationMatches",
11276
12145
  "getSalesforceStatus",
11277
12146
  "getSalesforceSyncConfig",
12147
+ "getSalesforceSyncLogs",
11278
12148
  "getScenario",
11279
12149
  "getSite",
11280
12150
  "getSiteByUuid",
@@ -11320,7 +12190,6 @@ var WORKSPACE_METHOD_NAMES = [
11320
12190
  "getWebhookLogs",
11321
12191
  "getWorkflow",
11322
12192
  "getWorkflowOpeningTurnConversionReport",
11323
- "getWorkflowAccessValidation",
11324
12193
  "getWorkflowActivity",
11325
12194
  "getWorkflowConfigValidation",
11326
12195
  "getWorkflowFeedback",
@@ -11351,6 +12220,8 @@ var WORKSPACE_METHOD_NAMES = [
11351
12220
  "getWorkspaceSubscriptions",
11352
12221
  "getWorkspaceSupportRequest",
11353
12222
  "getWorkspaceThemes",
12223
+ "installBundle",
12224
+ "grantBundle",
11354
12225
  "importFromBoard",
11355
12226
  "importHubspotMembers",
11356
12227
  "importMembers",
@@ -11373,13 +12244,23 @@ var WORKSPACE_METHOD_NAMES = [
11373
12244
  "linkMemberToMonday",
11374
12245
  "linkMemberToSalesforce",
11375
12246
  "linkPhoneNumber",
12247
+ "linkUnlinkedSalesforceMembersByIdentity",
11376
12248
  "listAbilities",
12249
+ "listAnonymousFormSubmissions",
11377
12250
  "listAppConnections",
11378
12251
  "listAvailableAppConnections",
12252
+ "listInstallations",
12253
+ "listBundleGrants",
12254
+ "listBundleVersions",
12255
+ "listBundles",
12256
+ "listBundleWorkflowCandidates",
12257
+ "updateBundle",
12258
+ "listBundleInstallations",
11379
12259
  "listConfluencePages",
11380
12260
  "listConfluenceSpaces",
11381
12261
  "listConnectionMemberFieldKeys",
11382
12262
  "listContactPermissions",
12263
+ "revokeBundleGrant",
11383
12264
  "rollbackSiteSource",
11384
12265
  "rotateDocumoFaxCredentials",
11385
12266
  "runQuery",
@@ -11400,7 +12281,11 @@ var WORKSPACE_METHOD_NAMES = [
11400
12281
  "getMetricSeries",
11401
12282
  "computeChatMetrics",
11402
12283
  "listPushSubscriptions",
12284
+ "listResourceWorkflows",
12285
+ "getResourceWorkflow",
12286
+ "getResourceWorkflowRevision",
11403
12287
  "listSalesforceObjects",
12288
+ "listScenarioHealthSummaries",
11404
12289
  "listScenarios",
11405
12290
  "listTestChatRuns",
11406
12291
  "listWidgetDomains",
@@ -11416,15 +12301,18 @@ var WORKSPACE_METHOD_NAMES = [
11416
12301
  "previewRenameFieldSlug",
11417
12302
  "previewImportWorkspace",
11418
12303
  "previewInboxEmail",
12304
+ "preflightBundleInstallation",
11419
12305
  "previewRoutineVoiceReadiness",
11420
- "previewRoutineWorkflowAccess",
11421
12306
  "previewSchedule",
12307
+ "previewRoutingRule",
11422
12308
  "previewTTS",
11423
12309
  "previewTemplate",
11424
12310
  "previewThinkingSound",
11425
12311
  "previewWorkspaceImport",
11426
12312
  "previewWorkspaceImportZip",
11427
12313
  "provisionClientWorkspace",
12314
+ "previewInstallationUpgrade",
12315
+ "publishBundle",
11428
12316
  "publishWorkflowRevision",
11429
12317
  "putJourneyDraft",
11430
12318
  "putJourneyV2Definition",
@@ -11436,11 +12324,16 @@ var WORKSPACE_METHOD_NAMES = [
11436
12324
  "registerPushSubscription",
11437
12325
  "reindexFolder",
11438
12326
  "releasePhoneNumber",
12327
+ "reorderRoutingRules",
11439
12328
  "removeFileRole",
11440
12329
  "removeFolderRole",
11441
12330
  "removeGroupMember",
11442
12331
  "reorderEventRules",
11443
12332
  "reorderMenuItems",
12333
+ "reconcileInstallation",
12334
+ "setInstallationPolicy",
12335
+ "upgradeInstallation",
12336
+ "replaceBundleDraft",
11444
12337
  "replyToEmail",
11445
12338
  "rotateDocumoFaxCredentials",
11446
12339
  "requestPhoneNumber",
@@ -11476,7 +12369,6 @@ var WORKSPACE_METHOD_NAMES = [
11476
12369
  "startSyncRun",
11477
12370
  "startTestChatRun",
11478
12371
  "summarizeChat",
11479
- "switchMember",
11480
12372
  "syncCalendarWithGoogle",
11481
12373
  "syncCalendarWithHealthie",
11482
12374
  "testFhirConnection",
@@ -11489,6 +12381,7 @@ var WORKSPACE_METHOD_NAMES = [
11489
12381
  "unarchiveChat",
11490
12382
  "unarchiveDataType",
11491
12383
  "unarchiveMember",
12384
+ "unarchiveMemberByExternalId",
11492
12385
  "unarchivePersona",
11493
12386
  "unarchiveStep",
11494
12387
  "unarchiveTask",
@@ -11546,6 +12439,7 @@ var WORKSPACE_METHOD_NAMES = [
11546
12439
  "updateJourneyNote",
11547
12440
  "updateMcpServer",
11548
12441
  "updateMember",
12442
+ "updateMemberByExternalId",
11549
12443
  "updateMemberField",
11550
12444
  "updateMemberFilter",
11551
12445
  "updateMemberLabel",
@@ -11562,6 +12456,7 @@ var WORKSPACE_METHOD_NAMES = [
11562
12456
  "updateProduct",
11563
12457
  "updateProject",
11564
12458
  "updateRoutine",
12459
+ "updateRoutingRule",
11565
12460
  "updateSalesforceSyncConfig",
11566
12461
  "resyncSalesforceLinkedMembers",
11567
12462
  "updateScenario",
@@ -11584,7 +12479,6 @@ var WORKSPACE_METHOD_NAMES = [
11584
12479
  "updateWorkspace",
11585
12480
  "updateWorkspaceDefaults",
11586
12481
  "updateWorkspaceInvitationAdmin",
11587
- "updateWorkspaceThemes",
11588
12482
  "upsertDataRecord",
11589
12483
  "upsertWidgetDomain",
11590
12484
  "validateCelExpression",
@@ -11675,6 +12569,9 @@ function bindChatsMethods(target, chats) {
11675
12569
  target.transitionChatInteractionSession = chats.transitionChatInteractionSession.bind(chats);
11676
12570
  target.getChats = chats.getChats.bind(chats);
11677
12571
  target.getChat = chats.getChat.bind(chats);
12572
+ target.getChatByUuid = chats.getChatByUuid.bind(chats);
12573
+ target.saveChatBrowserStorage = chats.saveChatBrowserStorage.bind(chats);
12574
+ target.clearChatBrowserStorage = chats.clearChatBrowserStorage.bind(chats);
11678
12575
  target.getChatBrowserLiveView = chats.getChatBrowserLiveView.bind(chats);
11679
12576
  target.getChatMachineResources = chats.getChatMachineResources.bind(chats);
11680
12577
  target.getCurrentSmsChat = chats.getCurrentSmsChat.bind(chats);
@@ -11811,7 +12708,10 @@ function bindDataTypesMethods(target, dataTypes) {
11811
12708
  target.unarchiveDataType = dataTypes.unarchiveDataType.bind(dataTypes);
11812
12709
  target.cloneDataType = dataTypes.cloneDataType.bind(dataTypes);
11813
12710
  target.getDataRecords = dataTypes.getDataRecords.bind(dataTypes);
12711
+ target.listAnonymousFormSubmissions = dataTypes.listAnonymousFormSubmissions.bind(dataTypes);
12712
+ target.getAnonymousFormSubmission = dataTypes.getAnonymousFormSubmission.bind(dataTypes);
11814
12713
  target.getDataRecord = dataTypes.getDataRecord.bind(dataTypes);
12714
+ target.getDataRecordByUuid = dataTypes.getDataRecordByUuid.bind(dataTypes);
11815
12715
  target.createDataRecord = dataTypes.createDataRecord.bind(dataTypes);
11816
12716
  target.updateDataRecord = dataTypes.updateDataRecord.bind(dataTypes);
11817
12717
  target.deleteDataRecord = dataTypes.deleteDataRecord.bind(dataTypes);
@@ -11850,18 +12750,19 @@ function bindMembersMethods(target, members) {
11850
12750
  target.previewMemberWorkflowVoice = members.previewMemberWorkflowVoice.bind(members);
11851
12751
  target.setMemberWorkflowVoice = members.setMemberWorkflowVoice.bind(members);
11852
12752
  target.clearMemberWorkflowVoice = members.clearMemberWorkflowVoice.bind(members);
11853
- target.getOwnedMembers = members.getOwnedMembers.bind(members);
11854
- target.switchMember = members.switchMember.bind(members);
11855
- target.clearMemberSwitch = members.clearMemberSwitch.bind(members);
11856
12753
  target.updateCurrentMember = members.updateCurrentMember.bind(members);
11857
12754
  target.getWorkspaceMembers = members.getWorkspaceMembers.bind(members);
11858
12755
  target.getWorkspaceMember = members.getWorkspaceMember.bind(members);
12756
+ target.getMemberByUuid = members.getMemberByUuid.bind(members);
11859
12757
  target.getOrgWorkspaceMember = members.getOrgWorkspaceMember.bind(members);
11860
12758
  target.createWorkspaceMember = members.createWorkspaceMember.bind(members);
11861
12759
  target.updateMember = members.updateMember.bind(members);
11862
12760
  target.deleteMember = members.deleteMember.bind(members);
11863
12761
  target.archiveMember = members.archiveMember.bind(members);
11864
12762
  target.unarchiveMember = members.unarchiveMember.bind(members);
12763
+ target.updateMemberByExternalId = members.updateMemberByExternalId.bind(members);
12764
+ target.archiveMemberByExternalId = members.archiveMemberByExternalId.bind(members);
12765
+ target.unarchiveMemberByExternalId = members.unarchiveMemberByExternalId.bind(members);
11865
12766
  target.sendMemberPhoneConfirmation = members.sendMemberPhoneConfirmation.bind(members);
11866
12767
  target.bulkCreateMembers = members.bulkCreateMembers.bind(members);
11867
12768
  target.previewImportMembers = members.previewImportMembers.bind(members);
@@ -11963,7 +12864,6 @@ function bindWorkspacesMethods(target, workspaces, signupRequests) {
11963
12864
  target.rebuildImportSkippedRules = workspaces.rebuildImportSkippedRules.bind(workspaces);
11964
12865
  target.previewImportWorkspace = workspaces.previewImportWorkspace.bind(workspaces);
11965
12866
  target.getWorkspaceThemes = workspaces.getWorkspaceThemes.bind(workspaces);
11966
- target.updateWorkspaceThemes = workspaces.updateWorkspaceThemes.bind(workspaces);
11967
12867
  target.getWorkspaceBySlug = workspaces.getWorkspace.bind(workspaces);
11968
12868
  target.getWorkspaceScopes = workspaces.getWorkspaceScopes.bind(workspaces);
11969
12869
  target.getUsageDashboard = workspaces.getUsageDashboard.bind(workspaces);
@@ -12012,6 +12912,7 @@ function bindAuthMethods(target, auth, assignments) {
12012
12912
  target.logout = auth.logout.bind(auth);
12013
12913
  target.requestCrossDomainToken = auth.requestCrossDomainToken.bind(auth);
12014
12914
  target.exchangeToken = auth.exchangeToken.bind(auth);
12915
+ target.createRealtimeLoginToken = auth.createRealtimeLoginToken.bind(auth);
12015
12916
  target.getDomainMapping = auth.getDomainMapping.bind(auth);
12016
12917
  target.createSignup = auth.createSignup.bind(auth);
12017
12918
  target.createAccount = auth.emailPasswordSignup.bind(auth);
@@ -12101,6 +13002,7 @@ function bindSitesMethods(target, sites) {
12101
13002
  function bindFilesMethods(target, files) {
12102
13003
  target.getFiles = files.getFiles.bind(files);
12103
13004
  target.getFile = files.getFile.bind(files);
13005
+ target.downloadFileContents = files.downloadFileContents.bind(files);
12104
13006
  target.downloadFilesZip = files.downloadFilesZip.bind(files);
12105
13007
  target.createFile = files.createFile.bind(files);
12106
13008
  target.uploadFile = files.uploadFile.bind(files);
@@ -12173,7 +13075,6 @@ function bindEventsMethods(target, events) {
12173
13075
  target.resetRoutineRuns = events.resetRoutineRuns.bind(events);
12174
13076
  target.previewSchedule = events.previewSchedule.bind(events);
12175
13077
  target.previewRoutineVoiceReadiness = events.previewRoutineVoiceReadiness.bind(events);
12176
- target.previewRoutineWorkflowAccess = events.previewRoutineWorkflowAccess.bind(events);
12177
13078
  }
12178
13079
 
12179
13080
  // src/client/bindings/experiments.ts
@@ -12214,7 +13115,6 @@ function bindWorkflowsMethods(target, workflows, workflowNotes, voice, superviso
12214
13115
  target.createWorkflowFromTemplate = workflows.createWorkflowFromTemplate.bind(workflows);
12215
13116
  target.getWorkflowTaskAssignmentStats = workflows.getWorkflowTaskAssignmentStats.bind(workflows);
12216
13117
  target.getTaskChats = workflows.getTaskChats.bind(workflows);
12217
- target.getWorkflowAccessValidation = workflows.getWorkflowAccessValidation.bind(workflows);
12218
13118
  target.getWorkflowConfigValidation = workflows.getWorkflowConfigValidation.bind(workflows);
12219
13119
  target.getWorkflowNotes = workflowNotes.getWorkflowNotes.bind(workflowNotes);
12220
13120
  target.createWorkflowNote = workflowNotes.createWorkflowNote.bind(workflowNotes);
@@ -12335,6 +13235,7 @@ function bindToolkitsMethods(target, toolkits, templates, aiModels, customToolki
12335
13235
  target.previewTemplate = templates.previewTemplate.bind(templates);
12336
13236
  target.getVariableRegistry = templates.getVariableRegistry.bind(templates);
12337
13237
  target.getChatModels = aiModels.getChatModels.bind(aiModels);
13238
+ target.getManagerModels = aiModels.getManagerModels.bind(aiModels);
12338
13239
  target.getRealtimeModels = aiModels.getRealtimeModels.bind(aiModels);
12339
13240
  target.getSTTModels = aiModels.getSTTModels.bind(aiModels);
12340
13241
  target.getTTSModels = aiModels.getTTSModels.bind(aiModels);
@@ -12448,6 +13349,7 @@ function bindIntegrationsMethods(target, mondayIntegration, discordBots, slackAp
12448
13349
  target.getMondayConnectionBoardColumns = mondayIntegration.getMondayConnectionBoardColumns.bind(mondayIntegration);
12449
13350
  target.getMondayConnectionBoardGroups = mondayIntegration.getMondayConnectionBoardGroups.bind(mondayIntegration);
12450
13351
  target.getMondaySyncConfig = mondayIntegration.getMondaySyncConfig.bind(mondayIntegration);
13352
+ target.getMondaySyncLogs = mondayIntegration.getMondaySyncLogs.bind(mondayIntegration);
12451
13353
  target.updateMondaySyncConfig = mondayIntegration.updateMondaySyncConfig.bind(mondayIntegration);
12452
13354
  target.getLinkedMondayMembers = mondayIntegration.getLinkedMondayMembers.bind(mondayIntegration);
12453
13355
  target.getMondayReconciliationMatches = mondayIntegration.getMondayReconciliationMatches.bind(mondayIntegration);
@@ -12562,10 +13464,12 @@ function bindIntegrationsMethods(target, mondayIntegration, discordBots, slackAp
12562
13464
  target.deleteSalesforce = salesforce.deleteSalesforce.bind(salesforce);
12563
13465
  target.getSalesforceReconciliationMatches = salesforce.getSalesforceReconciliationMatches.bind(salesforce);
12564
13466
  target.linkMemberToSalesforce = salesforce.linkMemberToSalesforce.bind(salesforce);
13467
+ target.linkUnlinkedSalesforceMembersByIdentity = salesforce.linkUnlinkedSalesforceMembersByIdentity.bind(salesforce);
12565
13468
  target.bulkLinkMembersToSalesforce = salesforce.bulkLinkMembersToSalesforce.bind(salesforce);
12566
13469
  target.unlinkMemberFromSalesforce = salesforce.unlinkMemberFromSalesforce.bind(salesforce);
12567
13470
  target.getLinkedSalesforceMembers = salesforce.getLinkedSalesforceMembers.bind(salesforce);
12568
13471
  target.getSalesforceSyncConfig = salesforce.getSalesforceSyncConfig.bind(salesforce);
13472
+ target.getSalesforceSyncLogs = salesforce.getSalesforceSyncLogs.bind(salesforce);
12569
13473
  target.updateSalesforceSyncConfig = salesforce.updateSalesforceSyncConfig.bind(salesforce);
12570
13474
  target.resyncSalesforceLinkedMembers = salesforce.resyncSalesforceLinkedMembers.bind(salesforce);
12571
13475
  target.listSalesforceObjects = salesforce.listSalesforceObjects.bind(salesforce);
@@ -12655,10 +13559,15 @@ function bindOrgMethods(target, org) {
12655
13559
  target.getVoiceTrustProducts = org.getVoiceTrustProducts.bind(org);
12656
13560
  target.syncVoiceTrustProducts = org.syncVoiceTrustProducts.bind(org);
12657
13561
  target.createOrganizationWorkspace = org.createOrganizationWorkspace.bind(org);
13562
+ target.getOrganizationWorkspace = org.getOrganizationWorkspace.bind(org);
13563
+ target.updateOrganizationWorkspace = org.updateOrganizationWorkspace.bind(org);
12658
13564
  target.getOrgBillingCustomer = org.getOrgBillingCustomer.bind(org);
12659
13565
  target.getA2PCampaignConfig = org.getA2PCampaignConfig.bind(org);
12660
13566
  target.updateA2PCampaignConfig = org.updateA2PCampaignConfig.bind(org);
12661
13567
  target.getOrgWorkspaceUsage = org.getOrgWorkspaceUsage.bind(org);
13568
+ target.updateOrganizationMember = org.updateOrganizationMember.bind(org);
13569
+ target.listOrgWebhookEndpoints = org.listOrgWebhookEndpoints.bind(org);
13570
+ target.getOrgWebhookEndpoint = org.getOrgWebhookEndpoint.bind(org);
12662
13571
  }
12663
13572
 
12664
13573
  // src/client/bindings/pronunciations.ts
@@ -12678,12 +13587,58 @@ function bindPronunciationsMethods(target, pronunciations) {
12678
13587
  target.previewPronunciation = pronunciations.previewPronunciation.bind(pronunciations);
12679
13588
  }
12680
13589
 
13590
+ // src/client/bindings/resource-workflows.ts
13591
+ function bindResourceWorkflowsMethods(target, resourceWorkflows) {
13592
+ target.getResourceWorkflow = resourceWorkflows.getResourceWorkflow.bind(resourceWorkflows);
13593
+ target.getResourceWorkflowRevision = resourceWorkflows.getResourceWorkflowRevision.bind(resourceWorkflows);
13594
+ }
13595
+
13596
+ // src/client/bindings/bundles.ts
13597
+ function bindBundlesMethods(target, bundles, resourceWorkflows) {
13598
+ bindResourceWorkflowsMethods(target, resourceWorkflows);
13599
+ target.getSolutionRelease = bundles.getSolutionRelease.bind(bundles);
13600
+ target.updateBundle = bundles.updateBundle.bind(bundles);
13601
+ target.listBundleInstallations = bundles.listBundleInstallations.bind(bundles);
13602
+ target.listBundles = bundles.listBundles.bind(bundles);
13603
+ target.listBundleWorkflowCandidates = bundles.listBundleWorkflowCandidates.bind(bundles);
13604
+ target.createBundle = bundles.createBundle.bind(bundles);
13605
+ target.getBundleDraft = bundles.getBundleDraft.bind(bundles);
13606
+ target.replaceBundleDraft = bundles.replaceBundleDraft.bind(bundles);
13607
+ target.publishBundle = bundles.publishBundle.bind(bundles);
13608
+ target.listBundleVersions = bundles.listBundleVersions.bind(bundles);
13609
+ target.getBundle = bundles.getBundle.bind(bundles);
13610
+ target.getBundleVersion = bundles.getBundleVersion.bind(bundles);
13611
+ target.listBundleGrants = bundles.listBundleGrants.bind(bundles);
13612
+ target.grantBundle = bundles.grantBundle.bind(bundles);
13613
+ target.revokeBundleGrant = bundles.revokeBundleGrant.bind(bundles);
13614
+ target.listResourceWorkflows = resourceWorkflows.listResourceWorkflows.bind(resourceWorkflows);
13615
+ }
13616
+
13617
+ // src/client/bindings/installations.ts
13618
+ function bindInstallationsMethods(target, installations) {
13619
+ target.preflightBundleInstallation = installations.preflightBundleInstallation.bind(installations);
13620
+ target.installBundle = installations.installBundle.bind(installations);
13621
+ target.listInstallations = installations.listInstallations.bind(installations);
13622
+ target.getInstallation = installations.getInstallation.bind(installations);
13623
+ target.getInstallationReadiness = installations.getInstallationReadiness.bind(installations);
13624
+ target.previewInstallationUpgrade = installations.previewInstallationUpgrade.bind(installations);
13625
+ target.upgradeInstallation = installations.upgradeInstallation.bind(installations);
13626
+ target.setInstallationPolicy = installations.setInstallationPolicy.bind(installations);
13627
+ target.unsubscribeInstallation = installations.unsubscribeInstallation.bind(installations);
13628
+ target.restoreInstallationForm = installations.restoreInstallationForm.bind(installations);
13629
+ target.restoreInstallationWorkflowResources = installations.restoreInstallationWorkflowResources.bind(installations);
13630
+ target.bindInstallationSlots = installations.bindInstallationSlots.bind(installations);
13631
+ target.reconcileInstallation = installations.reconcileInstallation.bind(installations);
13632
+ target.getThemeSettingsSchema = installations.getThemeSettingsSchema.bind(installations);
13633
+ }
13634
+
12681
13635
  // src/client/bindings/journeys.ts
12682
13636
  function bindJourneysMethods(target, journeys) {
12683
13637
  target.getJourneys = journeys.getJourneys.bind(journeys);
12684
13638
  target.getJourney = journeys.getJourney.bind(journeys);
12685
13639
  target.getJourneyAuthoring = journeys.getJourneyAuthoring.bind(journeys);
12686
13640
  target.putJourneyDraft = journeys.putJourneyDraft.bind(journeys);
13641
+ target.deleteJourneyDraft = journeys.deleteJourneyDraft.bind(journeys);
12687
13642
  target.putJourneyV2Definition = journeys.putJourneyV2Definition.bind(journeys);
12688
13643
  target.getJourneyV2Validation = journeys.getJourneyV2Validation.bind(journeys);
12689
13644
  target.getJourneyFilterOptions = journeys.getJourneyFilterOptions.bind(journeys);
@@ -12731,6 +13686,7 @@ function bindQualificationsMethods(target, qualifications) {
12731
13686
  target.updateScenario = qualifications.updateScenario.bind(qualifications);
12732
13687
  target.deleteScenario = qualifications.deleteScenario.bind(qualifications);
12733
13688
  target.listTestChatRuns = qualifications.listTestChatRuns.bind(qualifications);
13689
+ target.listScenarioHealthSummaries = qualifications.listScenarioHealthSummaries.bind(qualifications);
12734
13690
  target.getTestChatRun = qualifications.getTestChatRun.bind(qualifications);
12735
13691
  target.startTestChatRun = qualifications.startTestChatRun.bind(qualifications);
12736
13692
  target.evaluateTestChatRun = qualifications.evaluateTestChatRun.bind(qualifications);
@@ -12819,6 +13775,17 @@ function bindSupportRequestMethods(target, supportRequests) {
12819
13775
  target.clickWorkspaceSupportRequestResource = supportRequests.clickWorkspaceSupportRequestResource.bind(supportRequests);
12820
13776
  }
12821
13777
 
13778
+ // src/client/bindings/routing-rules.ts
13779
+ function bindRoutingRulesMethods(target, routingRules) {
13780
+ target.getRoutingRules = routingRules.getRoutingRules.bind(routingRules);
13781
+ target.getRoutingRule = routingRules.getRoutingRule.bind(routingRules);
13782
+ target.createRoutingRule = routingRules.createRoutingRule.bind(routingRules);
13783
+ target.updateRoutingRule = routingRules.updateRoutingRule.bind(routingRules);
13784
+ target.deleteRoutingRule = routingRules.deleteRoutingRule.bind(routingRules);
13785
+ target.reorderRoutingRules = routingRules.reorderRoutingRules.bind(routingRules);
13786
+ target.previewRoutingRule = routingRules.previewRoutingRule.bind(routingRules);
13787
+ }
13788
+
12822
13789
  // src/client/client.ts
12823
13790
  var GravityRailClient = class {
12824
13791
  // WorkspaceInvitations is exposed publicly for backward compatibility
@@ -12844,6 +13811,9 @@ var GravityRailClient = class {
12844
13811
  // Chats API
12845
13812
  getChats;
12846
13813
  getChat;
13814
+ getChatByUuid;
13815
+ saveChatBrowserStorage;
13816
+ clearChatBrowserStorage;
12847
13817
  getChatBrowserLiveView;
12848
13818
  getChatMachineResources;
12849
13819
  getCurrentSmsChat;
@@ -12921,7 +13891,10 @@ var GravityRailClient = class {
12921
13891
  unarchiveDataType;
12922
13892
  cloneDataType;
12923
13893
  getDataRecords;
13894
+ listAnonymousFormSubmissions;
13895
+ getAnonymousFormSubmission;
12924
13896
  getDataRecord;
13897
+ getDataRecordByUuid;
12925
13898
  createDataRecord;
12926
13899
  updateDataRecord;
12927
13900
  deleteDataRecord;
@@ -12947,12 +13920,10 @@ var GravityRailClient = class {
12947
13920
  previewMemberWorkflowVoice;
12948
13921
  setMemberWorkflowVoice;
12949
13922
  clearMemberWorkflowVoice;
12950
- getOwnedMembers;
12951
- switchMember;
12952
- clearMemberSwitch;
12953
13923
  updateCurrentMember;
12954
13924
  getWorkspaceMembers;
12955
13925
  getWorkspaceMember;
13926
+ getMemberByUuid;
12956
13927
  // Org-scoped, so deliberately absent from WORKSPACE_METHOD_NAMES: that proxy
12957
13928
  // passes a workspace uuid as the first argument.
12958
13929
  getOrgWorkspaceMember;
@@ -12961,6 +13932,9 @@ var GravityRailClient = class {
12961
13932
  deleteMember;
12962
13933
  archiveMember;
12963
13934
  unarchiveMember;
13935
+ updateMemberByExternalId;
13936
+ archiveMemberByExternalId;
13937
+ unarchiveMemberByExternalId;
12964
13938
  sendMemberPhoneConfirmation;
12965
13939
  bulkCreateMembers;
12966
13940
  previewImportMembers;
@@ -13038,6 +14012,7 @@ var GravityRailClient = class {
13038
14012
  updateScenario;
13039
14013
  deleteScenario;
13040
14014
  listTestChatRuns;
14015
+ listScenarioHealthSummaries;
13041
14016
  getTestChatRun;
13042
14017
  startTestChatRun;
13043
14018
  evaluateTestChatRun;
@@ -13115,6 +14090,7 @@ var GravityRailClient = class {
13115
14090
  getJourney;
13116
14091
  getJourneyAuthoring;
13117
14092
  putJourneyDraft;
14093
+ deleteJourneyDraft;
13118
14094
  putJourneyV2Definition;
13119
14095
  getJourneyV2Validation;
13120
14096
  getJourneyFilterOptions;
@@ -13149,6 +14125,41 @@ var GravityRailClient = class {
13149
14125
  createJourneyNote;
13150
14126
  updateJourneyNote;
13151
14127
  deleteJourneyNote;
14128
+ updateBundle;
14129
+ listBundleInstallations;
14130
+ // Bundles API
14131
+ getSolutionRelease;
14132
+ listBundles;
14133
+ listBundleWorkflowCandidates;
14134
+ createBundle;
14135
+ getBundleDraft;
14136
+ replaceBundleDraft;
14137
+ publishBundle;
14138
+ listBundleVersions;
14139
+ getBundle;
14140
+ getBundleVersion;
14141
+ listBundleGrants;
14142
+ grantBundle;
14143
+ revokeBundleGrant;
14144
+ listResourceWorkflows;
14145
+ // Resource Workflows API — published Workflow catalog reads
14146
+ getResourceWorkflow;
14147
+ getResourceWorkflowRevision;
14148
+ // Installations API
14149
+ preflightBundleInstallation;
14150
+ installBundle;
14151
+ listInstallations;
14152
+ getInstallation;
14153
+ getInstallationReadiness;
14154
+ previewInstallationUpgrade;
14155
+ upgradeInstallation;
14156
+ setInstallationPolicy;
14157
+ unsubscribeInstallation;
14158
+ bindInstallationSlots;
14159
+ restoreInstallationForm;
14160
+ restoreInstallationWorkflowResources;
14161
+ reconcileInstallation;
14162
+ getThemeSettingsSchema;
13152
14163
  // Experiments API
13153
14164
  getExperiments;
13154
14165
  getExperiment;
@@ -13241,7 +14252,6 @@ var GravityRailClient = class {
13241
14252
  rebuildImportSkippedRules;
13242
14253
  previewImportWorkspace;
13243
14254
  getWorkspaceThemes;
13244
- updateWorkspaceThemes;
13245
14255
  getWorkspaceBySlug;
13246
14256
  getWorkspaceScopes;
13247
14257
  getUsageDashboard;
@@ -13280,10 +14290,15 @@ var GravityRailClient = class {
13280
14290
  getVoiceTrustProducts;
13281
14291
  syncVoiceTrustProducts;
13282
14292
  createOrganizationWorkspace;
14293
+ getOrganizationWorkspace;
14294
+ updateOrganizationWorkspace;
13283
14295
  getOrgBillingCustomer;
13284
14296
  getA2PCampaignConfig;
13285
14297
  updateA2PCampaignConfig;
13286
14298
  getOrgWorkspaceUsage;
14299
+ updateOrganizationMember;
14300
+ listOrgWebhookEndpoints;
14301
+ getOrgWebhookEndpoint;
13287
14302
  getVapidPublicKey;
13288
14303
  registerPushSubscription;
13289
14304
  unregisterPushSubscription;
@@ -13320,6 +14335,7 @@ var GravityRailClient = class {
13320
14335
  logout;
13321
14336
  requestCrossDomainToken;
13322
14337
  exchangeToken;
14338
+ createRealtimeLoginToken;
13323
14339
  getDomainMapping;
13324
14340
  createSignup;
13325
14341
  createAccount;
@@ -13409,6 +14425,7 @@ var GravityRailClient = class {
13409
14425
  updateProject;
13410
14426
  updatePlan;
13411
14427
  resolveFilePath;
14428
+ downloadFileContents;
13412
14429
  downloadFilesZip;
13413
14430
  createFile;
13414
14431
  uploadFile;
@@ -13469,7 +14486,6 @@ var GravityRailClient = class {
13469
14486
  resetRoutineRuns;
13470
14487
  previewSchedule;
13471
14488
  previewRoutineVoiceReadiness;
13472
- previewRoutineWorkflowAccess;
13473
14489
  // Workflows API
13474
14490
  getWorkflows;
13475
14491
  getWorkflow;
@@ -13490,7 +14506,6 @@ var GravityRailClient = class {
13490
14506
  createWorkflowFromTemplate;
13491
14507
  getWorkflowTaskAssignmentStats;
13492
14508
  getTaskChats;
13493
- getWorkflowAccessValidation;
13494
14509
  getWorkflowConfigValidation;
13495
14510
  getWorkflowNotes;
13496
14511
  createWorkflowNote;
@@ -13602,6 +14617,7 @@ var GravityRailClient = class {
13602
14617
  previewTemplate;
13603
14618
  getVariableRegistry;
13604
14619
  getChatModels;
14620
+ getManagerModels;
13605
14621
  getRealtimeModels;
13606
14622
  getSTTModels;
13607
14623
  getTTSModels;
@@ -13714,6 +14730,7 @@ var GravityRailClient = class {
13714
14730
  getMondayConnectionBoardColumns;
13715
14731
  getMondayConnectionBoardGroups;
13716
14732
  getMondaySyncConfig;
14733
+ getMondaySyncLogs;
13717
14734
  updateMondaySyncConfig;
13718
14735
  getLinkedMondayMembers;
13719
14736
  getMondayReconciliationMatches;
@@ -13835,10 +14852,12 @@ var GravityRailClient = class {
13835
14852
  deleteSalesforce;
13836
14853
  getSalesforceReconciliationMatches;
13837
14854
  linkMemberToSalesforce;
14855
+ linkUnlinkedSalesforceMembersByIdentity;
13838
14856
  bulkLinkMembersToSalesforce;
13839
14857
  unlinkMemberFromSalesforce;
13840
14858
  getLinkedSalesforceMembers;
13841
14859
  getSalesforceSyncConfig;
14860
+ getSalesforceSyncLogs;
13842
14861
  updateSalesforceSyncConfig;
13843
14862
  resyncSalesforceLinkedMembers;
13844
14863
  listSalesforceObjects;
@@ -13935,6 +14954,14 @@ var GravityRailClient = class {
13935
14954
  closeWorkspaceSupportRequest;
13936
14955
  reopenWorkspaceSupportRequest;
13937
14956
  clickWorkspaceSupportRequestResource;
14957
+ // Routing Rules API
14958
+ getRoutingRules;
14959
+ getRoutingRule;
14960
+ createRoutingRule;
14961
+ updateRoutingRule;
14962
+ deleteRoutingRule;
14963
+ reorderRoutingRules;
14964
+ previewRoutingRule;
13938
14965
  constructor(apiKey, baseUrl, customFetch) {
13939
14966
  const apis = createApiModules(apiKey, baseUrl, customFetch);
13940
14967
  this.apis = apis;
@@ -13956,6 +14983,8 @@ var GravityRailClient = class {
13956
14983
  bindMotdMethods(this, apis.motd);
13957
14984
  bindTrackedLinksMethods(this, apis.trackedLinks);
13958
14985
  bindJourneysMethods(this, apis.journeys);
14986
+ bindBundlesMethods(this, apis.bundles, apis.resourceWorkflows);
14987
+ bindInstallationsMethods(this, apis.installations);
13959
14988
  bindExperimentsMethods(this, apis.experiments);
13960
14989
  bindOperatorMethods(this, apis.operatorGroups);
13961
14990
  bindOrgMethods(this, apis.org);
@@ -14009,6 +15038,7 @@ var GravityRailClient = class {
14009
15038
  bindCustomersMethods(this, apis.customers);
14010
15039
  bindResellersMethods(this, apis.resellers);
14011
15040
  bindSupportRequestMethods(this, apis.supportRequests);
15041
+ bindRoutingRulesMethods(this, apis.routingRules);
14012
15042
  }
14013
15043
  /**
14014
15044
  * Return a workspace-scoped client facade.
@@ -14086,32 +15116,6 @@ var GravityRailClient = class {
14086
15116
  }
14087
15117
  });
14088
15118
  }
14089
- /**
14090
- * Set the acting member UUID for member identity switching.
14091
- * When set, all API requests will include the X-Acting-Member header.
14092
- * The backend will validate that the authenticated account owns this member
14093
- * and use it as the effective identity for the request.
14094
- * Propagates to all API modules.
14095
- */
14096
- setActingMember(memberUuid) {
14097
- Object.values(this.apis).forEach((api) => {
14098
- if (typeof api.setActingMember === "function") {
14099
- api.setActingMember(memberUuid);
14100
- }
14101
- });
14102
- }
14103
- /**
14104
- * Get the current acting member UUID.
14105
- * Returns undefined if no member switch is active.
14106
- */
14107
- getActingMember() {
14108
- for (const api of Object.values(this.apis)) {
14109
- if (typeof api.getActingMember === "function") {
14110
- return api.getActingMember();
14111
- }
14112
- }
14113
- return void 0;
14114
- }
14115
15119
  };
14116
15120
 
14117
15121
  // src/types/ability-types.ts
@@ -14131,9 +15135,11 @@ var AbilityTypeSlugs = {
14131
15135
  GOOGLE_DRIVE: "integration:google_drive",
14132
15136
  GOOGLE_SHEETS: "integration:google_sheets",
14133
15137
  CHARLESTON_PMD_PAGING: "integration:charleston_pmd_paging",
15138
+ COSAN_PATHWAYS_SCHEDULING: "integration:cosan_pathways_scheduling",
14134
15139
  // Communication
14135
15140
  PHONE_CALL_TOOLS: "communication:phone_call_tools",
14136
15141
  SEND_SMS: "communication:send_sms",
15142
+ SEND_EMAIL: "communication:send_email",
14137
15143
  SEND_WHATSAPP: "communication:send_whatsapp",
14138
15144
  MEMBER_ACCESS: "communication:member_access",
14139
15145
  AUDIO_PLAYBACK: "communication:audio_playback",
@@ -14148,6 +15154,8 @@ var AbilityTypeSlugs = {
14148
15154
  MANAGE_WORKSPACE: "delegation:manage_workspace",
14149
15155
  // Workflow
14150
15156
  WORKFLOW_RUN: "workflow:run",
15157
+ // Access
15158
+ MEMBER_ROLE_GATE: "access:member_role_gate",
14151
15159
  // Commerce
14152
15160
  RESELLER: "commerce:reseller",
14153
15161
  // System (auto-injected, hidden from users)
@@ -14351,12 +15359,6 @@ var AbilityConfigIssueSeverity = {
14351
15359
  warning: "warning",
14352
15360
  error: "error"
14353
15361
  };
14354
- var WorkflowAccessWarningResourceType = {
14355
- form: "form",
14356
- file: "file",
14357
- folder: "folder",
14358
- calendar: "calendar"
14359
- };
14360
15362
 
14361
15363
  // src/types/generated/workflow.ts
14362
15364
  var WorkflowRoutingMode = {
@@ -14381,12 +15383,21 @@ var ImportReadinessIssueCode = {
14381
15383
  phone_not_provisioned: "phone_not_provisioned",
14382
15384
  phone_missing_default_workflow: "phone_missing_default_workflow",
14383
15385
  inbox_missing_default_workflow: "inbox_missing_default_workflow",
14384
- workflow_missing_default_phone: "workflow_missing_default_phone"
15386
+ workflow_missing_default_phone: "workflow_missing_default_phone",
15387
+ workflow_missing_default_inbox: "workflow_missing_default_inbox",
15388
+ routine_webhook_handoff_unverified: "routine_webhook_handoff_unverified",
15389
+ app_connection_not_connected: "app_connection_not_connected",
15390
+ site_form_migration_pending: "site_form_migration_pending",
15391
+ site_form_binding_invalid: "site_form_binding_invalid",
15392
+ site_theme_setting_inherited: "site_theme_setting_inherited"
14385
15393
  };
14386
15394
  var ImportReadinessIssueResourceType = {
14387
15395
  phone: "phone",
14388
15396
  inbox: "inbox",
14389
- workflow: "workflow"
15397
+ workflow: "workflow",
15398
+ routine: "routine",
15399
+ app_connection: "app_connection",
15400
+ site: "site"
14390
15401
  };
14391
15402
  var ImportSkippedRuleResourceGroupResourceType = {
14392
15403
  phone: "phone",
@@ -14408,7 +15419,8 @@ var ImportSkippedRuleResponseParentKind = {
14408
15419
  var ImportSkippedRuleResponseReasonCode = {
14409
15420
  missing_binding: "missing_binding",
14410
15421
  invalid_event_rule_cel: "invalid_event_rule_cel",
14411
- unresolved_journey_scope: "unresolved_journey_scope"
15422
+ unresolved_journey_scope: "unresolved_journey_scope",
15423
+ missing_source_workflow: "missing_source_workflow"
14412
15424
  };
14413
15425
  var ImportSkippedRuleResponseStatus = {
14414
15426
  outstanding: "outstanding",
@@ -14540,14 +15552,14 @@ function isChatType(value) {
14540
15552
  }
14541
15553
 
14542
15554
  // src/constants/models.ts
14543
- var DEFAULT_CHAT_MODEL = "aws:bedrock:claude-4-5-haiku";
14544
- var DEFAULT_AGENT_CHAT_MODEL = "openai:chat:gpt-5.6-luna";
15555
+ var DEFAULT_CHAT_MODEL = "openai:chat:gpt-6-luna";
15556
+ var DEFAULT_AGENT_CHAT_MODEL = "openai:chat:gpt-6-luna";
14545
15557
  var DEFAULT_AGENT_REALTIME_MODEL = "xai:realtime:voice-agent-2";
14546
15558
  var DEFAULT_AGENT_REALTIME_MODEL_CONFIG = {
14547
15559
  ttsModel: "native",
14548
15560
  voiceModel: "xai:voice:cosmo"
14549
15561
  };
14550
- var DEFAULT_VOICE_INFERENCE_MODEL = "openai:chat:gpt-5.6-luna";
15562
+ var DEFAULT_VOICE_INFERENCE_MODEL = "openai:chat:gpt-6-luna";
14551
15563
  var DEFAULT_CUSTOM_VOICE_MODEL = "xai:voice:lux";
14552
15564
 
14553
15565
  // src/types/resource-metadata.ts
@@ -14679,6 +15691,14 @@ var ActivityWindowBasis = {
14679
15691
  absolute: "absolute",
14680
15692
  workspace_local: "workspace_local"
14681
15693
  };
15694
+ var FeedCursorRejection = {
15695
+ malformed: "malformed",
15696
+ signature: "signature",
15697
+ version: "version",
15698
+ expired: "expired",
15699
+ scope_mismatch: "scope_mismatch",
15700
+ query_mismatch: "query_mismatch"
15701
+ };
14682
15702
 
14683
15703
  // src/types/generated/family.ts
14684
15704
  var ActivityEventFamily = {
@@ -14727,6 +15747,7 @@ var ScopeCategory = /* @__PURE__ */ ((ScopeCategory2) => {
14727
15747
  ScopeCategory2["APPS"] = "apps";
14728
15748
  ScopeCategory2["LABELS"] = "labels";
14729
15749
  ScopeCategory2["ANALYTICS"] = "analytics";
15750
+ ScopeCategory2["ANONYMOUS_SUBMISSIONS"] = "anonymous_submissions";
14730
15751
  ScopeCategory2["OPERATOR"] = "operator";
14731
15752
  ScopeCategory2["EXPORT"] = "export";
14732
15753
  ScopeCategory2["ORG"] = "org";
@@ -15189,6 +16210,14 @@ var SCOPES = {
15189
16210
  description: "View analytics and reports"
15190
16211
  },
15191
16212
  // =========================================================================
16213
+ // ANONYMOUS FORM SUBMISSIONS (read-only: submissions are immutable)
16214
+ // =========================================================================
16215
+ "anonymous_submissions:read": {
16216
+ name: "anonymous_submissions:read",
16217
+ category: "anonymous_submissions" /* ANONYMOUS_SUBMISSIONS */,
16218
+ description: "View what anonymous visitors submitted on anonymous Forms"
16219
+ },
16220
+ // =========================================================================
15192
16221
  // EXPORT
15193
16222
  // =========================================================================
15194
16223
  "export:read": {
@@ -15380,6 +16409,9 @@ function getRevisionState(workflow, revision) {
15380
16409
 
15381
16410
  export {
15382
16411
  AbilitiesApi,
16412
+ ResourceWorkflowsApi,
16413
+ BundlesApi,
16414
+ InstallationsApi,
15383
16415
  AccessGrantsApi,
15384
16416
  AgentTasksApi,
15385
16417
  AgentsApi,
@@ -15424,6 +16456,10 @@ export {
15424
16456
  QueriesApi,
15425
16457
  QualificationsApi,
15426
16458
  ReportsApi,
16459
+ RoutingActionType,
16460
+ RoutingAudience,
16461
+ RoutingChannel,
16462
+ RoutingTimeWindow,
15427
16463
  SalesforceApi,
15428
16464
  ConnectionSyncApi,
15429
16465
  HubspotApi,
@@ -15453,15 +16489,17 @@ export {
15453
16489
  PERMISSION_DELETE,
15454
16490
  decodePermissions,
15455
16491
  encodePermissions,
15456
- WORKFLOW_IMPLICIT_USE_SCOPE,
15457
- roleImplicitWorkflowUseScope,
15458
- roleWorkflowAccess,
15459
- roleCanUseWorkflow,
15460
16492
  Scope,
15461
16493
  BulkMemberResultStatus,
15462
16494
  MemberImportMatchInfoMatchType,
15463
16495
  MemberImportPreviewRowAction,
15464
16496
  MergeMemberRolesRequestAccessStrategy,
16497
+ CreateMemberContactPointRequestContactType,
16498
+ CreateMemberContactPointRequestPurpose,
16499
+ CreateMemberContactPointRequestSharing,
16500
+ UpdateMemberContactPointRequestContactType,
16501
+ UpdateMemberContactPointRequestPurpose,
16502
+ UpdateMemberContactPointRequestSharing,
15465
16503
  MemberType,
15466
16504
  isMemberContactConflict,
15467
16505
  isAccountContactConflict,
@@ -15475,6 +16513,8 @@ export {
15475
16513
  EventRuleActionType,
15476
16514
  eventRuleActionParams,
15477
16515
  MASKED_SECRET_SENTINEL,
16516
+ SendingNextStep,
16517
+ SendingStopState,
15478
16518
  WorkspaceFeature,
15479
16519
  MemberFeature,
15480
16520
  OrgFeature,
@@ -15506,8 +16546,16 @@ export {
15506
16546
  FhirVendor,
15507
16547
  FhirConnectionState,
15508
16548
  FhirClientType,
16549
+ CrmActivityKind,
16550
+ RunHealthCategory,
15509
16551
  TestChatRunLane,
15510
16552
  TestChatRunOutcome,
16553
+ ScenarioHealthCaption,
16554
+ ScenarioHealthHeadline,
16555
+ ScenarioHealthSampleNote,
16556
+ ScenarioHealthState,
16557
+ RevisionHistorySegment,
16558
+ ScenarioRunBlocker,
15511
16559
  CriterionType,
15512
16560
  DriverMode,
15513
16561
  AccessGrantResourceType,
@@ -15528,6 +16576,9 @@ export {
15528
16576
  TERMINAL_TASK_STATES,
15529
16577
  WorkspaceInvitationsApi,
15530
16578
  WorkspacesApi,
16579
+ BundleGrantRequestGranteeType,
16580
+ FormBundleItemRecordScope,
16581
+ SolutionReleaseResponseSlug,
15531
16582
  formatAppContextAsMarkdown,
15532
16583
  createApiModules,
15533
16584
  createWorkspaceClient,
@@ -15562,6 +16613,8 @@ export {
15562
16613
  bindOperatorMethods,
15563
16614
  bindOrgMethods,
15564
16615
  bindPronunciationsMethods,
16616
+ bindBundlesMethods,
16617
+ bindInstallationsMethods,
15565
16618
  bindJourneysMethods,
15566
16619
  bindQualificationsMethods,
15567
16620
  bindPersonasMethods,
@@ -15571,6 +16624,7 @@ export {
15571
16624
  bindResellersMethods,
15572
16625
  bindPromptsMethods,
15573
16626
  bindSupportRequestMethods,
16627
+ bindRoutingRulesMethods,
15574
16628
  GravityRailClient,
15575
16629
  AbilityTypeSlugs,
15576
16630
  DEFAULT_THINKING_SPEECH_PHRASES,
@@ -15602,7 +16656,6 @@ export {
15602
16656
  MenuItemResponseItemType,
15603
16657
  AbilityConfigIssueCode,
15604
16658
  AbilityConfigIssueSeverity,
15605
- WorkflowAccessWarningResourceType,
15606
16659
  WorkflowRoutingMode,
15607
16660
  WIDGET_SLUGS,
15608
16661
  PromoCodeStatus,
@@ -15646,6 +16699,7 @@ export {
15646
16699
  ActivityGroupBy,
15647
16700
  ActivityOpenItemOrder,
15648
16701
  ActivityWindowBasis,
16702
+ FeedCursorRejection,
15649
16703
  ActivityEventFamily,
15650
16704
  ActivityOutcome,
15651
16705
  RefResolutionStatus,
@@ -15655,4 +16709,4 @@ export {
15655
16709
  SCOPE_PRESETS,
15656
16710
  getRevisionState
15657
16711
  };
15658
- //# sourceMappingURL=chunk-R6S5RXW5.js.map
16712
+ //# sourceMappingURL=chunk-ZTUOB4V2.js.map