vellum-ai 0.3.6 → 0.3.7

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 (81) hide show
  1. package/Client.d.ts +5 -2
  2. package/Client.js +25 -20
  3. package/api/resources/deployments/client/Client.d.ts +2 -2
  4. package/api/resources/deployments/client/Client.js +4 -4
  5. package/api/resources/documentIndexes/client/Client.d.ts +2 -2
  6. package/api/resources/documentIndexes/client/Client.js +3 -3
  7. package/api/resources/documents/client/Client.d.ts +2 -2
  8. package/api/resources/documents/client/Client.js +5 -5
  9. package/api/resources/folderEntities/client/Client.d.ts +31 -0
  10. package/api/resources/folderEntities/client/Client.js +106 -0
  11. package/api/resources/folderEntities/client/index.d.ts +1 -0
  12. package/api/resources/folderEntities/client/index.js +17 -0
  13. package/api/resources/folderEntities/client/requests/AddEntityToFolderRequest.d.ts +13 -0
  14. package/api/resources/folderEntities/client/requests/AddEntityToFolderRequest.js +5 -0
  15. package/api/resources/folderEntities/client/requests/index.d.ts +1 -0
  16. package/api/resources/folderEntities/client/requests/index.js +2 -0
  17. package/api/resources/folderEntities/index.d.ts +1 -0
  18. package/api/resources/folderEntities/index.js +17 -0
  19. package/api/resources/index.d.ts +2 -0
  20. package/api/resources/index.js +3 -1
  21. package/api/resources/modelVersions/client/Client.d.ts +2 -2
  22. package/api/resources/modelVersions/client/Client.js +2 -2
  23. package/api/resources/registeredPrompts/client/Client.d.ts +2 -2
  24. package/api/resources/registeredPrompts/client/Client.js +2 -2
  25. package/api/resources/sandboxes/client/Client.d.ts +2 -2
  26. package/api/resources/sandboxes/client/Client.js +3 -3
  27. package/api/resources/testSuites/client/Client.d.ts +2 -2
  28. package/api/resources/testSuites/client/Client.js +3 -3
  29. package/api/resources/workflowDeployments/client/Client.d.ts +2 -2
  30. package/api/resources/workflowDeployments/client/Client.js +2 -2
  31. package/dist/Client.d.ts +5 -2
  32. package/dist/Client.js +25 -20
  33. package/dist/api/resources/deployments/client/Client.d.ts +2 -2
  34. package/dist/api/resources/deployments/client/Client.js +4 -4
  35. package/dist/api/resources/documentIndexes/client/Client.d.ts +2 -2
  36. package/dist/api/resources/documentIndexes/client/Client.js +3 -3
  37. package/dist/api/resources/documents/client/Client.d.ts +2 -2
  38. package/dist/api/resources/documents/client/Client.js +5 -5
  39. package/dist/api/resources/folderEntities/client/Client.d.ts +31 -0
  40. package/dist/api/resources/folderEntities/client/Client.js +106 -0
  41. package/dist/api/resources/folderEntities/client/index.d.ts +1 -0
  42. package/dist/api/resources/folderEntities/client/index.js +17 -0
  43. package/dist/api/resources/folderEntities/client/requests/AddEntityToFolderRequest.d.ts +13 -0
  44. package/dist/api/resources/folderEntities/client/requests/AddEntityToFolderRequest.js +5 -0
  45. package/dist/api/resources/folderEntities/client/requests/index.d.ts +1 -0
  46. package/dist/api/resources/folderEntities/client/requests/index.js +2 -0
  47. package/dist/api/resources/folderEntities/index.d.ts +1 -0
  48. package/dist/api/resources/folderEntities/index.js +17 -0
  49. package/dist/api/resources/index.d.ts +2 -0
  50. package/dist/api/resources/index.js +3 -1
  51. package/dist/api/resources/modelVersions/client/Client.d.ts +2 -2
  52. package/dist/api/resources/modelVersions/client/Client.js +2 -2
  53. package/dist/api/resources/registeredPrompts/client/Client.d.ts +2 -2
  54. package/dist/api/resources/registeredPrompts/client/Client.js +2 -2
  55. package/dist/api/resources/sandboxes/client/Client.d.ts +2 -2
  56. package/dist/api/resources/sandboxes/client/Client.js +3 -3
  57. package/dist/api/resources/testSuites/client/Client.d.ts +2 -2
  58. package/dist/api/resources/testSuites/client/Client.js +3 -3
  59. package/dist/api/resources/workflowDeployments/client/Client.d.ts +2 -2
  60. package/dist/api/resources/workflowDeployments/client/Client.js +2 -2
  61. package/dist/serialization/resources/folderEntities/client/index.d.ts +1 -0
  62. package/dist/serialization/resources/folderEntities/client/index.js +17 -0
  63. package/dist/serialization/resources/folderEntities/client/requests/AddEntityToFolderRequest.d.ts +12 -0
  64. package/dist/serialization/resources/folderEntities/client/requests/AddEntityToFolderRequest.js +33 -0
  65. package/dist/serialization/resources/folderEntities/client/requests/index.d.ts +1 -0
  66. package/dist/serialization/resources/folderEntities/client/requests/index.js +5 -0
  67. package/dist/serialization/resources/folderEntities/index.d.ts +1 -0
  68. package/dist/serialization/resources/folderEntities/index.js +17 -0
  69. package/dist/serialization/resources/index.d.ts +2 -0
  70. package/dist/serialization/resources/index.js +3 -1
  71. package/package.json +1 -1
  72. package/serialization/resources/folderEntities/client/index.d.ts +1 -0
  73. package/serialization/resources/folderEntities/client/index.js +17 -0
  74. package/serialization/resources/folderEntities/client/requests/AddEntityToFolderRequest.d.ts +12 -0
  75. package/serialization/resources/folderEntities/client/requests/AddEntityToFolderRequest.js +33 -0
  76. package/serialization/resources/folderEntities/client/requests/index.d.ts +1 -0
  77. package/serialization/resources/folderEntities/client/requests/index.js +5 -0
  78. package/serialization/resources/folderEntities/index.d.ts +1 -0
  79. package/serialization/resources/folderEntities/index.js +17 -0
  80. package/serialization/resources/index.d.ts +2 -0
  81. package/serialization/resources/index.js +3 -1
@@ -46,7 +46,7 @@ const serializers = __importStar(require("../../../../serialization"));
46
46
  const url_join_1 = __importDefault(require("url-join"));
47
47
  const errors = __importStar(require("../../../../errors"));
48
48
  class RegisteredPrompts {
49
- constructor(_options) {
49
+ constructor(_options = {}) {
50
50
  this._options = _options;
51
51
  }
52
52
  /**
@@ -96,7 +96,7 @@ class RegisteredPrompts {
96
96
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
97
97
  "X-Fern-Language": "JavaScript",
98
98
  "X-Fern-SDK-Name": "vellum-ai",
99
- "X-Fern-SDK-Version": "0.3.6",
99
+ "X-Fern-SDK-Version": "0.3.7",
100
100
  "X-Fern-Runtime": core.RUNTIME.type,
101
101
  "X-Fern-Runtime-Version": core.RUNTIME.version,
102
102
  },
@@ -7,7 +7,7 @@ import * as Vellum from "../../..";
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
  timeoutInSeconds?: number;
@@ -16,7 +16,7 @@ export declare namespace Sandboxes {
16
16
  }
17
17
  export declare class Sandboxes {
18
18
  protected readonly _options: Sandboxes.Options;
19
- constructor(_options: Sandboxes.Options);
19
+ constructor(_options?: Sandboxes.Options);
20
20
  /**
21
21
  * Upserts a new scenario for a sandbox, keying off of the optionally provided scenario id.
22
22
  *
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors"));
47
47
  class Sandboxes {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -84,7 +84,7 @@ class Sandboxes {
84
84
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
85
85
  "X-Fern-Language": "JavaScript",
86
86
  "X-Fern-SDK-Name": "vellum-ai",
87
- "X-Fern-SDK-Version": "0.3.6",
87
+ "X-Fern-SDK-Version": "0.3.7",
88
88
  "X-Fern-Runtime": core.RUNTIME.type,
89
89
  "X-Fern-Runtime-Version": core.RUNTIME.version,
90
90
  },
@@ -141,7 +141,7 @@ class Sandboxes {
141
141
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
142
142
  "X-Fern-Language": "JavaScript",
143
143
  "X-Fern-SDK-Name": "vellum-ai",
144
- "X-Fern-SDK-Version": "0.3.6",
144
+ "X-Fern-SDK-Version": "0.3.7",
145
145
  "X-Fern-Runtime": core.RUNTIME.type,
146
146
  "X-Fern-Runtime-Version": core.RUNTIME.version,
147
147
  },
@@ -7,7 +7,7 @@ import * as Vellum from "../../..";
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
  timeoutInSeconds?: number;
@@ -16,7 +16,7 @@ export declare namespace TestSuites {
16
16
  }
17
17
  export declare class TestSuites {
18
18
  protected readonly _options: TestSuites.Options;
19
- constructor(_options: TestSuites.Options);
19
+ constructor(_options?: TestSuites.Options);
20
20
  /**
21
21
  * Upserts a new test case for a test suite, keying off of the optionally provided test case id.
22
22
  *
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors"));
47
47
  class TestSuites {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -74,7 +74,7 @@ class TestSuites {
74
74
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
75
75
  "X-Fern-Language": "JavaScript",
76
76
  "X-Fern-SDK-Name": "vellum-ai",
77
- "X-Fern-SDK-Version": "0.3.6",
77
+ "X-Fern-SDK-Version": "0.3.7",
78
78
  "X-Fern-Runtime": core.RUNTIME.type,
79
79
  "X-Fern-Runtime-Version": core.RUNTIME.version,
80
80
  },
@@ -131,7 +131,7 @@ class TestSuites {
131
131
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
132
132
  "X-Fern-Language": "JavaScript",
133
133
  "X-Fern-SDK-Name": "vellum-ai",
134
- "X-Fern-SDK-Version": "0.3.6",
134
+ "X-Fern-SDK-Version": "0.3.7",
135
135
  "X-Fern-Runtime": core.RUNTIME.type,
136
136
  "X-Fern-Runtime-Version": core.RUNTIME.version,
137
137
  },
@@ -7,7 +7,7 @@ import * as Vellum from "../../..";
7
7
  export declare namespace WorkflowDeployments {
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
  timeoutInSeconds?: number;
@@ -16,6 +16,6 @@ export declare namespace WorkflowDeployments {
16
16
  }
17
17
  export declare class WorkflowDeployments {
18
18
  protected readonly _options: WorkflowDeployments.Options;
19
- constructor(_options: WorkflowDeployments.Options);
19
+ constructor(_options?: WorkflowDeployments.Options);
20
20
  list(request?: Vellum.WorkflowDeploymentsListRequest, requestOptions?: WorkflowDeployments.RequestOptions): Promise<Vellum.PaginatedSlimWorkflowDeploymentList>;
21
21
  }
@@ -45,7 +45,7 @@ const url_join_1 = __importDefault(require("url-join"));
45
45
  const serializers = __importStar(require("../../../../serialization"));
46
46
  const errors = __importStar(require("../../../../errors"));
47
47
  class WorkflowDeployments {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  list(request = {}, requestOptions) {
@@ -73,7 +73,7 @@ class WorkflowDeployments {
73
73
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
74
74
  "X-Fern-Language": "JavaScript",
75
75
  "X-Fern-SDK-Name": "vellum-ai",
76
- "X-Fern-SDK-Version": "0.3.6",
76
+ "X-Fern-SDK-Version": "0.3.7",
77
77
  "X-Fern-Runtime": core.RUNTIME.type,
78
78
  "X-Fern-Runtime-Version": core.RUNTIME.version,
79
79
  },
package/dist/Client.d.ts CHANGED
@@ -7,6 +7,7 @@ import * as Vellum from "./api";
7
7
  import { Deployments } from "./api/resources/deployments/client/Client";
8
8
  import { DocumentIndexes } from "./api/resources/documentIndexes/client/Client";
9
9
  import { Documents } from "./api/resources/documents/client/Client";
10
+ import { FolderEntities } from "./api/resources/folderEntities/client/Client";
10
11
  import { ModelVersions } from "./api/resources/modelVersions/client/Client";
11
12
  import { RegisteredPrompts } from "./api/resources/registeredPrompts/client/Client";
12
13
  import { Sandboxes } from "./api/resources/sandboxes/client/Client";
@@ -15,7 +16,7 @@ import { WorkflowDeployments } from "./api/resources/workflowDeployments/client/
15
16
  export declare namespace VellumClient {
16
17
  interface Options {
17
18
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
18
- apiKey: core.Supplier<string>;
19
+ apiKey?: core.Supplier<string | undefined>;
19
20
  }
20
21
  interface RequestOptions {
21
22
  timeoutInSeconds?: number;
@@ -24,7 +25,7 @@ export declare namespace VellumClient {
24
25
  }
25
26
  export declare class VellumClient {
26
27
  protected readonly _options: VellumClient.Options;
27
- constructor(_options: VellumClient.Options);
28
+ constructor(_options?: VellumClient.Options);
28
29
  /**
29
30
  * Executes a deployed Prompt and returns the result.
30
31
  * @throws {@link Vellum.BadRequestError}
@@ -116,6 +117,8 @@ export declare class VellumClient {
116
117
  get documentIndexes(): DocumentIndexes;
117
118
  protected _documents: Documents | undefined;
118
119
  get documents(): Documents;
120
+ protected _folderEntities: FolderEntities | undefined;
121
+ get folderEntities(): FolderEntities;
119
122
  protected _modelVersions: ModelVersions | undefined;
120
123
  get modelVersions(): ModelVersions;
121
124
  protected _registeredPrompts: RegisteredPrompts | undefined;
package/dist/Client.js CHANGED
@@ -48,13 +48,14 @@ const errors = __importStar(require("./errors"));
48
48
  const Client_1 = require("./api/resources/deployments/client/Client");
49
49
  const Client_2 = require("./api/resources/documentIndexes/client/Client");
50
50
  const Client_3 = require("./api/resources/documents/client/Client");
51
- const Client_4 = require("./api/resources/modelVersions/client/Client");
52
- const Client_5 = require("./api/resources/registeredPrompts/client/Client");
53
- const Client_6 = require("./api/resources/sandboxes/client/Client");
54
- const Client_7 = require("./api/resources/testSuites/client/Client");
55
- const Client_8 = require("./api/resources/workflowDeployments/client/Client");
51
+ const Client_4 = require("./api/resources/folderEntities/client/Client");
52
+ const Client_5 = require("./api/resources/modelVersions/client/Client");
53
+ const Client_6 = require("./api/resources/registeredPrompts/client/Client");
54
+ const Client_7 = require("./api/resources/sandboxes/client/Client");
55
+ const Client_8 = require("./api/resources/testSuites/client/Client");
56
+ const Client_9 = require("./api/resources/workflowDeployments/client/Client");
56
57
  class VellumClient {
57
- constructor(_options) {
58
+ constructor(_options = {}) {
58
59
  this._options = _options;
59
60
  }
60
61
  /**
@@ -75,7 +76,7 @@ class VellumClient {
75
76
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
76
77
  "X-Fern-Language": "JavaScript",
77
78
  "X-Fern-SDK-Name": "vellum-ai",
78
- "X-Fern-SDK-Version": "0.3.6",
79
+ "X-Fern-SDK-Version": "0.3.7",
79
80
  "X-Fern-Runtime": core.RUNTIME.type,
80
81
  "X-Fern-Runtime-Version": core.RUNTIME.version,
81
82
  },
@@ -138,7 +139,7 @@ class VellumClient {
138
139
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
139
140
  "X-Fern-Language": "JavaScript",
140
141
  "X-Fern-SDK-Name": "vellum-ai",
141
- "X-Fern-SDK-Version": "0.3.6",
142
+ "X-Fern-SDK-Version": "0.3.7",
142
143
  "X-Fern-Runtime": core.RUNTIME.type,
143
144
  "X-Fern-Runtime-Version": core.RUNTIME.version,
144
145
  },
@@ -213,7 +214,7 @@ class VellumClient {
213
214
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
214
215
  "X-Fern-Language": "JavaScript",
215
216
  "X-Fern-SDK-Name": "vellum-ai",
216
- "X-Fern-SDK-Version": "0.3.6",
217
+ "X-Fern-SDK-Version": "0.3.7",
217
218
  "X-Fern-Runtime": core.RUNTIME.type,
218
219
  "X-Fern-Runtime-Version": core.RUNTIME.version,
219
220
  },
@@ -274,7 +275,7 @@ class VellumClient {
274
275
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
275
276
  "X-Fern-Language": "JavaScript",
276
277
  "X-Fern-SDK-Name": "vellum-ai",
277
- "X-Fern-SDK-Version": "0.3.6",
278
+ "X-Fern-SDK-Version": "0.3.7",
278
279
  "X-Fern-Runtime": core.RUNTIME.type,
279
280
  "X-Fern-Runtime-Version": core.RUNTIME.version,
280
281
  },
@@ -357,7 +358,7 @@ class VellumClient {
357
358
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
358
359
  "X-Fern-Language": "JavaScript",
359
360
  "X-Fern-SDK-Name": "vellum-ai",
360
- "X-Fern-SDK-Version": "0.3.6",
361
+ "X-Fern-SDK-Version": "0.3.7",
361
362
  "X-Fern-Runtime": core.RUNTIME.type,
362
363
  "X-Fern-Runtime-Version": core.RUNTIME.version,
363
364
  },
@@ -422,7 +423,7 @@ class VellumClient {
422
423
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
423
424
  "X-Fern-Language": "JavaScript",
424
425
  "X-Fern-SDK-Name": "vellum-ai",
425
- "X-Fern-SDK-Version": "0.3.6",
426
+ "X-Fern-SDK-Version": "0.3.7",
426
427
  "X-Fern-Runtime": core.RUNTIME.type,
427
428
  "X-Fern-Runtime-Version": core.RUNTIME.version,
428
429
  },
@@ -502,7 +503,7 @@ class VellumClient {
502
503
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
503
504
  "X-Fern-Language": "JavaScript",
504
505
  "X-Fern-SDK-Name": "vellum-ai",
505
- "X-Fern-SDK-Version": "0.3.6",
506
+ "X-Fern-SDK-Version": "0.3.7",
506
507
  "X-Fern-Runtime": core.RUNTIME.type,
507
508
  "X-Fern-Runtime-Version": core.RUNTIME.version,
508
509
  },
@@ -573,7 +574,7 @@ class VellumClient {
573
574
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
574
575
  "X-Fern-Language": "JavaScript",
575
576
  "X-Fern-SDK-Name": "vellum-ai",
576
- "X-Fern-SDK-Version": "0.3.6",
577
+ "X-Fern-SDK-Version": "0.3.7",
577
578
  "X-Fern-Runtime": core.RUNTIME.type,
578
579
  "X-Fern-Runtime-Version": core.RUNTIME.version,
579
580
  },
@@ -638,7 +639,7 @@ class VellumClient {
638
639
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
639
640
  "X-Fern-Language": "JavaScript",
640
641
  "X-Fern-SDK-Name": "vellum-ai",
641
- "X-Fern-SDK-Version": "0.3.6",
642
+ "X-Fern-SDK-Version": "0.3.7",
642
643
  "X-Fern-Runtime": core.RUNTIME.type,
643
644
  "X-Fern-Runtime-Version": core.RUNTIME.version,
644
645
  },
@@ -685,25 +686,29 @@ class VellumClient {
685
686
  var _a;
686
687
  return ((_a = this._documents) !== null && _a !== void 0 ? _a : (this._documents = new Client_3.Documents(this._options)));
687
688
  }
689
+ get folderEntities() {
690
+ var _a;
691
+ return ((_a = this._folderEntities) !== null && _a !== void 0 ? _a : (this._folderEntities = new Client_4.FolderEntities(this._options)));
692
+ }
688
693
  get modelVersions() {
689
694
  var _a;
690
- return ((_a = this._modelVersions) !== null && _a !== void 0 ? _a : (this._modelVersions = new Client_4.ModelVersions(this._options)));
695
+ return ((_a = this._modelVersions) !== null && _a !== void 0 ? _a : (this._modelVersions = new Client_5.ModelVersions(this._options)));
691
696
  }
692
697
  get registeredPrompts() {
693
698
  var _a;
694
- return ((_a = this._registeredPrompts) !== null && _a !== void 0 ? _a : (this._registeredPrompts = new Client_5.RegisteredPrompts(this._options)));
699
+ return ((_a = this._registeredPrompts) !== null && _a !== void 0 ? _a : (this._registeredPrompts = new Client_6.RegisteredPrompts(this._options)));
695
700
  }
696
701
  get sandboxes() {
697
702
  var _a;
698
- return ((_a = this._sandboxes) !== null && _a !== void 0 ? _a : (this._sandboxes = new Client_6.Sandboxes(this._options)));
703
+ return ((_a = this._sandboxes) !== null && _a !== void 0 ? _a : (this._sandboxes = new Client_7.Sandboxes(this._options)));
699
704
  }
700
705
  get testSuites() {
701
706
  var _a;
702
- return ((_a = this._testSuites) !== null && _a !== void 0 ? _a : (this._testSuites = new Client_7.TestSuites(this._options)));
707
+ return ((_a = this._testSuites) !== null && _a !== void 0 ? _a : (this._testSuites = new Client_8.TestSuites(this._options)));
703
708
  }
704
709
  get workflowDeployments() {
705
710
  var _a;
706
- return ((_a = this._workflowDeployments) !== null && _a !== void 0 ? _a : (this._workflowDeployments = new Client_8.WorkflowDeployments(this._options)));
711
+ return ((_a = this._workflowDeployments) !== null && _a !== void 0 ? _a : (this._workflowDeployments = new Client_9.WorkflowDeployments(this._options)));
707
712
  }
708
713
  }
709
714
  exports.VellumClient = VellumClient;
@@ -7,7 +7,7 @@ import * as Vellum from "../../..";
7
7
  export declare namespace Deployments {
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
  timeoutInSeconds?: number;
@@ -16,7 +16,7 @@ export declare namespace Deployments {
16
16
  }
17
17
  export declare class Deployments {
18
18
  protected readonly _options: Deployments.Options;
19
- constructor(_options: Deployments.Options);
19
+ constructor(_options?: Deployments.Options);
20
20
  list(request?: Vellum.DeploymentsListRequest, requestOptions?: Deployments.RequestOptions): Promise<Vellum.PaginatedSlimDeploymentReadList>;
21
21
  /**
22
22
  * Used to retrieve a deployment given its ID or name.
@@ -45,7 +45,7 @@ const url_join_1 = __importDefault(require("url-join"));
45
45
  const serializers = __importStar(require("../../../../serialization"));
46
46
  const errors = __importStar(require("../../../../errors"));
47
47
  class Deployments {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  list(request = {}, requestOptions) {
@@ -73,7 +73,7 @@ class Deployments {
73
73
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
74
74
  "X-Fern-Language": "JavaScript",
75
75
  "X-Fern-SDK-Name": "vellum-ai",
76
- "X-Fern-SDK-Version": "0.3.6",
76
+ "X-Fern-SDK-Version": "0.3.7",
77
77
  "X-Fern-Runtime": core.RUNTIME.type,
78
78
  "X-Fern-Runtime-Version": core.RUNTIME.version,
79
79
  },
@@ -128,7 +128,7 @@ class Deployments {
128
128
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
129
129
  "X-Fern-Language": "JavaScript",
130
130
  "X-Fern-SDK-Name": "vellum-ai",
131
- "X-Fern-SDK-Version": "0.3.6",
131
+ "X-Fern-SDK-Version": "0.3.7",
132
132
  "X-Fern-Runtime": core.RUNTIME.type,
133
133
  "X-Fern-Runtime-Version": core.RUNTIME.version,
134
134
  },
@@ -176,7 +176,7 @@ class Deployments {
176
176
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
177
177
  "X-Fern-Language": "JavaScript",
178
178
  "X-Fern-SDK-Name": "vellum-ai",
179
- "X-Fern-SDK-Version": "0.3.6",
179
+ "X-Fern-SDK-Version": "0.3.7",
180
180
  "X-Fern-Runtime": core.RUNTIME.type,
181
181
  "X-Fern-Runtime-Version": core.RUNTIME.version,
182
182
  },
@@ -7,7 +7,7 @@ import * as Vellum from "../../..";
7
7
  export declare namespace DocumentIndexes {
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
  timeoutInSeconds?: number;
@@ -16,7 +16,7 @@ export declare namespace DocumentIndexes {
16
16
  }
17
17
  export declare class DocumentIndexes {
18
18
  protected readonly _options: DocumentIndexes.Options;
19
- constructor(_options: DocumentIndexes.Options);
19
+ constructor(_options?: DocumentIndexes.Options);
20
20
  /**
21
21
  * Creates a new document index.
22
22
  *
@@ -45,7 +45,7 @@ const serializers = __importStar(require("../../../../serialization"));
45
45
  const url_join_1 = __importDefault(require("url-join"));
46
46
  const errors = __importStar(require("../../../../errors"));
47
47
  class DocumentIndexes {
48
- constructor(_options) {
48
+ constructor(_options = {}) {
49
49
  this._options = _options;
50
50
  }
51
51
  /**
@@ -85,7 +85,7 @@ class DocumentIndexes {
85
85
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
86
86
  "X-Fern-Language": "JavaScript",
87
87
  "X-Fern-SDK-Name": "vellum-ai",
88
- "X-Fern-SDK-Version": "0.3.6",
88
+ "X-Fern-SDK-Version": "0.3.7",
89
89
  "X-Fern-Runtime": core.RUNTIME.type,
90
90
  "X-Fern-Runtime-Version": core.RUNTIME.version,
91
91
  },
@@ -142,7 +142,7 @@ class DocumentIndexes {
142
142
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
143
143
  "X-Fern-Language": "JavaScript",
144
144
  "X-Fern-SDK-Name": "vellum-ai",
145
- "X-Fern-SDK-Version": "0.3.6",
145
+ "X-Fern-SDK-Version": "0.3.7",
146
146
  "X-Fern-Runtime": core.RUNTIME.type,
147
147
  "X-Fern-Runtime-Version": core.RUNTIME.version,
148
148
  },
@@ -9,7 +9,7 @@ import * as fs from "fs";
9
9
  export declare namespace Documents {
10
10
  interface Options {
11
11
  environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
12
- apiKey: core.Supplier<string>;
12
+ apiKey?: core.Supplier<string | undefined>;
13
13
  }
14
14
  interface RequestOptions {
15
15
  timeoutInSeconds?: number;
@@ -18,7 +18,7 @@ export declare namespace Documents {
18
18
  }
19
19
  export declare class Documents {
20
20
  protected readonly _options: Documents.Options;
21
- constructor(_options: Documents.Options);
21
+ constructor(_options?: Documents.Options);
22
22
  /**
23
23
  * Used to list documents. Optionally filter on supported fields.
24
24
  *
@@ -47,7 +47,7 @@ const serializers = __importStar(require("../../../../serialization"));
47
47
  const errors = __importStar(require("../../../../errors"));
48
48
  const form_data_1 = __importDefault(require("form-data"));
49
49
  class Documents {
50
- constructor(_options) {
50
+ constructor(_options = {}) {
51
51
  this._options = _options;
52
52
  }
53
53
  /**
@@ -81,7 +81,7 @@ class Documents {
81
81
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
82
82
  "X-Fern-Language": "JavaScript",
83
83
  "X-Fern-SDK-Name": "vellum-ai",
84
- "X-Fern-SDK-Version": "0.3.6",
84
+ "X-Fern-SDK-Version": "0.3.7",
85
85
  "X-Fern-Runtime": core.RUNTIME.type,
86
86
  "X-Fern-Runtime-Version": core.RUNTIME.version,
87
87
  },
@@ -130,7 +130,7 @@ class Documents {
130
130
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
131
131
  "X-Fern-Language": "JavaScript",
132
132
  "X-Fern-SDK-Name": "vellum-ai",
133
- "X-Fern-SDK-Version": "0.3.6",
133
+ "X-Fern-SDK-Version": "0.3.7",
134
134
  "X-Fern-Runtime": core.RUNTIME.type,
135
135
  "X-Fern-Runtime-Version": core.RUNTIME.version,
136
136
  },
@@ -179,7 +179,7 @@ class Documents {
179
179
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
180
180
  "X-Fern-Language": "JavaScript",
181
181
  "X-Fern-SDK-Name": "vellum-ai",
182
- "X-Fern-SDK-Version": "0.3.6",
182
+ "X-Fern-SDK-Version": "0.3.7",
183
183
  "X-Fern-Runtime": core.RUNTIME.type,
184
184
  "X-Fern-Runtime-Version": core.RUNTIME.version,
185
185
  },
@@ -265,7 +265,7 @@ class Documents {
265
265
  X_API_KEY: yield core.Supplier.get(this._options.apiKey),
266
266
  "X-Fern-Language": "JavaScript",
267
267
  "X-Fern-SDK-Name": "vellum-ai",
268
- "X-Fern-SDK-Version": "0.3.6",
268
+ "X-Fern-SDK-Version": "0.3.7",
269
269
  "X-Fern-Runtime": core.RUNTIME.type,
270
270
  "X-Fern-Runtime-Version": core.RUNTIME.version,
271
271
  },
@@ -0,0 +1,31 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as environments from "../../../../environments";
5
+ import * as core from "../../../../core";
6
+ import * as Vellum from "../../..";
7
+ export declare namespace FolderEntities {
8
+ interface Options {
9
+ environment?: core.Supplier<environments.VellumEnvironment | environments.VellumEnvironmentUrls>;
10
+ apiKey?: core.Supplier<string | undefined>;
11
+ }
12
+ interface RequestOptions {
13
+ timeoutInSeconds?: number;
14
+ maxRetries?: number;
15
+ }
16
+ }
17
+ export declare class FolderEntities {
18
+ protected readonly _options: FolderEntities.Options;
19
+ constructor(_options?: FolderEntities.Options);
20
+ /**
21
+ * Add an entity to a specific folder or root directory.
22
+ *
23
+ * Adding an entity to a folder will remove it from any other folders it might have been a member of.
24
+ *
25
+ * @example
26
+ * await vellum.folderEntities.addEntityToFolder("folder_id", {
27
+ * entityId: "entity_id"
28
+ * })
29
+ */
30
+ addEntityToFolder(folderId: string, request: Vellum.AddEntityToFolderRequest, requestOptions?: FolderEntities.RequestOptions): Promise<void>;
31
+ }
@@ -0,0 +1,106 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ var __importDefault = (this && this.__importDefault) || function (mod) {
38
+ return (mod && mod.__esModule) ? mod : { "default": mod };
39
+ };
40
+ Object.defineProperty(exports, "__esModule", { value: true });
41
+ exports.FolderEntities = void 0;
42
+ const environments = __importStar(require("../../../../environments"));
43
+ const core = __importStar(require("../../../../core"));
44
+ const serializers = __importStar(require("../../../../serialization"));
45
+ const url_join_1 = __importDefault(require("url-join"));
46
+ const errors = __importStar(require("../../../../errors"));
47
+ class FolderEntities {
48
+ constructor(_options = {}) {
49
+ this._options = _options;
50
+ }
51
+ /**
52
+ * Add an entity to a specific folder or root directory.
53
+ *
54
+ * Adding an entity to a folder will remove it from any other folders it might have been a member of.
55
+ *
56
+ * @example
57
+ * await vellum.folderEntities.addEntityToFolder("folder_id", {
58
+ * entityId: "entity_id"
59
+ * })
60
+ */
61
+ addEntityToFolder(folderId, request, requestOptions) {
62
+ var _a;
63
+ return __awaiter(this, void 0, void 0, function* () {
64
+ const _response = yield core.fetcher({
65
+ url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VellumEnvironment.Production)
66
+ .default, `v1/folders/${folderId}/add-entity`),
67
+ method: "POST",
68
+ headers: {
69
+ X_API_KEY: yield core.Supplier.get(this._options.apiKey),
70
+ "X-Fern-Language": "JavaScript",
71
+ "X-Fern-SDK-Name": "vellum-ai",
72
+ "X-Fern-SDK-Version": "0.3.7",
73
+ "X-Fern-Runtime": core.RUNTIME.type,
74
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
75
+ },
76
+ contentType: "application/json",
77
+ body: yield serializers.AddEntityToFolderRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
78
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
79
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
80
+ });
81
+ if (_response.ok) {
82
+ return;
83
+ }
84
+ if (_response.error.reason === "status-code") {
85
+ throw new errors.VellumError({
86
+ statusCode: _response.error.statusCode,
87
+ body: _response.error.body,
88
+ });
89
+ }
90
+ switch (_response.error.reason) {
91
+ case "non-json":
92
+ throw new errors.VellumError({
93
+ statusCode: _response.error.statusCode,
94
+ body: _response.error.rawBody,
95
+ });
96
+ case "timeout":
97
+ throw new errors.VellumTimeoutError();
98
+ case "unknown":
99
+ throw new errors.VellumError({
100
+ message: _response.error.errorMessage,
101
+ });
102
+ }
103
+ });
104
+ }
105
+ }
106
+ exports.FolderEntities = FolderEntities;
@@ -0,0 +1 @@
1
+ export * from "./requests";
@@ -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("./requests"), exports);