scorecard-ai 0.5.2 → 0.5.3

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.
@@ -97,7 +97,7 @@ class Prompt {
97
97
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
98
98
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/prompt"),
99
99
  method: "POST",
100
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
100
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
101
101
  contentType: "application/json",
102
102
  body: yield serializers.PromptCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
103
103
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -189,7 +189,7 @@ class Prompt {
189
189
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
190
190
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
191
191
  method: "GET",
192
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "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": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
193
193
  contentType: "application/json",
194
194
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
195
195
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -280,7 +280,7 @@ class Prompt {
280
280
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
281
281
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
282
282
  method: "DELETE",
283
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
283
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
284
284
  contentType: "application/json",
285
285
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
286
286
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -370,7 +370,7 @@ class Prompt {
370
370
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
371
371
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
372
372
  method: "PATCH",
373
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
373
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
374
374
  contentType: "application/json",
375
375
  body: yield serializers.PromptUpdateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
376
376
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -462,7 +462,7 @@ class Prompt {
462
462
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
463
463
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/name/${encodeURIComponent(name)}`),
464
464
  method: "GET",
465
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
465
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
466
466
  contentType: "application/json",
467
467
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
468
468
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -69,7 +69,7 @@ class Run {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/run"),
71
71
  method: "POST",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  body: yield serializers.RunCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
75
75
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -161,7 +161,7 @@ class Run {
161
161
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
162
162
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}`),
163
163
  method: "GET",
164
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
164
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
165
165
  contentType: "application/json",
166
166
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
167
167
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -253,7 +253,7 @@ class Run {
253
253
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
254
254
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/status`),
255
255
  method: "PATCH",
256
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
256
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
257
257
  contentType: "application/json",
258
258
  body: yield serializers.UpdateStatusParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
259
259
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class RunMetric {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run_metric/${encodeURIComponent(runId)}`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -73,7 +73,7 @@ class Score {
73
73
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
74
74
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}/score`),
75
75
  method: "POST",
76
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "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": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
77
77
  contentType: "application/json",
78
78
  body: yield serializers.ScoreCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
79
79
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -168,7 +168,7 @@ class Score {
168
168
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
169
169
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}/score/${encodeURIComponent(scoreId)}`),
170
170
  method: "PATCH",
171
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
171
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
172
172
  contentType: "application/json",
173
173
  body: yield serializers.ScoreUpdateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
174
174
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -70,7 +70,7 @@ class Testcase {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase`),
72
72
  method: "POST",
73
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
74
  contentType: "application/json",
75
75
  body: yield serializers.TestcaseCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
76
76
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -163,7 +163,7 @@ class Testcase {
163
163
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
164
164
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase/${encodeURIComponent(testcaseId)}`),
165
165
  method: "GET",
166
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
166
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
167
167
  contentType: "application/json",
168
168
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
169
169
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -255,7 +255,7 @@ class Testcase {
255
255
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
256
256
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase/${encodeURIComponent(testcaseId)}`),
257
257
  method: "DELETE",
258
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
258
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
259
259
  contentType: "application/json",
260
260
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
261
261
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -70,7 +70,7 @@ class Testrecord {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}`),
72
72
  method: "GET",
73
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
74
  contentType: "application/json",
75
75
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
76
76
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -162,7 +162,7 @@ class Testrecord {
162
162
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
163
163
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord`),
164
164
  method: "POST",
165
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
165
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
166
166
  contentType: "application/json",
167
167
  body: yield serializers.TestrecordCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
168
168
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class Testset {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -160,7 +160,7 @@ class Testset {
160
160
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
161
161
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}`),
162
162
  method: "DELETE",
163
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
163
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
164
164
  contentType: "application/json",
165
165
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
166
166
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -253,7 +253,7 @@ class Testset {
253
253
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
254
254
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/testset"),
255
255
  method: "POST",
256
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
256
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
257
257
  contentType: "application/json",
258
258
  body: yield serializers.TestsetCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
259
259
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -345,7 +345,7 @@ class Testset {
345
345
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
346
346
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/schema`),
347
347
  method: "GET",
348
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
348
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
349
349
  contentType: "application/json",
350
350
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
351
351
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -445,7 +445,7 @@ class Testset {
445
445
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
446
446
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase`),
447
447
  method: "GET",
448
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
448
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
449
449
  contentType: "application/json",
450
450
  queryParameters: _queryParams,
451
451
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class Traces {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/traces/${encodeURIComponent(traceId)}/spans`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -97,7 +97,7 @@ class Prompt {
97
97
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
98
98
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/prompt"),
99
99
  method: "POST",
100
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
100
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
101
101
  contentType: "application/json",
102
102
  body: yield serializers.PromptCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
103
103
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -189,7 +189,7 @@ class Prompt {
189
189
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
190
190
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
191
191
  method: "GET",
192
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "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": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
193
193
  contentType: "application/json",
194
194
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
195
195
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -280,7 +280,7 @@ class Prompt {
280
280
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
281
281
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
282
282
  method: "DELETE",
283
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
283
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
284
284
  contentType: "application/json",
285
285
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
286
286
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -370,7 +370,7 @@ class Prompt {
370
370
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
371
371
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/${encodeURIComponent(id)}`),
372
372
  method: "PATCH",
373
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
373
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
374
374
  contentType: "application/json",
375
375
  body: yield serializers.PromptUpdateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
376
376
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -462,7 +462,7 @@ class Prompt {
462
462
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
463
463
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/prompt/name/${encodeURIComponent(name)}`),
464
464
  method: "GET",
465
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
465
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
466
466
  contentType: "application/json",
467
467
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
468
468
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -69,7 +69,7 @@ class Run {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/run"),
71
71
  method: "POST",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  body: yield serializers.RunCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
75
75
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -161,7 +161,7 @@ class Run {
161
161
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
162
162
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}`),
163
163
  method: "GET",
164
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
164
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
165
165
  contentType: "application/json",
166
166
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
167
167
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -253,7 +253,7 @@ class Run {
253
253
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
254
254
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/status`),
255
255
  method: "PATCH",
256
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
256
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
257
257
  contentType: "application/json",
258
258
  body: yield serializers.UpdateStatusParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
259
259
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class RunMetric {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run_metric/${encodeURIComponent(runId)}`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -73,7 +73,7 @@ class Score {
73
73
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
74
74
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}/score`),
75
75
  method: "POST",
76
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "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": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
77
77
  contentType: "application/json",
78
78
  body: yield serializers.ScoreCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
79
79
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -168,7 +168,7 @@ class Score {
168
168
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
169
169
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}/score/${encodeURIComponent(scoreId)}`),
170
170
  method: "PATCH",
171
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
171
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
172
172
  contentType: "application/json",
173
173
  body: yield serializers.ScoreUpdateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
174
174
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -70,7 +70,7 @@ class Testcase {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase`),
72
72
  method: "POST",
73
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
74
  contentType: "application/json",
75
75
  body: yield serializers.TestcaseCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
76
76
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -163,7 +163,7 @@ class Testcase {
163
163
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
164
164
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase/${encodeURIComponent(testcaseId)}`),
165
165
  method: "GET",
166
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
166
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
167
167
  contentType: "application/json",
168
168
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
169
169
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -255,7 +255,7 @@ class Testcase {
255
255
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
256
256
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase/${encodeURIComponent(testcaseId)}`),
257
257
  method: "DELETE",
258
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
258
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
259
259
  contentType: "application/json",
260
260
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
261
261
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -70,7 +70,7 @@ class Testrecord {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord/${encodeURIComponent(testrecordId)}`),
72
72
  method: "GET",
73
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
74
74
  contentType: "application/json",
75
75
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
76
76
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -162,7 +162,7 @@ class Testrecord {
162
162
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
163
163
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/run/${encodeURIComponent(runId)}/testrecord`),
164
164
  method: "POST",
165
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
165
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
166
166
  contentType: "application/json",
167
167
  body: yield serializers.TestrecordCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
168
168
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class Testset {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -160,7 +160,7 @@ class Testset {
160
160
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
161
161
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}`),
162
162
  method: "DELETE",
163
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
163
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
164
164
  contentType: "application/json",
165
165
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
166
166
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -253,7 +253,7 @@ class Testset {
253
253
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
254
254
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, "v1/testset"),
255
255
  method: "POST",
256
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
256
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
257
257
  contentType: "application/json",
258
258
  body: yield serializers.TestsetCreateParams.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
259
259
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -345,7 +345,7 @@ class Testset {
345
345
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
346
346
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/schema`),
347
347
  method: "GET",
348
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
348
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
349
349
  contentType: "application/json",
350
350
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
351
351
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -445,7 +445,7 @@ class Testset {
445
445
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
446
446
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/testset/${encodeURIComponent(testsetId)}/testcase`),
447
447
  method: "GET",
448
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
448
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
449
449
  contentType: "application/json",
450
450
  queryParameters: _queryParams,
451
451
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -69,7 +69,7 @@ class Traces {
69
69
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
70
70
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ScorecardEnvironment.Default, `v1/traces/${encodeURIComponent(traceId)}/spans`),
71
71
  method: "GET",
72
- headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
72
+ headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "scorecard-ai", "X-Fern-SDK-Version": "0.5.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
73
73
  contentType: "application/json",
74
74
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
75
75
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -1,15 +1,5 @@
1
1
  import { ScorecardClient as FernClient } from "../Client";
2
- import { ScorecardEnvironment } from "../environments";
3
- import * as core from "../core";
4
2
  export declare namespace ScorecardClient {
5
- interface Options {
6
- /**
7
- * Your Scorecard API Key. Defaults to the environment
8
- * variable SCORECARD_API_KEY.
9
- */
10
- apiKey?: core.Supplier<string>;
11
- environment?: core.Supplier<ScorecardEnvironment | string>;
12
- }
13
3
  interface RequestOptions extends FernClient.RequestOptions {
14
4
  }
15
5
  interface RunTestArgs {
@@ -28,7 +18,6 @@ export declare namespace ScorecardClient {
28
18
  }
29
19
  }
30
20
  export declare class ScorecardClient extends FernClient {
31
- constructor(options?: ScorecardClient.Options);
32
21
  /**
33
22
  * Runs all tests within a testset
34
23
  */
@@ -36,16 +36,6 @@ exports.ScorecardClient = void 0;
36
36
  const Client_1 = require("../Client");
37
37
  const errors = __importStar(require("../errors"));
38
38
  class ScorecardClient extends Client_1.ScorecardClient {
39
- constructor(options = {}) {
40
- var _a;
41
- const apiKey = (_a = options.apiKey) !== null && _a !== void 0 ? _a : process.env["SCORECARD_API_KEY"];
42
- if (apiKey !== undefined) {
43
- super(Object.assign(Object.assign({}, options), { apiKey }));
44
- }
45
- throw new errors.ScorecardError({
46
- message: "Please pass in your Scorecard API Key or export SCORECARD_API_KEY in your environment.",
47
- });
48
- }
49
39
  /**
50
40
  * Runs all tests within a testset
51
41
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scorecard-ai",
3
- "version": "0.5.2",
3
+ "version": "0.5.3",
4
4
  "private": false,
5
5
  "repository": "https://github.com/scorecard-ai/scorecard-node",
6
6
  "license": "See LICENSE",
@@ -1,15 +1,5 @@
1
1
  import { ScorecardClient as FernClient } from "../Client";
2
- import { ScorecardEnvironment } from "../environments";
3
- import * as core from "../core";
4
2
  export declare namespace ScorecardClient {
5
- interface Options {
6
- /**
7
- * Your Scorecard API Key. Defaults to the environment
8
- * variable SCORECARD_API_KEY.
9
- */
10
- apiKey?: core.Supplier<string>;
11
- environment?: core.Supplier<ScorecardEnvironment | string>;
12
- }
13
3
  interface RequestOptions extends FernClient.RequestOptions {
14
4
  }
15
5
  interface RunTestArgs {
@@ -28,7 +18,6 @@ export declare namespace ScorecardClient {
28
18
  }
29
19
  }
30
20
  export declare class ScorecardClient extends FernClient {
31
- constructor(options?: ScorecardClient.Options);
32
21
  /**
33
22
  * Runs all tests within a testset
34
23
  */
@@ -36,16 +36,6 @@ exports.ScorecardClient = void 0;
36
36
  const Client_1 = require("../Client");
37
37
  const errors = __importStar(require("../errors"));
38
38
  class ScorecardClient extends Client_1.ScorecardClient {
39
- constructor(options = {}) {
40
- var _a;
41
- const apiKey = (_a = options.apiKey) !== null && _a !== void 0 ? _a : process.env["SCORECARD_API_KEY"];
42
- if (apiKey !== undefined) {
43
- super(Object.assign(Object.assign({}, options), { apiKey }));
44
- }
45
- throw new errors.ScorecardError({
46
- message: "Please pass in your Scorecard API Key or export SCORECARD_API_KEY in your environment.",
47
- });
48
- }
49
39
  /**
50
40
  * Runs all tests within a testset
51
41
  */