@corti/sdk 0.9.1-rc → 0.10.0-rc

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 (127) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/agents/client/Client.d.ts +1 -1
  3. package/dist/cjs/api/resources/agents/client/Client.js +11 -1
  4. package/dist/cjs/api/resources/agents/client/requests/AgentsCreateAgent.d.ts +2 -0
  5. package/dist/cjs/api/resources/agents/types/AgentsCreateAgentAgentType.d.ts +12 -0
  6. package/dist/cjs/api/resources/agents/types/AgentsCreateAgentAgentType.js +11 -0
  7. package/dist/cjs/api/resources/agents/types/AgentsCreateAgentExpertsItem.d.ts +1 -1
  8. package/dist/cjs/api/resources/agents/types/index.d.ts +1 -0
  9. package/dist/cjs/api/resources/agents/types/index.js +1 -0
  10. package/dist/cjs/api/resources/auth/client/Client.js +1 -0
  11. package/dist/cjs/api/resources/documents/client/Client.d.ts +1 -1
  12. package/dist/cjs/api/resources/documents/client/Client.js +6 -1
  13. package/dist/cjs/api/resources/facts/client/Client.js +6 -0
  14. package/dist/cjs/api/resources/interactions/client/Client.js +5 -0
  15. package/dist/cjs/api/resources/recordings/client/Client.js +4 -0
  16. package/dist/cjs/api/resources/templates/client/Client.js +3 -0
  17. package/dist/cjs/api/resources/transcripts/client/Client.d.ts +15 -1
  18. package/dist/cjs/api/resources/transcripts/client/Client.js +76 -1
  19. package/dist/cjs/api/types/AgentsCreateExpertReference.d.ts +15 -0
  20. package/dist/cjs/api/types/AgentsCreateExpertReference.js +5 -0
  21. package/dist/cjs/api/types/AgentsCreateMcpServer.d.ts +2 -0
  22. package/dist/cjs/api/types/AgentsExpertReference.d.ts +5 -3
  23. package/dist/cjs/api/types/AgentsMcpServer.d.ts +2 -0
  24. package/dist/cjs/api/types/DocumentsContextWithFacts.d.ts +1 -1
  25. package/dist/cjs/api/types/DocumentsContextWithTranscript.d.ts +1 -1
  26. package/dist/cjs/api/types/DocumentsCreateRequestWithTemplate.d.ts +1 -1
  27. package/dist/cjs/api/types/DocumentsCreateRequestWithTemplateKey.d.ts +2 -2
  28. package/dist/cjs/api/types/ErrorResponse.d.ts +4 -5
  29. package/dist/cjs/api/types/TranscriptsResponse.d.ts +4 -0
  30. package/dist/cjs/api/types/TranscriptsStatusEnum.d.ts +12 -0
  31. package/dist/cjs/api/types/TranscriptsStatusEnum.js +11 -0
  32. package/dist/cjs/api/types/TranscriptsStatusResponse.d.ts +8 -0
  33. package/dist/cjs/api/types/TranscriptsStatusResponse.js +5 -0
  34. package/dist/cjs/api/types/index.d.ts +3 -0
  35. package/dist/cjs/api/types/index.js +3 -0
  36. package/dist/cjs/serialization/resources/agents/client/requests/AgentsCreateAgent.d.ts +2 -0
  37. package/dist/cjs/serialization/resources/agents/client/requests/AgentsCreateAgent.js +2 -0
  38. package/dist/cjs/serialization/resources/agents/types/AgentsCreateAgentAgentType.d.ts +10 -0
  39. package/dist/cjs/serialization/resources/agents/types/AgentsCreateAgentAgentType.js +41 -0
  40. package/dist/cjs/serialization/resources/agents/types/AgentsCreateAgentExpertsItem.d.ts +2 -2
  41. package/dist/cjs/serialization/resources/agents/types/AgentsCreateAgentExpertsItem.js +2 -2
  42. package/dist/cjs/serialization/resources/agents/types/index.d.ts +1 -0
  43. package/dist/cjs/serialization/resources/agents/types/index.js +1 -0
  44. package/dist/cjs/serialization/types/AgentsCreateExpertReference.d.ts +15 -0
  45. package/dist/cjs/serialization/types/AgentsCreateExpertReference.js +46 -0
  46. package/dist/cjs/serialization/types/AgentsCreateMcpServer.d.ts +1 -0
  47. package/dist/cjs/serialization/types/AgentsCreateMcpServer.js +1 -0
  48. package/dist/cjs/serialization/types/AgentsExpertReference.d.ts +3 -2
  49. package/dist/cjs/serialization/types/AgentsExpertReference.js +3 -2
  50. package/dist/cjs/serialization/types/AgentsMcpServer.d.ts +1 -0
  51. package/dist/cjs/serialization/types/AgentsMcpServer.js +1 -0
  52. package/dist/cjs/serialization/types/ErrorResponse.d.ts +4 -5
  53. package/dist/cjs/serialization/types/ErrorResponse.js +6 -5
  54. package/dist/cjs/serialization/types/TranscriptsResponse.d.ts +3 -0
  55. package/dist/cjs/serialization/types/TranscriptsResponse.js +3 -0
  56. package/dist/cjs/serialization/types/TranscriptsStatusEnum.d.ts +10 -0
  57. package/dist/cjs/serialization/types/TranscriptsStatusEnum.js +41 -0
  58. package/dist/cjs/serialization/types/TranscriptsStatusResponse.d.ts +13 -0
  59. package/dist/cjs/serialization/types/TranscriptsStatusResponse.js +44 -0
  60. package/dist/cjs/serialization/types/index.d.ts +3 -0
  61. package/dist/cjs/serialization/types/index.js +3 -0
  62. package/dist/cjs/version.d.ts +1 -1
  63. package/dist/cjs/version.js +1 -1
  64. package/dist/esm/Client.mjs +2 -2
  65. package/dist/esm/api/resources/agents/client/Client.d.mts +1 -1
  66. package/dist/esm/api/resources/agents/client/Client.mjs +11 -1
  67. package/dist/esm/api/resources/agents/client/requests/AgentsCreateAgent.d.mts +2 -0
  68. package/dist/esm/api/resources/agents/types/AgentsCreateAgentAgentType.d.mts +12 -0
  69. package/dist/esm/api/resources/agents/types/AgentsCreateAgentAgentType.mjs +8 -0
  70. package/dist/esm/api/resources/agents/types/AgentsCreateAgentExpertsItem.d.mts +1 -1
  71. package/dist/esm/api/resources/agents/types/index.d.mts +1 -0
  72. package/dist/esm/api/resources/agents/types/index.mjs +1 -0
  73. package/dist/esm/api/resources/auth/client/Client.mjs +1 -0
  74. package/dist/esm/api/resources/documents/client/Client.d.mts +1 -1
  75. package/dist/esm/api/resources/documents/client/Client.mjs +6 -1
  76. package/dist/esm/api/resources/facts/client/Client.mjs +6 -0
  77. package/dist/esm/api/resources/interactions/client/Client.mjs +5 -0
  78. package/dist/esm/api/resources/recordings/client/Client.mjs +4 -0
  79. package/dist/esm/api/resources/templates/client/Client.mjs +3 -0
  80. package/dist/esm/api/resources/transcripts/client/Client.d.mts +15 -1
  81. package/dist/esm/api/resources/transcripts/client/Client.mjs +76 -1
  82. package/dist/esm/api/types/AgentsCreateExpertReference.d.mts +15 -0
  83. package/dist/esm/api/types/AgentsCreateExpertReference.mjs +4 -0
  84. package/dist/esm/api/types/AgentsCreateMcpServer.d.mts +2 -0
  85. package/dist/esm/api/types/AgentsExpertReference.d.mts +5 -3
  86. package/dist/esm/api/types/AgentsMcpServer.d.mts +2 -0
  87. package/dist/esm/api/types/DocumentsContextWithFacts.d.mts +1 -1
  88. package/dist/esm/api/types/DocumentsContextWithTranscript.d.mts +1 -1
  89. package/dist/esm/api/types/DocumentsCreateRequestWithTemplate.d.mts +1 -1
  90. package/dist/esm/api/types/DocumentsCreateRequestWithTemplateKey.d.mts +2 -2
  91. package/dist/esm/api/types/ErrorResponse.d.mts +4 -5
  92. package/dist/esm/api/types/TranscriptsResponse.d.mts +4 -0
  93. package/dist/esm/api/types/TranscriptsStatusEnum.d.mts +12 -0
  94. package/dist/esm/api/types/TranscriptsStatusEnum.mjs +8 -0
  95. package/dist/esm/api/types/TranscriptsStatusResponse.d.mts +8 -0
  96. package/dist/esm/api/types/TranscriptsStatusResponse.mjs +4 -0
  97. package/dist/esm/api/types/index.d.mts +3 -0
  98. package/dist/esm/api/types/index.mjs +3 -0
  99. package/dist/esm/serialization/resources/agents/client/requests/AgentsCreateAgent.d.mts +2 -0
  100. package/dist/esm/serialization/resources/agents/client/requests/AgentsCreateAgent.mjs +2 -0
  101. package/dist/esm/serialization/resources/agents/types/AgentsCreateAgentAgentType.d.mts +10 -0
  102. package/dist/esm/serialization/resources/agents/types/AgentsCreateAgentAgentType.mjs +5 -0
  103. package/dist/esm/serialization/resources/agents/types/AgentsCreateAgentExpertsItem.d.mts +2 -2
  104. package/dist/esm/serialization/resources/agents/types/AgentsCreateAgentExpertsItem.mjs +2 -2
  105. package/dist/esm/serialization/resources/agents/types/index.d.mts +1 -0
  106. package/dist/esm/serialization/resources/agents/types/index.mjs +1 -0
  107. package/dist/esm/serialization/types/AgentsCreateExpertReference.d.mts +15 -0
  108. package/dist/esm/serialization/types/AgentsCreateExpertReference.mjs +10 -0
  109. package/dist/esm/serialization/types/AgentsCreateMcpServer.d.mts +1 -0
  110. package/dist/esm/serialization/types/AgentsCreateMcpServer.mjs +1 -0
  111. package/dist/esm/serialization/types/AgentsExpertReference.d.mts +3 -2
  112. package/dist/esm/serialization/types/AgentsExpertReference.mjs +3 -2
  113. package/dist/esm/serialization/types/AgentsMcpServer.d.mts +1 -0
  114. package/dist/esm/serialization/types/AgentsMcpServer.mjs +1 -0
  115. package/dist/esm/serialization/types/ErrorResponse.d.mts +4 -5
  116. package/dist/esm/serialization/types/ErrorResponse.mjs +6 -5
  117. package/dist/esm/serialization/types/TranscriptsResponse.d.mts +3 -0
  118. package/dist/esm/serialization/types/TranscriptsResponse.mjs +3 -0
  119. package/dist/esm/serialization/types/TranscriptsStatusEnum.d.mts +10 -0
  120. package/dist/esm/serialization/types/TranscriptsStatusEnum.mjs +5 -0
  121. package/dist/esm/serialization/types/TranscriptsStatusResponse.d.mts +13 -0
  122. package/dist/esm/serialization/types/TranscriptsStatusResponse.mjs +8 -0
  123. package/dist/esm/serialization/types/index.d.mts +3 -0
  124. package/dist/esm/serialization/types/index.mjs +3 -0
  125. package/dist/esm/version.d.mts +1 -1
  126. package/dist/esm/version.mjs +1 -1
  127. package/package.json +1 -1
@@ -64,8 +64,8 @@ class CortiClient {
64
64
  "Tenant-Name": _options === null || _options === void 0 ? void 0 : _options.tenantName,
65
65
  "X-Fern-Language": "JavaScript",
66
66
  "X-Fern-SDK-Name": "@corti/sdk",
67
- "X-Fern-SDK-Version": "0.9.1-rc",
68
- "User-Agent": "@corti/sdk/0.9.1-rc",
67
+ "X-Fern-SDK-Version": "0.10.0-rc",
68
+ "User-Agent": "@corti/sdk/0.10.0-rc",
69
69
  "X-Fern-Runtime": core.RUNTIME.type,
70
70
  "X-Fern-Runtime-Version": core.RUNTIME.version,
71
71
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -189,7 +189,7 @@ export declare class Agents {
189
189
  getContext(id: string, contextId: string, request?: Corti.AgentsGetContextRequest, requestOptions?: Agents.RequestOptions): core.HttpResponsePromise<Corti.AgentsContext>;
190
190
  private __getContext;
191
191
  /**
192
- * This endpoint retrieves the experts registry, which contains information about all available experts that can be referenced when creating agents through the AgentsExpertReference schema.
192
+ * This endpoint retrieves the experts registry, which contains information about all available experts that can be referenced when creating agents through the AgentsCreateExpertReference schema.
193
193
  *
194
194
  * @param {Corti.AgentsGetRegistryExpertsRequest} request
195
195
  * @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
@@ -105,6 +105,7 @@ class Agents {
105
105
  queryParameters: _queryParams,
106
106
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
107
107
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
108
+ withCredentials: true,
108
109
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
109
110
  });
110
111
  if (_response.ok) {
@@ -192,6 +193,7 @@ class Agents {
192
193
  }),
193
194
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
194
195
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
196
+ withCredentials: true,
195
197
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
196
198
  });
197
199
  if (_response.ok) {
@@ -265,6 +267,7 @@ class Agents {
265
267
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
266
268
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
267
269
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
270
+ withCredentials: true,
268
271
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
269
272
  });
270
273
  if (_response.ok) {
@@ -340,6 +343,7 @@ class Agents {
340
343
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
341
344
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
342
345
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
346
+ withCredentials: true,
343
347
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
344
348
  });
345
349
  if (_response.ok) {
@@ -418,6 +422,7 @@ class Agents {
418
422
  }),
419
423
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
420
424
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
425
+ withCredentials: true,
421
426
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
422
427
  });
423
428
  if (_response.ok) {
@@ -493,6 +498,7 @@ class Agents {
493
498
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
494
499
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
495
500
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
501
+ withCredentials: true,
496
502
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
497
503
  });
498
504
  if (_response.ok) {
@@ -585,6 +591,7 @@ class Agents {
585
591
  }),
586
592
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
587
593
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
594
+ withCredentials: true,
588
595
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
589
596
  });
590
597
  if (_response.ok) {
@@ -668,6 +675,7 @@ class Agents {
668
675
  queryParameters: _queryParams,
669
676
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
670
677
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
678
+ withCredentials: true,
671
679
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
672
680
  });
673
681
  if (_response.ok) {
@@ -754,6 +762,7 @@ class Agents {
754
762
  queryParameters: _queryParams,
755
763
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
756
764
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
765
+ withCredentials: true,
757
766
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
758
767
  });
759
768
  if (_response.ok) {
@@ -802,7 +811,7 @@ class Agents {
802
811
  });
803
812
  }
804
813
  /**
805
- * This endpoint retrieves the experts registry, which contains information about all available experts that can be referenced when creating agents through the AgentsExpertReference schema.
814
+ * This endpoint retrieves the experts registry, which contains information about all available experts that can be referenced when creating agents through the AgentsCreateExpertReference schema.
806
815
  *
807
816
  * @param {Corti.AgentsGetRegistryExpertsRequest} request
808
817
  * @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
@@ -840,6 +849,7 @@ class Agents {
840
849
  queryParameters: _queryParams,
841
850
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
842
851
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
852
+ withCredentials: true,
843
853
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
844
854
  });
845
855
  if (_response.ok) {
@@ -16,6 +16,8 @@ export interface AgentsCreateAgent {
16
16
  ephemeral?: boolean | null;
17
17
  /** The name of the agent. */
18
18
  name: string;
19
+ /** Optional type of agent. */
20
+ agentType?: Corti.AgentsCreateAgentAgentType;
19
21
  /** The system prompt that defines the overall agents behavior and expectations. This field is optional as there is a default system orchestrator. */
20
22
  systemPrompt?: string;
21
23
  /** A brief description of the agent's capabilities. */
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * Optional type of agent.
6
+ */
7
+ export type AgentsCreateAgentAgentType = "expert" | "orchestrator" | "interviewing-expert";
8
+ export declare const AgentsCreateAgentAgentType: {
9
+ readonly Expert: "expert";
10
+ readonly Orchestrator: "orchestrator";
11
+ readonly InterviewingExpert: "interviewing-expert";
12
+ };
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.AgentsCreateAgentAgentType = void 0;
7
+ exports.AgentsCreateAgentAgentType = {
8
+ Expert: "expert",
9
+ Orchestrator: "orchestrator",
10
+ InterviewingExpert: "interviewing-expert",
11
+ };
@@ -2,4 +2,4 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Corti from "../../../index.js";
5
- export type AgentsCreateAgentExpertsItem = Corti.AgentsCreateExpert | Corti.AgentsExpertReference;
5
+ export type AgentsCreateAgentExpertsItem = Corti.AgentsCreateExpert | Corti.AgentsCreateExpertReference;
@@ -1,2 +1,3 @@
1
+ export * from "./AgentsCreateAgentAgentType.js";
1
2
  export * from "./AgentsCreateAgentExpertsItem.js";
2
3
  export * from "./AgentsMessageSendResponse.js";
@@ -14,5 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./AgentsCreateAgentAgentType.js"), exports);
17
18
  __exportStar(require("./AgentsCreateAgentExpertsItem.js"), exports);
18
19
  __exportStar(require("./AgentsMessageSendResponse.js"), exports);
@@ -87,6 +87,7 @@ class Auth {
87
87
  })), { scope: "openid", grant_type: "client_credentials" }),
88
88
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
89
89
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
90
+ withCredentials: true,
90
91
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
91
92
  });
92
93
  if (_response.ok) {
@@ -48,7 +48,7 @@ export declare class Documents {
48
48
  list(id: Corti.Uuid, requestOptions?: Documents.RequestOptions): core.HttpResponsePromise<Corti.DocumentsListResponse>;
49
49
  private __list;
50
50
  /**
51
- * Generate Document.
51
+ * This endpoint offers different ways to generate a document. Find guides to document generation [here](/textgen/documents-standard).
52
52
  *
53
53
  * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
54
54
  * @param {Corti.DocumentsCreateRequest} request
@@ -84,6 +84,7 @@ class Documents {
84
84
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
85
85
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
86
86
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
87
+ withCredentials: true,
87
88
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
88
89
  });
89
90
  if (_response.ok) {
@@ -152,7 +153,7 @@ class Documents {
152
153
  });
153
154
  }
154
155
  /**
155
- * Generate Document.
156
+ * This endpoint offers different ways to generate a document. Find guides to document generation [here](/textgen/documents-standard).
156
157
  *
157
158
  * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
158
159
  * @param {Corti.DocumentsCreateRequest} request
@@ -197,6 +198,7 @@ class Documents {
197
198
  }),
198
199
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
199
200
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
201
+ withCredentials: true,
200
202
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
201
203
  });
202
204
  if (_response.ok) {
@@ -294,6 +296,7 @@ class Documents {
294
296
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
295
297
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
296
298
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
299
+ withCredentials: true,
297
300
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
298
301
  });
299
302
  if (_response.ok) {
@@ -389,6 +392,7 @@ class Documents {
389
392
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
390
393
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
391
394
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
395
+ withCredentials: true,
392
396
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
393
397
  });
394
398
  if (_response.ok) {
@@ -482,6 +486,7 @@ class Documents {
482
486
  }),
483
487
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
484
488
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
489
+ withCredentials: true,
485
490
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
486
491
  });
487
492
  if (_response.ok) {
@@ -80,6 +80,7 @@ class Facts {
80
80
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
81
81
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
82
82
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
83
+ withCredentials: true,
83
84
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
84
85
  });
85
86
  if (_response.ok) {
@@ -155,6 +156,7 @@ class Facts {
155
156
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
156
157
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
157
158
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
159
+ withCredentials: true,
158
160
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
159
161
  });
160
162
  if (_response.ok) {
@@ -242,6 +244,7 @@ class Facts {
242
244
  }),
243
245
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
244
246
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
247
+ withCredentials: true,
245
248
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
246
249
  });
247
250
  if (_response.ok) {
@@ -328,6 +331,7 @@ class Facts {
328
331
  }),
329
332
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
330
333
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
334
+ withCredentials: true,
331
335
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
332
336
  });
333
337
  if (_response.ok) {
@@ -411,6 +415,7 @@ class Facts {
411
415
  }),
412
416
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
413
417
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
418
+ withCredentials: true,
414
419
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
415
420
  });
416
421
  if (_response.ok) {
@@ -498,6 +503,7 @@ class Facts {
498
503
  }),
499
504
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
500
505
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
506
+ withCredentials: true,
501
507
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
502
508
  });
503
509
  if (_response.ok) {
@@ -115,6 +115,7 @@ class Interactions {
115
115
  queryParameters: _queryParams,
116
116
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
117
117
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
118
+ withCredentials: true,
118
119
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
119
120
  });
120
121
  if (_response.ok) {
@@ -226,6 +227,7 @@ class Interactions {
226
227
  }),
227
228
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
228
229
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
230
+ withCredentials: true,
229
231
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
230
232
  });
231
233
  if (_response.ok) {
@@ -320,6 +322,7 @@ class Interactions {
320
322
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
321
323
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
322
324
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
325
+ withCredentials: true,
323
326
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
324
327
  });
325
328
  if (_response.ok) {
@@ -404,6 +407,7 @@ class Interactions {
404
407
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
405
408
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
406
409
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
410
+ withCredentials: true,
407
411
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
408
412
  });
409
413
  if (_response.ok) {
@@ -486,6 +490,7 @@ class Interactions {
486
490
  }),
487
491
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
488
492
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
493
+ withCredentials: true,
489
494
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
490
495
  });
491
496
  if (_response.ok) {
@@ -84,6 +84,7 @@ class Recordings {
84
84
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
85
85
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
86
86
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
87
+ withCredentials: true,
87
88
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
88
89
  });
89
90
  if (_response.ok) {
@@ -183,6 +184,7 @@ class Recordings {
183
184
  body: _binaryUploadRequest.body,
184
185
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
185
186
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
187
+ withCredentials: true,
186
188
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
187
189
  });
188
190
  if (_response.ok) {
@@ -274,6 +276,7 @@ class Recordings {
274
276
  responseType: "binary-response",
275
277
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
276
278
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
279
+ withCredentials: true,
277
280
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
278
281
  });
279
282
  if (_response.ok) {
@@ -364,6 +367,7 @@ class Recordings {
364
367
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
365
368
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
366
369
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
370
+ withCredentials: true,
367
371
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
368
372
  });
369
373
  if (_response.ok) {
@@ -101,6 +101,7 @@ class Templates {
101
101
  queryParameters: _queryParams,
102
102
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
103
103
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
104
+ withCredentials: true,
104
105
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
105
106
  });
106
107
  if (_response.ok) {
@@ -206,6 +207,7 @@ class Templates {
206
207
  queryParameters: _queryParams,
207
208
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
208
209
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
210
+ withCredentials: true,
209
211
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
210
212
  });
211
213
  if (_response.ok) {
@@ -284,6 +286,7 @@ class Templates {
284
286
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
285
287
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
286
288
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
289
+ withCredentials: true,
287
290
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
288
291
  });
289
292
  if (_response.ok) {
@@ -50,7 +50,7 @@ export declare class Transcripts {
50
50
  list(id: Corti.Uuid, request?: Corti.TranscriptsListRequest, requestOptions?: Transcripts.RequestOptions): core.HttpResponsePromise<Corti.TranscriptsListResponse>;
51
51
  private __list;
52
52
  /**
53
- * Create a transcript from an audio file attached, via `/recordings` endpoint, to the interaction.<br/><Note>Each interaction may have more than one audio file and transcript associated with it. While audio files up to 60min in total duration, or 150MB in total size, may be attached to an interaction, synchronous processing is only supported for audio files less than ~2min in duration.<br/><br/>If an audio file takes longer to transcribe than the 25sec synchronous processing timeout, then it will continue to process asynchronously. In this scenario, an empty transcript will be returned with a location header that can be used to retrieve the final transcript.<br/><br/>The client can poll the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/status`) for transcript status changes:<br/>- `200 OK` with status `processing`, `completed`, or `failed`<br/>- `404 Not Found` if the `interactionId` or `transcriptId` are invalid<br/><br/>The completed transcript can be retrieved via the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/`).</Note>
53
+ * Create a transcript from an audio file attached, via `/recordings` endpoint, to the interaction.<br/><Note>Each interaction may have more than one audio file and transcript associated with it. While audio files up to 60min in total duration, or 150MB in total size, may be attached to an interaction, synchronous processing is only supported for audio files less than ~2min in duration.<br/><br/>If an audio file takes longer to transcribe than the 25sec synchronous processing timeout, then it will continue to process asynchronously. In this scenario, an incomplete or empty transcript with `status=processing` will be returned with a location header that can be used to retrieve the final transcript.<br/><br/>The client can poll the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/status`) for transcript status changes:<br/>- `200 OK` with status `processing`, `completed`, or `failed`<br/>- `404 Not Found` if the `interactionId` or `transcriptId` are invalid<br/><br/>The completed transcript can be retrieved via the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/`).</Note>
54
54
  *
55
55
  * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
56
56
  * @param {Corti.TranscriptsCreateRequest} request
@@ -106,5 +106,19 @@ export declare class Transcripts {
106
106
  */
107
107
  delete(id: Corti.Uuid, transcriptId: Corti.Uuid, requestOptions?: Transcripts.RequestOptions): core.HttpResponsePromise<void>;
108
108
  private __delete;
109
+ /**
110
+ * Poll for transcript creation status.<br/><Note>Status of `completed` indicates the transcript is finalized.<br/>If the transcript is retrieved while status is `processing`, then it will be incomplete.<br/>Status of `failed` indicate the transcript was not created successfully; please retry.</Note>
111
+ *
112
+ * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
113
+ * @param {Corti.Uuid} transcriptId - The unique identifier of the transcript. Must be a valid UUID.
114
+ * @param {Transcripts.RequestOptions} requestOptions - Request-specific configuration.
115
+ *
116
+ * @throws {@link Corti.NotFoundError}
117
+ *
118
+ * @example
119
+ * await client.transcripts.getStatus("f47ac10b-58cc-4372-a567-0e02b2c3d479", "f47ac10b-58cc-4372-a567-0e02b2c3d479")
120
+ */
121
+ getStatus(id: Corti.Uuid, transcriptId: Corti.Uuid, requestOptions?: Transcripts.RequestOptions): core.HttpResponsePromise<Corti.TranscriptsStatusResponse>;
122
+ private __getStatus;
109
123
  protected _getAuthorizationHeader(): Promise<string | undefined>;
110
124
  }
@@ -92,6 +92,7 @@ class Transcripts {
92
92
  queryParameters: _queryParams,
93
93
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
94
94
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
95
+ withCredentials: true,
95
96
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
96
97
  });
97
98
  if (_response.ok) {
@@ -162,7 +163,7 @@ class Transcripts {
162
163
  });
163
164
  }
164
165
  /**
165
- * Create a transcript from an audio file attached, via `/recordings` endpoint, to the interaction.<br/><Note>Each interaction may have more than one audio file and transcript associated with it. While audio files up to 60min in total duration, or 150MB in total size, may be attached to an interaction, synchronous processing is only supported for audio files less than ~2min in duration.<br/><br/>If an audio file takes longer to transcribe than the 25sec synchronous processing timeout, then it will continue to process asynchronously. In this scenario, an empty transcript will be returned with a location header that can be used to retrieve the final transcript.<br/><br/>The client can poll the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/status`) for transcript status changes:<br/>- `200 OK` with status `processing`, `completed`, or `failed`<br/>- `404 Not Found` if the `interactionId` or `transcriptId` are invalid<br/><br/>The completed transcript can be retrieved via the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/`).</Note>
166
+ * Create a transcript from an audio file attached, via `/recordings` endpoint, to the interaction.<br/><Note>Each interaction may have more than one audio file and transcript associated with it. While audio files up to 60min in total duration, or 150MB in total size, may be attached to an interaction, synchronous processing is only supported for audio files less than ~2min in duration.<br/><br/>If an audio file takes longer to transcribe than the 25sec synchronous processing timeout, then it will continue to process asynchronously. In this scenario, an incomplete or empty transcript with `status=processing` will be returned with a location header that can be used to retrieve the final transcript.<br/><br/>The client can poll the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/status`) for transcript status changes:<br/>- `200 OK` with status `processing`, `completed`, or `failed`<br/>- `404 Not Found` if the `interactionId` or `transcriptId` are invalid<br/><br/>The completed transcript can be retrieved via the Get Transcript endpoint (`GET /interactions/{id}/transcripts/{transcriptId}/`).</Note>
166
167
  *
167
168
  * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
168
169
  * @param {Corti.TranscriptsCreateRequest} request
@@ -201,6 +202,7 @@ class Transcripts {
201
202
  }),
202
203
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
203
204
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
205
+ withCredentials: true,
204
206
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
205
207
  });
206
208
  if (_response.ok) {
@@ -301,6 +303,7 @@ class Transcripts {
301
303
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
302
304
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
303
305
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
306
+ withCredentials: true,
304
307
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
305
308
  });
306
309
  if (_response.ok) {
@@ -401,6 +404,7 @@ class Transcripts {
401
404
  }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
402
405
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
403
406
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
407
+ withCredentials: true,
404
408
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
405
409
  });
406
410
  if (_response.ok) {
@@ -461,6 +465,77 @@ class Transcripts {
461
465
  }
462
466
  });
463
467
  }
468
+ /**
469
+ * Poll for transcript creation status.<br/><Note>Status of `completed` indicates the transcript is finalized.<br/>If the transcript is retrieved while status is `processing`, then it will be incomplete.<br/>Status of `failed` indicate the transcript was not created successfully; please retry.</Note>
470
+ *
471
+ * @param {Corti.Uuid} id - The unique identifier of the interaction. Must be a valid UUID.
472
+ * @param {Corti.Uuid} transcriptId - The unique identifier of the transcript. Must be a valid UUID.
473
+ * @param {Transcripts.RequestOptions} requestOptions - Request-specific configuration.
474
+ *
475
+ * @throws {@link Corti.NotFoundError}
476
+ *
477
+ * @example
478
+ * await client.transcripts.getStatus("f47ac10b-58cc-4372-a567-0e02b2c3d479", "f47ac10b-58cc-4372-a567-0e02b2c3d479")
479
+ */
480
+ getStatus(id, transcriptId, requestOptions) {
481
+ return core.HttpResponsePromise.fromPromise(this.__getStatus(id, transcriptId, requestOptions));
482
+ }
483
+ __getStatus(id, transcriptId, requestOptions) {
484
+ return __awaiter(this, void 0, void 0, function* () {
485
+ var _a, _b;
486
+ const _response = yield core.fetcher({
487
+ url: core.url.join((_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : (yield core.Supplier.get(this._options.environment)).base, `interactions/${encodeURIComponent(serializers.Uuid.jsonOrThrow(id, { omitUndefined: true }))}/transcripts/${encodeURIComponent(serializers.Uuid.jsonOrThrow(transcriptId, { omitUndefined: true }))}/status`),
488
+ method: "GET",
489
+ headers: (0, headers_js_1.mergeHeaders)((_b = this._options) === null || _b === void 0 ? void 0 : _b.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
490
+ Authorization: yield this._getAuthorizationHeader(),
491
+ "Tenant-Name": requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.tenantName,
492
+ }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
493
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
494
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
495
+ withCredentials: true,
496
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
497
+ });
498
+ if (_response.ok) {
499
+ return {
500
+ data: serializers.TranscriptsStatusResponse.parseOrThrow(_response.body, {
501
+ unrecognizedObjectKeys: "passthrough",
502
+ allowUnrecognizedUnionMembers: true,
503
+ allowUnrecognizedEnumValues: true,
504
+ skipValidation: true,
505
+ breadcrumbsPrefix: ["response"],
506
+ }),
507
+ rawResponse: _response.rawResponse,
508
+ };
509
+ }
510
+ if (_response.error.reason === "status-code") {
511
+ switch (_response.error.statusCode) {
512
+ case 404:
513
+ throw new Corti.NotFoundError(_response.error.body, _response.rawResponse);
514
+ default:
515
+ throw new errors.CortiError({
516
+ statusCode: _response.error.statusCode,
517
+ body: _response.error.body,
518
+ rawResponse: _response.rawResponse,
519
+ });
520
+ }
521
+ }
522
+ switch (_response.error.reason) {
523
+ case "non-json":
524
+ throw new errors.CortiError({
525
+ statusCode: _response.error.statusCode,
526
+ body: _response.error.rawBody,
527
+ rawResponse: _response.rawResponse,
528
+ });
529
+ case "timeout":
530
+ throw new errors.CortiTimeoutError("Timeout exceeded when calling GET /interactions/{id}/transcripts/{transcriptId}/status.");
531
+ case "unknown":
532
+ throw new errors.CortiError({
533
+ message: _response.error.errorMessage,
534
+ rawResponse: _response.rawResponse,
535
+ });
536
+ }
537
+ });
538
+ }
464
539
  _getAuthorizationHeader() {
465
540
  return __awaiter(this, void 0, void 0, function* () {
466
541
  const bearer = yield core.Supplier.get(this._options.token);
@@ -0,0 +1,15 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * A reference to a registry expert when creating an agent, either id or name must be provided. If both are passed, the id will be used.
6
+ */
7
+ export interface AgentsCreateExpertReference {
8
+ type: "reference";
9
+ /** The unique identifier of the expert. */
10
+ id?: string;
11
+ /** The name of the expert. */
12
+ name?: string;
13
+ /** Optional. Additional system instructions appended to the default system prompt when creating an expert from the registry, extending the expert's behavior. */
14
+ systemPrompt?: string;
15
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -11,6 +11,8 @@ export interface AgentsCreateMcpServer {
11
11
  transportType: Corti.AgentsCreateMcpServerTransportType;
12
12
  /** Type of authorization used by the MCP server. */
13
13
  authorizationType: Corti.AgentsCreateMcpServerAuthorizationType;
14
+ /** OAuth2.0 authorization scope to request. */
15
+ authorizationScope?: string;
14
16
  /** URL of the MCP server. */
15
17
  url: string;
16
18
  /** Redirect URI for OAuth2.0 authorization. */
@@ -2,12 +2,14 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  /**
5
- * A reference to an expert, either id or name must be provided. If both are passed, the id will be used.
5
+ * A reference to an expert returned by the API. The expert's id and name are always provided. systemPrompt is included only when a registry expert was created with a custom system prompt.
6
6
  */
7
7
  export interface AgentsExpertReference {
8
8
  type: "reference";
9
9
  /** The unique identifier of the expert. */
10
- id?: string;
10
+ id: string;
11
11
  /** The name of the expert. */
12
- name?: string;
12
+ name: string;
13
+ /** Optional. Additional system instructions appended to the default system prompt when creating an expert from the registry, extending the expert's behavior. */
14
+ systemPrompt?: string;
13
15
  }
@@ -11,6 +11,8 @@ export interface AgentsMcpServer {
11
11
  transportType: Corti.AgentsMcpServerTransportType;
12
12
  /** Type of authorization used by the MCP server. */
13
13
  authorizationType: Corti.AgentsMcpServerAuthorizationType;
14
+ /** OAuth2.0 authorization scope to request. */
15
+ authorizationScope?: string;
14
16
  /** URL of the MCP server. */
15
17
  url: string;
16
18
  /** Redirect URI for OAuth2.0 authorization. */
@@ -5,6 +5,6 @@ import * as Corti from "../index.js";
5
5
  export interface DocumentsContextWithFacts {
6
6
  /** The type of context data that will be used in the request: `Facts`, `Transcript`, or `String`. */
7
7
  type: "facts";
8
- /** An array of facts. */
8
+ /** An array of facts. See [guide](/textgen/documents-standard##generate-document-from-facts-as-input). */
9
9
  data: Corti.FactsContext[];
10
10
  }
@@ -5,6 +5,6 @@ import * as Corti from "../index.js";
5
5
  export interface DocumentsContextWithTranscript {
6
6
  /** The type of context data that will be used in the request: `Facts`, `Transcript`, or `String`. */
7
7
  type: "transcript";
8
- /** Transcript object can accept the full transcript in one string, or individual transcript segments. */
8
+ /** The transcript `data.text` object can accept the full transcript in one string, alternatively pass each transcript segment into a `context` object - [see guide](/textgen/documents-standard#generate-document-from-transcript-as-input). */
9
9
  data: Corti.CommonTranscriptRequest;
10
10
  }
@@ -3,7 +3,7 @@
3
3
  */
4
4
  import * as Corti from "../index.js";
5
5
  export interface DocumentsCreateRequestWithTemplate {
6
- /** An array of context objects. Currently accepts exactly one context object to be used as input for document generation. */
6
+ /** An array of context objects. Currently only accepts multiple objects when of type `transcript`. See [guide](/textgen/documents-standard#generate-document-from-transcript-as-input). */
7
7
  context: Corti.DocumentsContext[];
8
8
  /** Template details if the template should be generated during the request. */
9
9
  template: Corti.DocumentsTemplate;