vellum-ai 0.8.23 → 0.8.25

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 (199) hide show
  1. package/.mock/definition/__package__.yml +141 -0
  2. package/.mock/definition/folderEntities.yml +91 -2
  3. package/.mock/openapi/openapi.yml +300 -2
  4. package/Client.d.ts +3 -3
  5. package/Client.js +11 -11
  6. package/api/resources/adHoc/client/Client.d.ts +3 -3
  7. package/api/resources/adHoc/client/Client.js +2 -2
  8. package/api/resources/deployments/client/Client.d.ts +3 -3
  9. package/api/resources/deployments/client/Client.js +6 -6
  10. package/api/resources/documentIndexes/client/Client.d.ts +3 -3
  11. package/api/resources/documentIndexes/client/Client.js +9 -9
  12. package/api/resources/documents/client/Client.d.ts +3 -3
  13. package/api/resources/documents/client/Client.js +6 -6
  14. package/api/resources/folderEntities/client/Client.d.ts +22 -4
  15. package/api/resources/folderEntities/client/Client.js +80 -4
  16. package/api/resources/folderEntities/client/requests/FolderEntitiesListRequest.d.ts +43 -0
  17. package/api/resources/folderEntities/client/requests/FolderEntitiesListRequest.js +5 -0
  18. package/api/resources/folderEntities/client/requests/index.d.ts +1 -0
  19. package/api/resources/folderEntities/index.d.ts +1 -0
  20. package/api/resources/folderEntities/index.js +1 -0
  21. package/api/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.d.ts +8 -0
  22. package/api/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.js +10 -0
  23. package/api/resources/folderEntities/types/index.d.ts +1 -0
  24. package/api/resources/folderEntities/types/index.js +17 -0
  25. package/api/resources/index.d.ts +2 -1
  26. package/api/resources/index.js +3 -2
  27. package/api/resources/metricDefinitions/client/Client.d.ts +3 -3
  28. package/api/resources/metricDefinitions/client/Client.js +2 -2
  29. package/api/resources/sandboxes/client/Client.d.ts +3 -3
  30. package/api/resources/sandboxes/client/Client.js +4 -4
  31. package/api/resources/testSuiteRuns/client/Client.d.ts +3 -3
  32. package/api/resources/testSuiteRuns/client/Client.js +4 -4
  33. package/api/resources/testSuites/client/Client.d.ts +3 -3
  34. package/api/resources/testSuites/client/Client.js +5 -5
  35. package/api/resources/workflowDeployments/client/Client.d.ts +3 -3
  36. package/api/resources/workflowDeployments/client/Client.js +5 -5
  37. package/api/resources/workflowSandboxes/client/Client.d.ts +3 -3
  38. package/api/resources/workflowSandboxes/client/Client.js +2 -2
  39. package/api/types/FolderEntity.d.ts +5 -0
  40. package/api/types/FolderEntity.js +5 -0
  41. package/api/types/FolderEntityDocumentIndex.d.ts +12 -0
  42. package/api/types/FolderEntityDocumentIndex.js +5 -0
  43. package/api/types/FolderEntityDocumentIndexData.d.ts +11 -0
  44. package/api/types/FolderEntityDocumentIndexData.js +5 -0
  45. package/api/types/FolderEntityFolder.d.ts +12 -0
  46. package/api/types/FolderEntityFolder.js +5 -0
  47. package/api/types/FolderEntityFolderData.d.ts +10 -0
  48. package/api/types/FolderEntityFolderData.js +5 -0
  49. package/api/types/FolderEntityPromptSandbox.d.ts +12 -0
  50. package/api/types/FolderEntityPromptSandbox.js +5 -0
  51. package/api/types/FolderEntityPromptSandboxData.d.ts +12 -0
  52. package/api/types/FolderEntityPromptSandboxData.js +5 -0
  53. package/api/types/FolderEntityTestSuite.d.ts +12 -0
  54. package/api/types/FolderEntityTestSuite.js +5 -0
  55. package/api/types/FolderEntityTestSuiteData.d.ts +11 -0
  56. package/api/types/FolderEntityTestSuiteData.js +5 -0
  57. package/api/types/FolderEntityWorkflowSandbox.d.ts +12 -0
  58. package/api/types/FolderEntityWorkflowSandbox.js +5 -0
  59. package/api/types/FolderEntityWorkflowSandboxData.d.ts +12 -0
  60. package/api/types/FolderEntityWorkflowSandboxData.js +5 -0
  61. package/api/types/PaginatedFolderEntityList.d.ts +10 -0
  62. package/api/types/PaginatedFolderEntityList.js +5 -0
  63. package/api/types/index.d.ts +12 -0
  64. package/api/types/index.js +12 -0
  65. package/dist/Client.d.ts +3 -3
  66. package/dist/Client.js +11 -11
  67. package/dist/api/resources/adHoc/client/Client.d.ts +3 -3
  68. package/dist/api/resources/adHoc/client/Client.js +2 -2
  69. package/dist/api/resources/deployments/client/Client.d.ts +3 -3
  70. package/dist/api/resources/deployments/client/Client.js +6 -6
  71. package/dist/api/resources/documentIndexes/client/Client.d.ts +3 -3
  72. package/dist/api/resources/documentIndexes/client/Client.js +9 -9
  73. package/dist/api/resources/documents/client/Client.d.ts +3 -3
  74. package/dist/api/resources/documents/client/Client.js +6 -6
  75. package/dist/api/resources/folderEntities/client/Client.d.ts +22 -4
  76. package/dist/api/resources/folderEntities/client/Client.js +80 -4
  77. package/dist/api/resources/folderEntities/client/requests/FolderEntitiesListRequest.d.ts +43 -0
  78. package/dist/api/resources/folderEntities/client/requests/FolderEntitiesListRequest.js +5 -0
  79. package/dist/api/resources/folderEntities/client/requests/index.d.ts +1 -0
  80. package/dist/api/resources/folderEntities/index.d.ts +1 -0
  81. package/dist/api/resources/folderEntities/index.js +1 -0
  82. package/dist/api/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.d.ts +8 -0
  83. package/dist/api/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.js +10 -0
  84. package/dist/api/resources/folderEntities/types/index.d.ts +1 -0
  85. package/dist/api/resources/folderEntities/types/index.js +17 -0
  86. package/dist/api/resources/index.d.ts +2 -1
  87. package/dist/api/resources/index.js +3 -2
  88. package/dist/api/resources/metricDefinitions/client/Client.d.ts +3 -3
  89. package/dist/api/resources/metricDefinitions/client/Client.js +2 -2
  90. package/dist/api/resources/sandboxes/client/Client.d.ts +3 -3
  91. package/dist/api/resources/sandboxes/client/Client.js +4 -4
  92. package/dist/api/resources/testSuiteRuns/client/Client.d.ts +3 -3
  93. package/dist/api/resources/testSuiteRuns/client/Client.js +4 -4
  94. package/dist/api/resources/testSuites/client/Client.d.ts +3 -3
  95. package/dist/api/resources/testSuites/client/Client.js +5 -5
  96. package/dist/api/resources/workflowDeployments/client/Client.d.ts +3 -3
  97. package/dist/api/resources/workflowDeployments/client/Client.js +5 -5
  98. package/dist/api/resources/workflowSandboxes/client/Client.d.ts +3 -3
  99. package/dist/api/resources/workflowSandboxes/client/Client.js +2 -2
  100. package/dist/api/types/FolderEntity.d.ts +5 -0
  101. package/dist/api/types/FolderEntity.js +5 -0
  102. package/dist/api/types/FolderEntityDocumentIndex.d.ts +12 -0
  103. package/dist/api/types/FolderEntityDocumentIndex.js +5 -0
  104. package/dist/api/types/FolderEntityDocumentIndexData.d.ts +11 -0
  105. package/dist/api/types/FolderEntityDocumentIndexData.js +5 -0
  106. package/dist/api/types/FolderEntityFolder.d.ts +12 -0
  107. package/dist/api/types/FolderEntityFolder.js +5 -0
  108. package/dist/api/types/FolderEntityFolderData.d.ts +10 -0
  109. package/dist/api/types/FolderEntityFolderData.js +5 -0
  110. package/dist/api/types/FolderEntityPromptSandbox.d.ts +12 -0
  111. package/dist/api/types/FolderEntityPromptSandbox.js +5 -0
  112. package/dist/api/types/FolderEntityPromptSandboxData.d.ts +12 -0
  113. package/dist/api/types/FolderEntityPromptSandboxData.js +5 -0
  114. package/dist/api/types/FolderEntityTestSuite.d.ts +12 -0
  115. package/dist/api/types/FolderEntityTestSuite.js +5 -0
  116. package/dist/api/types/FolderEntityTestSuiteData.d.ts +11 -0
  117. package/dist/api/types/FolderEntityTestSuiteData.js +5 -0
  118. package/dist/api/types/FolderEntityWorkflowSandbox.d.ts +12 -0
  119. package/dist/api/types/FolderEntityWorkflowSandbox.js +5 -0
  120. package/dist/api/types/FolderEntityWorkflowSandboxData.d.ts +12 -0
  121. package/dist/api/types/FolderEntityWorkflowSandboxData.js +5 -0
  122. package/dist/api/types/PaginatedFolderEntityList.d.ts +10 -0
  123. package/dist/api/types/PaginatedFolderEntityList.js +5 -0
  124. package/dist/api/types/index.d.ts +12 -0
  125. package/dist/api/types/index.js +12 -0
  126. package/dist/serialization/resources/folderEntities/index.d.ts +1 -0
  127. package/dist/serialization/resources/folderEntities/index.js +1 -0
  128. package/dist/serialization/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.d.ts +10 -0
  129. package/dist/serialization/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.js +31 -0
  130. package/dist/serialization/resources/folderEntities/types/index.d.ts +1 -0
  131. package/dist/serialization/resources/folderEntities/types/index.js +17 -0
  132. package/dist/serialization/resources/index.d.ts +2 -1
  133. package/dist/serialization/resources/index.js +3 -2
  134. package/dist/serialization/types/FolderEntity.d.ts +15 -0
  135. package/dist/serialization/types/FolderEntity.js +42 -0
  136. package/dist/serialization/types/FolderEntityDocumentIndex.d.ts +15 -0
  137. package/dist/serialization/types/FolderEntityDocumentIndex.js +36 -0
  138. package/dist/serialization/types/FolderEntityDocumentIndexData.d.ts +17 -0
  139. package/dist/serialization/types/FolderEntityDocumentIndexData.js +38 -0
  140. package/dist/serialization/types/FolderEntityFolder.d.ts +15 -0
  141. package/dist/serialization/types/FolderEntityFolder.js +36 -0
  142. package/dist/serialization/types/FolderEntityFolderData.d.ts +16 -0
  143. package/dist/serialization/types/FolderEntityFolderData.js +37 -0
  144. package/dist/serialization/types/FolderEntityPromptSandbox.d.ts +15 -0
  145. package/dist/serialization/types/FolderEntityPromptSandbox.js +36 -0
  146. package/dist/serialization/types/FolderEntityPromptSandboxData.d.ts +18 -0
  147. package/dist/serialization/types/FolderEntityPromptSandboxData.js +39 -0
  148. package/dist/serialization/types/FolderEntityTestSuite.d.ts +15 -0
  149. package/dist/serialization/types/FolderEntityTestSuite.js +36 -0
  150. package/dist/serialization/types/FolderEntityTestSuiteData.d.ts +17 -0
  151. package/dist/serialization/types/FolderEntityTestSuiteData.js +38 -0
  152. package/dist/serialization/types/FolderEntityWorkflowSandbox.d.ts +15 -0
  153. package/dist/serialization/types/FolderEntityWorkflowSandbox.js +36 -0
  154. package/dist/serialization/types/FolderEntityWorkflowSandboxData.d.ts +18 -0
  155. package/dist/serialization/types/FolderEntityWorkflowSandboxData.js +39 -0
  156. package/dist/serialization/types/PaginatedFolderEntityList.d.ts +16 -0
  157. package/dist/serialization/types/PaginatedFolderEntityList.js +37 -0
  158. package/dist/serialization/types/index.d.ts +12 -0
  159. package/dist/serialization/types/index.js +12 -0
  160. package/dist/version.d.ts +1 -1
  161. package/dist/version.js +1 -1
  162. package/package.json +1 -1
  163. package/reference.md +74 -1
  164. package/serialization/resources/folderEntities/index.d.ts +1 -0
  165. package/serialization/resources/folderEntities/index.js +1 -0
  166. package/serialization/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.d.ts +10 -0
  167. package/serialization/resources/folderEntities/types/FolderEntitiesListRequestEntityStatus.js +31 -0
  168. package/serialization/resources/folderEntities/types/index.d.ts +1 -0
  169. package/serialization/resources/folderEntities/types/index.js +17 -0
  170. package/serialization/resources/index.d.ts +2 -1
  171. package/serialization/resources/index.js +3 -2
  172. package/serialization/types/FolderEntity.d.ts +15 -0
  173. package/serialization/types/FolderEntity.js +42 -0
  174. package/serialization/types/FolderEntityDocumentIndex.d.ts +15 -0
  175. package/serialization/types/FolderEntityDocumentIndex.js +36 -0
  176. package/serialization/types/FolderEntityDocumentIndexData.d.ts +17 -0
  177. package/serialization/types/FolderEntityDocumentIndexData.js +38 -0
  178. package/serialization/types/FolderEntityFolder.d.ts +15 -0
  179. package/serialization/types/FolderEntityFolder.js +36 -0
  180. package/serialization/types/FolderEntityFolderData.d.ts +16 -0
  181. package/serialization/types/FolderEntityFolderData.js +37 -0
  182. package/serialization/types/FolderEntityPromptSandbox.d.ts +15 -0
  183. package/serialization/types/FolderEntityPromptSandbox.js +36 -0
  184. package/serialization/types/FolderEntityPromptSandboxData.d.ts +18 -0
  185. package/serialization/types/FolderEntityPromptSandboxData.js +39 -0
  186. package/serialization/types/FolderEntityTestSuite.d.ts +15 -0
  187. package/serialization/types/FolderEntityTestSuite.js +36 -0
  188. package/serialization/types/FolderEntityTestSuiteData.d.ts +17 -0
  189. package/serialization/types/FolderEntityTestSuiteData.js +38 -0
  190. package/serialization/types/FolderEntityWorkflowSandbox.d.ts +15 -0
  191. package/serialization/types/FolderEntityWorkflowSandbox.js +36 -0
  192. package/serialization/types/FolderEntityWorkflowSandboxData.d.ts +18 -0
  193. package/serialization/types/FolderEntityWorkflowSandboxData.js +39 -0
  194. package/serialization/types/PaginatedFolderEntityList.d.ts +16 -0
  195. package/serialization/types/PaginatedFolderEntityList.js +37 -0
  196. package/serialization/types/index.d.ts +12 -0
  197. package/serialization/types/index.js +12 -0
  198. package/version.d.ts +1 -1
  199. package/version.js +1 -1
@@ -46,7 +46,7 @@ const url_join_1 = __importDefault(require("url-join"));
46
46
  const serializers = __importStar(require("../../../../serialization/index"));
47
47
  const errors = __importStar(require("../../../../errors/index"));
48
48
  class Documents {
49
- constructor(_options) {
49
+ constructor(_options = {}) {
50
50
  this._options = _options;
51
51
  }
52
52
  /**
@@ -79,7 +79,7 @@ class Documents {
79
79
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
80
80
  .default, "v1/documents"),
81
81
  method: "GET",
82
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
82
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
83
83
  contentType: "application/json",
84
84
  queryParameters: _queryParams,
85
85
  requestType: "json",
@@ -132,7 +132,7 @@ class Documents {
132
132
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
133
133
  .default, `v1/documents/${encodeURIComponent(id)}`),
134
134
  method: "GET",
135
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
135
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
136
136
  contentType: "application/json",
137
137
  requestType: "json",
138
138
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
@@ -184,7 +184,7 @@ class Documents {
184
184
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
185
185
  .documents, `v1/documents/${encodeURIComponent(id)}`),
186
186
  method: "DELETE",
187
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
187
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
188
188
  contentType: "application/json",
189
189
  requestType: "json",
190
190
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
@@ -232,7 +232,7 @@ class Documents {
232
232
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
233
233
  .default, `v1/documents/${encodeURIComponent(id)}`),
234
234
  method: "PATCH",
235
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
235
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
236
236
  contentType: "application/json",
237
237
  requestType: "json",
238
238
  body: serializers.PatchedDocumentUpdateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -322,7 +322,7 @@ class Documents {
322
322
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
323
323
  .documents, "v1/upload-document"),
324
324
  method: "POST",
325
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), _maybeEncodedRequest.headers),
325
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), _maybeEncodedRequest.headers),
326
326
  requestType: "file",
327
327
  duplex: _maybeEncodedRequest.duplex,
328
328
  body: _maybeEncodedRequest.body,
@@ -7,7 +7,7 @@ import * as Vellum from "../../../index";
7
7
  export declare namespace FolderEntities {
8
8
  interface Options {
9
9
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
- apiKey: core.Supplier<string>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
11
  }
12
12
  interface RequestOptions {
13
13
  /** The maximum time to wait for a response in seconds. */
@@ -20,13 +20,31 @@ export declare namespace FolderEntities {
20
20
  }
21
21
  export declare class FolderEntities {
22
22
  protected readonly _options: FolderEntities.Options;
23
- constructor(_options: FolderEntities.Options);
23
+ constructor(_options?: FolderEntities.Options);
24
+ /**
25
+ * List all folder entities within a specified folder.
26
+ *
27
+ * @param {Vellum.FolderEntitiesListRequest} request
28
+ * @param {FolderEntities.RequestOptions} requestOptions - Request-specific configuration.
29
+ *
30
+ * @example
31
+ * await client.folderEntities.list({
32
+ * parentFolderId: "parent_folder_id"
33
+ * })
34
+ */
35
+ list(request: Vellum.FolderEntitiesListRequest, requestOptions?: FolderEntities.RequestOptions): Promise<Vellum.PaginatedFolderEntityList>;
24
36
  /**
25
37
  * Add an entity to a specific folder or root directory.
26
38
  *
27
39
  * Adding an entity to a folder will remove it from any other folders it might have been a member of.
28
40
  *
29
- * @param {string} folderId - The ID of the folder to which the entity should be added. This can be a UUID of a folder, or the name of a root directory (e.g. "PROMPT_SANDBOX").
41
+ * @param {string} folderId - The ID of the folder to which the entity should be added. This can be a UUID of a folder, or the name of a root
42
+ * directory. Supported root directories include:
43
+ *
44
+ * - PROMPT_SANDBOX
45
+ * - WORKFLOW_SANDBOX
46
+ * - DOCUMENT_INDEX
47
+ * - TEST_SUITE
30
48
  * @param {Vellum.AddEntityToFolderRequest} request
31
49
  * @param {FolderEntities.RequestOptions} requestOptions - Request-specific configuration.
32
50
  *
@@ -37,6 +55,6 @@ export declare class FolderEntities {
37
55
  */
38
56
  addEntityToFolder(folderId: string, request: Vellum.AddEntityToFolderRequest, requestOptions?: FolderEntities.RequestOptions): Promise<void>;
39
57
  protected _getCustomAuthorizationHeaders(): Promise<{
40
- X_API_KEY: string;
58
+ X_API_KEY: string | undefined;
41
59
  }>;
42
60
  }
@@ -41,19 +41,95 @@ Object.defineProperty(exports, "__esModule", { value: true });
41
41
  exports.FolderEntities = void 0;
42
42
  const environments = __importStar(require("../../../../environments"));
43
43
  const core = __importStar(require("../../../../core"));
44
- const serializers = __importStar(require("../../../../serialization/index"));
45
44
  const url_join_1 = __importDefault(require("url-join"));
45
+ const serializers = __importStar(require("../../../../serialization/index"));
46
46
  const errors = __importStar(require("../../../../errors/index"));
47
47
  class FolderEntities {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
+ /**
52
+ * List all folder entities within a specified folder.
53
+ *
54
+ * @param {Vellum.FolderEntitiesListRequest} request
55
+ * @param {FolderEntities.RequestOptions} requestOptions - Request-specific configuration.
56
+ *
57
+ * @example
58
+ * await client.folderEntities.list({
59
+ * parentFolderId: "parent_folder_id"
60
+ * })
61
+ */
62
+ list(request, requestOptions) {
63
+ var _a;
64
+ return __awaiter(this, void 0, void 0, function* () {
65
+ const { entityStatus, limit, offset, ordering, parentFolderId } = request;
66
+ const _queryParams = {};
67
+ if (entityStatus != null) {
68
+ _queryParams["entity_status"] = entityStatus;
69
+ }
70
+ if (limit != null) {
71
+ _queryParams["limit"] = limit.toString();
72
+ }
73
+ if (offset != null) {
74
+ _queryParams["offset"] = offset.toString();
75
+ }
76
+ if (ordering != null) {
77
+ _queryParams["ordering"] = ordering;
78
+ }
79
+ _queryParams["parent_folder_id"] = parentFolderId;
80
+ const _response = yield core.fetcher({
81
+ url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
82
+ .default, "v1/folder-entities"),
83
+ method: "GET",
84
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
85
+ contentType: "application/json",
86
+ queryParameters: _queryParams,
87
+ requestType: "json",
88
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
89
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
90
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
91
+ });
92
+ if (_response.ok) {
93
+ return serializers.PaginatedFolderEntityList.parseOrThrow(_response.body, {
94
+ unrecognizedObjectKeys: "passthrough",
95
+ allowUnrecognizedUnionMembers: true,
96
+ allowUnrecognizedEnumValues: true,
97
+ breadcrumbsPrefix: ["response"],
98
+ });
99
+ }
100
+ if (_response.error.reason === "status-code") {
101
+ throw new errors.VellumError({
102
+ statusCode: _response.error.statusCode,
103
+ body: _response.error.body,
104
+ });
105
+ }
106
+ switch (_response.error.reason) {
107
+ case "non-json":
108
+ throw new errors.VellumError({
109
+ statusCode: _response.error.statusCode,
110
+ body: _response.error.rawBody,
111
+ });
112
+ case "timeout":
113
+ throw new errors.VellumTimeoutError();
114
+ case "unknown":
115
+ throw new errors.VellumError({
116
+ message: _response.error.errorMessage,
117
+ });
118
+ }
119
+ });
120
+ }
51
121
  /**
52
122
  * Add an entity to a specific folder or root directory.
53
123
  *
54
124
  * Adding an entity to a folder will remove it from any other folders it might have been a member of.
55
125
  *
56
- * @param {string} folderId - The ID of the folder to which the entity should be added. This can be a UUID of a folder, or the name of a root directory (e.g. "PROMPT_SANDBOX").
126
+ * @param {string} folderId - The ID of the folder to which the entity should be added. This can be a UUID of a folder, or the name of a root
127
+ * directory. Supported root directories include:
128
+ *
129
+ * - PROMPT_SANDBOX
130
+ * - WORKFLOW_SANDBOX
131
+ * - DOCUMENT_INDEX
132
+ * - TEST_SUITE
57
133
  * @param {Vellum.AddEntityToFolderRequest} request
58
134
  * @param {FolderEntities.RequestOptions} requestOptions - Request-specific configuration.
59
135
  *
@@ -69,7 +145,7 @@ class FolderEntities {
69
145
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
70
146
  .default, `v1/folders/${encodeURIComponent(folderId)}/add-entity`),
71
147
  method: "POST",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
148
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
149
  contentType: "application/json",
74
150
  requestType: "json",
75
151
  body: serializers.AddEntityToFolderRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -0,0 +1,43 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Vellum from "../../../../index";
5
+ /**
6
+ * @example
7
+ * {
8
+ * parentFolderId: "parent_folder_id"
9
+ * }
10
+ */
11
+ export interface FolderEntitiesListRequest {
12
+ /**
13
+ * Filter down to only those objects whose entities have a status matching the status specified.
14
+ *
15
+ * - `ACTIVE` - Active
16
+ * - `ARCHIVED` - Archived
17
+ */
18
+ entityStatus?: Vellum.FolderEntitiesListRequestEntityStatus;
19
+ /**
20
+ * Number of results to return per page.
21
+ */
22
+ limit?: number;
23
+ /**
24
+ * The initial index from which to return the results.
25
+ */
26
+ offset?: number;
27
+ /**
28
+ * Which field to use when ordering the results.
29
+ */
30
+ ordering?: string;
31
+ /**
32
+ * Filter down to only those entities whose parent folder has the specified ID.
33
+ *
34
+ * To filter by an entity's parent folder, provide the ID of the parent folder. To filter by the root directory, provide
35
+ * a string representing the entity type of the root directory. Supported root directories include:
36
+ *
37
+ * - PROMPT_SANDBOX
38
+ * - WORKFLOW_SANDBOX
39
+ * - DOCUMENT_INDEX
40
+ * - TEST_SUITE
41
+ */
42
+ parentFolderId: string;
43
+ }
@@ -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 });
@@ -1 +1,2 @@
1
+ export { type FolderEntitiesListRequest } from "./FolderEntitiesListRequest";
1
2
  export { type AddEntityToFolderRequest } from "./AddEntityToFolderRequest";
@@ -1 +1,2 @@
1
+ export * from "./types";
1
2
  export * from "./client";
@@ -14,4 +14,5 @@ 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("./types"), exports);
17
18
  __exportStar(require("./client"), exports);
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export declare type FolderEntitiesListRequestEntityStatus = "ACTIVE" | "ARCHIVED";
5
+ export declare const FolderEntitiesListRequestEntityStatus: {
6
+ readonly Active: "ACTIVE";
7
+ readonly Archived: "ARCHIVED";
8
+ };
@@ -0,0 +1,10 @@
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.FolderEntitiesListRequestEntityStatus = void 0;
7
+ exports.FolderEntitiesListRequestEntityStatus = {
8
+ Active: "ACTIVE",
9
+ Archived: "ARCHIVED",
10
+ };
@@ -0,0 +1 @@
1
+ export * from "./FolderEntitiesListRequestEntityStatus";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./FolderEntitiesListRequestEntityStatus"), exports);
@@ -2,11 +2,12 @@ export * as deployments from "./deployments";
2
2
  export * from "./deployments/types";
3
3
  export * as documentIndexes from "./documentIndexes";
4
4
  export * from "./documentIndexes/types";
5
+ export * as folderEntities from "./folderEntities";
6
+ export * from "./folderEntities/types";
5
7
  export * as workflowDeployments from "./workflowDeployments";
6
8
  export * from "./workflowDeployments/types";
7
9
  export * as adHoc from "./adHoc";
8
10
  export * as documents from "./documents";
9
- export * as folderEntities from "./folderEntities";
10
11
  export * as metricDefinitions from "./metricDefinitions";
11
12
  export * as sandboxes from "./sandboxes";
12
13
  export * as testSuiteRuns from "./testSuiteRuns";
@@ -26,16 +26,17 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
26
26
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.workflowSandboxes = exports.testSuites = exports.testSuiteRuns = exports.sandboxes = exports.metricDefinitions = exports.folderEntities = exports.documents = exports.adHoc = exports.workflowDeployments = exports.documentIndexes = exports.deployments = void 0;
29
+ exports.workflowSandboxes = exports.testSuites = exports.testSuiteRuns = exports.sandboxes = exports.metricDefinitions = exports.documents = exports.adHoc = exports.workflowDeployments = exports.folderEntities = exports.documentIndexes = exports.deployments = void 0;
30
30
  exports.deployments = __importStar(require("./deployments"));
31
31
  __exportStar(require("./deployments/types"), exports);
32
32
  exports.documentIndexes = __importStar(require("./documentIndexes"));
33
33
  __exportStar(require("./documentIndexes/types"), exports);
34
+ exports.folderEntities = __importStar(require("./folderEntities"));
35
+ __exportStar(require("./folderEntities/types"), exports);
34
36
  exports.workflowDeployments = __importStar(require("./workflowDeployments"));
35
37
  __exportStar(require("./workflowDeployments/types"), exports);
36
38
  exports.adHoc = __importStar(require("./adHoc"));
37
39
  exports.documents = __importStar(require("./documents"));
38
- exports.folderEntities = __importStar(require("./folderEntities"));
39
40
  exports.metricDefinitions = __importStar(require("./metricDefinitions"));
40
41
  exports.sandboxes = __importStar(require("./sandboxes"));
41
42
  exports.testSuiteRuns = __importStar(require("./testSuiteRuns"));
@@ -7,7 +7,7 @@ import * as Vellum from "../../../index";
7
7
  export declare namespace MetricDefinitions {
8
8
  interface Options {
9
9
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
- apiKey: core.Supplier<string>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
11
  }
12
12
  interface RequestOptions {
13
13
  /** The maximum time to wait for a response in seconds. */
@@ -20,7 +20,7 @@ export declare namespace MetricDefinitions {
20
20
  }
21
21
  export declare class MetricDefinitions {
22
22
  protected readonly _options: MetricDefinitions.Options;
23
- constructor(_options: MetricDefinitions.Options);
23
+ constructor(_options?: MetricDefinitions.Options);
24
24
  /**
25
25
  * An internal-only endpoint that's subject to breaking changes without notice. Not intended for public use.
26
26
  *
@@ -39,6 +39,6 @@ export declare class MetricDefinitions {
39
39
  */
40
40
  executeMetricDefinition(id: string, request: Vellum.ExecuteMetricDefinitionRequest, requestOptions?: MetricDefinitions.RequestOptions): Promise<Vellum.MetricDefinitionExecution>;
41
41
  protected _getCustomAuthorizationHeaders(): Promise<{
42
- X_API_KEY: string;
42
+ X_API_KEY: string | undefined;
43
43
  }>;
44
44
  }
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization/index"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors/index"));
47
47
  class MetricDefinitions {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -71,7 +71,7 @@ class MetricDefinitions {
71
71
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
72
72
  .default, `v1/metric-definitions/${encodeURIComponent(id)}/execute`),
73
73
  method: "POST",
74
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
75
75
  contentType: "application/json",
76
76
  requestType: "json",
77
77
  body: serializers.ExecuteMetricDefinitionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -7,7 +7,7 @@ import * as Vellum from "../../../index";
7
7
  export declare namespace Sandboxes {
8
8
  interface Options {
9
9
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
- apiKey: core.Supplier<string>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
11
  }
12
12
  interface RequestOptions {
13
13
  /** The maximum time to wait for a response in seconds. */
@@ -20,7 +20,7 @@ export declare namespace Sandboxes {
20
20
  }
21
21
  export declare class Sandboxes {
22
22
  protected readonly _options: Sandboxes.Options;
23
- constructor(_options: Sandboxes.Options);
23
+ constructor(_options?: Sandboxes.Options);
24
24
  /**
25
25
  * @param {string} id - A UUID string identifying this sandbox.
26
26
  * @param {string} promptVariantId - An ID identifying the Prompt you'd like to deploy.
@@ -87,6 +87,6 @@ export declare class Sandboxes {
87
87
  */
88
88
  deleteSandboxScenario(id: string, scenarioId: string, requestOptions?: Sandboxes.RequestOptions): Promise<void>;
89
89
  protected _getCustomAuthorizationHeaders(): Promise<{
90
- X_API_KEY: string;
90
+ X_API_KEY: string | undefined;
91
91
  }>;
92
92
  }
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization/index"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors/index"));
47
47
  class Sandboxes {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -64,7 +64,7 @@ class Sandboxes {
64
64
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
65
65
  .default, `v1/sandboxes/${encodeURIComponent(id)}/prompts/${encodeURIComponent(promptVariantId)}/deploy`),
66
66
  method: "POST",
67
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
67
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
68
68
  contentType: "application/json",
69
69
  requestType: "json",
70
70
  body: serializers.DeploySandboxPromptRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -151,7 +151,7 @@ class Sandboxes {
151
151
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
152
152
  .default, `v1/sandboxes/${encodeURIComponent(id)}/scenarios`),
153
153
  method: "POST",
154
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
154
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
155
155
  contentType: "application/json",
156
156
  requestType: "json",
157
157
  body: serializers.UpsertSandboxScenarioRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -205,7 +205,7 @@ class Sandboxes {
205
205
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
206
206
  .default, `v1/sandboxes/${encodeURIComponent(id)}/scenarios/${encodeURIComponent(scenarioId)}`),
207
207
  method: "DELETE",
208
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
208
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
209
209
  contentType: "application/json",
210
210
  requestType: "json",
211
211
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
@@ -7,7 +7,7 @@ import * as Vellum from "../../../index";
7
7
  export declare namespace TestSuiteRuns {
8
8
  interface Options {
9
9
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
- apiKey: core.Supplier<string>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
11
  }
12
12
  interface RequestOptions {
13
13
  /** The maximum time to wait for a response in seconds. */
@@ -20,7 +20,7 @@ export declare namespace TestSuiteRuns {
20
20
  }
21
21
  export declare class TestSuiteRuns {
22
22
  protected readonly _options: TestSuiteRuns.Options;
23
- constructor(_options: TestSuiteRuns.Options);
23
+ constructor(_options?: TestSuiteRuns.Options);
24
24
  /**
25
25
  * Trigger a Test Suite and create a new Test Suite Run
26
26
  *
@@ -58,6 +58,6 @@ export declare class TestSuiteRuns {
58
58
  */
59
59
  listExecutions(id: string, request?: Vellum.TestSuiteRunsListExecutionsRequest, requestOptions?: TestSuiteRuns.RequestOptions): Promise<Vellum.PaginatedTestSuiteRunExecutionList>;
60
60
  protected _getCustomAuthorizationHeaders(): Promise<{
61
- X_API_KEY: string;
61
+ X_API_KEY: string | undefined;
62
62
  }>;
63
63
  }
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization/index"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors/index"));
47
47
  class TestSuiteRuns {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -71,7 +71,7 @@ class TestSuiteRuns {
71
71
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
72
72
  .default, "v1/test-suite-runs"),
73
73
  method: "POST",
74
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
75
75
  contentType: "application/json",
76
76
  requestType: "json",
77
77
  body: serializers.TestSuiteRunCreateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -124,7 +124,7 @@ class TestSuiteRuns {
124
124
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
125
125
  .default, `v1/test-suite-runs/${encodeURIComponent(id)}`),
126
126
  method: "GET",
127
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
127
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
128
128
  contentType: "application/json",
129
129
  requestType: "json",
130
130
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
@@ -191,7 +191,7 @@ class TestSuiteRuns {
191
191
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
192
192
  .default, `v1/test-suite-runs/${encodeURIComponent(id)}/executions`),
193
193
  method: "GET",
194
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
194
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
195
195
  contentType: "application/json",
196
196
  queryParameters: _queryParams,
197
197
  requestType: "json",
@@ -7,7 +7,7 @@ import * as Vellum from "../../../index";
7
7
  export declare namespace TestSuites {
8
8
  interface Options {
9
9
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
- apiKey: core.Supplier<string>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
11
  }
12
12
  interface RequestOptions {
13
13
  /** The maximum time to wait for a response in seconds. */
@@ -20,7 +20,7 @@ export declare namespace TestSuites {
20
20
  }
21
21
  export declare class TestSuites {
22
22
  protected readonly _options: TestSuites.Options;
23
- constructor(_options: TestSuites.Options);
23
+ constructor(_options?: TestSuites.Options);
24
24
  /**
25
25
  * List the Test Cases associated with a Test Suite
26
26
  *
@@ -74,6 +74,6 @@ export declare class TestSuites {
74
74
  */
75
75
  deleteTestSuiteTestCase(id: string, testCaseId: string, requestOptions?: TestSuites.RequestOptions): Promise<void>;
76
76
  protected _getCustomAuthorizationHeaders(): Promise<{
77
- X_API_KEY: string;
77
+ X_API_KEY: string | undefined;
78
78
  }>;
79
79
  }
@@ -45,7 +45,7 @@ const url_join_1 = __importDefault(require("url-join"));
45
45
  const serializers = __importStar(require("../../../../serialization/index"));
46
46
  const errors = __importStar(require("../../../../errors/index"));
47
47
  class TestSuites {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -73,7 +73,7 @@ class TestSuites {
73
73
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
74
74
  .default, `v1/test-suites/${encodeURIComponent(id)}/test-cases`),
75
75
  method: "GET",
76
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
76
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
77
77
  contentType: "application/json",
78
78
  queryParameters: _queryParams,
79
79
  requestType: "json",
@@ -142,7 +142,7 @@ class TestSuites {
142
142
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
143
143
  .default, `v1/test-suites/${encodeURIComponent(id)}/test-cases`),
144
144
  method: "POST",
145
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
145
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
146
146
  contentType: "application/json",
147
147
  requestType: "json",
148
148
  body: serializers.UpsertTestSuiteTestCaseRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -189,7 +189,7 @@ class TestSuites {
189
189
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
190
190
  .default, `v1/test-suites/${encodeURIComponent(id)}/test-cases-bulk`),
191
191
  method: "POST",
192
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
192
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
193
193
  contentType: "application/json",
194
194
  requestType: "json",
195
195
  body: serializers.testSuites.testSuiteTestCasesBulk.Request.jsonOrThrow(request, {
@@ -256,7 +256,7 @@ class TestSuites {
256
256
  url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
257
257
  .default, `v1/test-suites/${encodeURIComponent(id)}/test-cases/${encodeURIComponent(testCaseId)}`),
258
258
  method: "DELETE",
259
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.23", "User-Agent": "vellum-ai/0.8.23", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
259
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "vellum-ai", "X-Fern-SDK-Version": "0.8.25", "User-Agent": "vellum-ai/0.8.25", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
260
260
  contentType: "application/json",
261
261
  requestType: "json",
262
262
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,