@orq-ai/node 4.16.13 → 4.16.14

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 (59) hide show
  1. package/jsr.json +1 -1
  2. package/lib/config.d.ts +3 -3
  3. package/lib/config.js +3 -3
  4. package/models/components/reasoningpart.js +1 -1
  5. package/models/operations/createtool.js +4 -4
  6. package/models/operations/getalltools.js +4 -4
  7. package/models/operations/getv2humanevalsets.js +2 -2
  8. package/models/operations/getv2humanevalsetsid.js +2 -2
  9. package/models/operations/listdeploymentversions.js +1 -1
  10. package/models/operations/patchv2humanevalsetsid.js +2 -2
  11. package/models/operations/postv2feedbackevaluation.js +4 -4
  12. package/models/operations/postv2humanevalsets.js +2 -2
  13. package/models/operations/retrievetool.js +4 -4
  14. package/models/operations/runagent.js +1 -1
  15. package/models/operations/streamrunagent.js +1 -1
  16. package/models/operations/updatetool.js +4 -4
  17. package/package.json +6 -6
  18. package/packages/orq-rc/src/funcs/humanReviewSetsCreate.ts +5 -0
  19. package/packages/orq-rc/src/funcs/humanReviewSetsDelete.ts +5 -0
  20. package/packages/orq-rc/src/funcs/humanReviewSetsGet.ts +5 -0
  21. package/packages/orq-rc/src/funcs/humanReviewSetsList.ts +5 -0
  22. package/packages/orq-rc/src/funcs/humanReviewSetsUpdate.ts +5 -0
  23. package/packages/orq-rc/src/lib/config.ts +2 -2
  24. package/packages/orq-rc/src/models/components/reasoningpart.ts +1 -1
  25. package/packages/orq-rc/src/models/operations/createtool.ts +4 -4
  26. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +15 -18
  27. package/packages/orq-rc/src/models/operations/deploymentstream.ts +11 -14
  28. package/packages/orq-rc/src/models/operations/getalltools.ts +4 -4
  29. package/packages/orq-rc/src/models/operations/getv2humanevalsets.ts +2 -2
  30. package/packages/orq-rc/src/models/operations/getv2humanevalsetsid.ts +2 -2
  31. package/packages/orq-rc/src/models/operations/index.ts +0 -2
  32. package/packages/orq-rc/src/models/operations/listdeploymentversions.ts +1 -1
  33. package/packages/orq-rc/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  34. package/packages/orq-rc/src/models/operations/postv2humanevalsets.ts +21 -35
  35. package/packages/orq-rc/src/models/operations/retrievetool.ts +4 -4
  36. package/packages/orq-rc/src/models/operations/runagent.ts +1 -1
  37. package/packages/orq-rc/src/models/operations/streamrunagent.ts +1 -1
  38. package/packages/orq-rc/src/models/operations/updatetool.ts +4 -4
  39. package/packages/orq-rc/src/sdk/feedback.ts +0 -30
  40. package/packages/orq-rc/src/sdk/humanreviewsets.ts +25 -0
  41. package/packages/orq-rc/src/sdk/sdk.ts +5 -5
  42. package/src/lib/config.ts +3 -3
  43. package/src/models/components/reasoningpart.ts +1 -1
  44. package/src/models/operations/createtool.ts +4 -4
  45. package/src/models/operations/getalltools.ts +4 -4
  46. package/src/models/operations/getv2humanevalsets.ts +2 -2
  47. package/src/models/operations/getv2humanevalsetsid.ts +2 -2
  48. package/src/models/operations/listdeploymentversions.ts +1 -1
  49. package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  50. package/src/models/operations/postv2feedbackevaluation.ts +4 -4
  51. package/src/models/operations/postv2humanevalsets.ts +2 -2
  52. package/src/models/operations/retrievetool.ts +4 -4
  53. package/src/models/operations/runagent.ts +1 -1
  54. package/src/models/operations/streamrunagent.ts +1 -1
  55. package/src/models/operations/updatetool.ts +4 -4
  56. package/packages/orq-rc/src/funcs/feedbackCreateEvaluation.ts +0 -173
  57. package/packages/orq-rc/src/funcs/feedbackRemoveEvaluation.ts +0 -173
  58. package/packages/orq-rc/src/models/operations/postv2feedbackevaluation.ts +0 -453
  59. package/packages/orq-rc/src/models/operations/postv2feedbackevaluationremove.ts +0 -43
@@ -245,7 +245,7 @@ export const RequestBody4$outboundSchema: z.ZodType<
245
245
  PostV2FeedbackEvaluationRequestBodyFeedbackRequestSource$outboundSchema
246
246
  .default("orq"),
247
247
  explanation: z.string().optional(),
248
- reviewedAt: z.date().default(() => new Date("2026-10-20T08:24:11.743Z"))
248
+ reviewedAt: z.date().default(() => new Date("2026-10-20T09:57:29.587Z"))
249
249
  .transform(v => v.toISOString()),
250
250
  type: z.literal("string_array"),
251
251
  values: z.array(z.string()),
@@ -299,7 +299,7 @@ export const Three$outboundSchema: z.ZodType<
299
299
  source: PostV2FeedbackEvaluationRequestBodyFeedbackSource$outboundSchema
300
300
  .default("orq"),
301
301
  explanation: z.string().optional(),
302
- reviewedAt: z.date().default(() => new Date("2026-10-20T08:24:11.743Z"))
302
+ reviewedAt: z.date().default(() => new Date("2026-10-20T09:57:29.586Z"))
303
303
  .transform(v => v.toISOString()),
304
304
  type: z.literal("boolean"),
305
305
  value: z.boolean(),
@@ -353,7 +353,7 @@ export const RequestBody2$outboundSchema: z.ZodType<
353
353
  "orq",
354
354
  ),
355
355
  explanation: z.string().optional(),
356
- reviewedAt: z.date().default(() => new Date("2026-10-20T08:24:11.743Z"))
356
+ reviewedAt: z.date().default(() => new Date("2026-10-20T09:57:29.586Z"))
357
357
  .transform(v => v.toISOString()),
358
358
  type: z.literal("number"),
359
359
  value: z.number(),
@@ -405,7 +405,7 @@ export const RequestBody1$outboundSchema: z.ZodType<
405
405
  humanReviewId: z.string().optional(),
406
406
  source: RequestBodySource$outboundSchema.default("orq"),
407
407
  explanation: z.string().optional(),
408
- reviewedAt: z.date().default(() => new Date("2026-10-20T08:24:11.742Z"))
408
+ reviewedAt: z.date().default(() => new Date("2026-10-20T09:57:29.586Z"))
409
409
  .transform(v => v.toISOString()),
410
410
  type: z.literal("string"),
411
411
  value: z.string(),
@@ -271,7 +271,7 @@ export const PostV2HumanEvalSetsResponseBody2$inboundSchema: z.ZodType<
271
271
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
272
272
  .optional(),
273
273
  updated: z.string().datetime({ offset: true }).default(
274
- "2026-10-20T08:24:03.277Z",
274
+ "2026-10-20T09:57:21.331Z",
275
275
  ).transform(v => new Date(v)),
276
276
  filter_type: z.literal("name"),
277
277
  filter_value: z.string(),
@@ -316,7 +316,7 @@ export const PostV2HumanEvalSetsResponseBody1$inboundSchema: z.ZodType<
316
316
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
317
317
  .optional(),
318
318
  updated: z.string().datetime({ offset: true }).default(
319
- "2026-10-20T08:24:03.277Z",
319
+ "2026-10-20T09:57:21.331Z",
320
320
  ).transform(v => new Date(v)),
321
321
  filter_type: z.literal("span_type"),
322
322
  filter_values: z.array(z.string()),
@@ -624,7 +624,7 @@ export const RetrieveToolResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
624
624
  z.ZodTypeDef,
625
625
  unknown
626
626
  > = z.object({
627
- _id: z.string().default("tool_01M5C6JCNF5E8WZHWDP2RYCMA6"),
627
+ _id: z.string().default("tool_01M5CBX7A453MFR44QW27Z1DM8"),
628
628
  path: z.string(),
629
629
  key: z.string(),
630
630
  display_name: z.string().optional(),
@@ -820,7 +820,7 @@ export const RetrieveToolResponseBodyHTTPTool$inboundSchema: z.ZodType<
820
820
  z.ZodTypeDef,
821
821
  unknown
822
822
  > = z.object({
823
- _id: z.string().default("tool_01M5C6JCNEHXRSXQK9XHMVHDNM"),
823
+ _id: z.string().default("tool_01M5CBX7A3AMM0K1AMXBD6YZ94"),
824
824
  path: z.string(),
825
825
  key: z.string(),
826
826
  display_name: z.string().optional(),
@@ -916,7 +916,7 @@ export const RetrieveToolResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
916
916
  z.ZodTypeDef,
917
917
  unknown
918
918
  > = z.object({
919
- _id: z.string().default("tool_01M5C6JCNDZ3Q680K259ZQEC26"),
919
+ _id: z.string().default("tool_01M5CBX7A30JRR39YWSVVCGH6Z"),
920
920
  path: z.string(),
921
921
  key: z.string(),
922
922
  display_name: z.string().optional(),
@@ -1022,7 +1022,7 @@ export const RetrieveToolResponseBodyFunctionTool$inboundSchema: z.ZodType<
1022
1022
  z.ZodTypeDef,
1023
1023
  unknown
1024
1024
  > = z.object({
1025
- _id: z.string().default("tool_01M5C6JCNDA9Q8K2P1N768BJS0"),
1025
+ _id: z.string().default("tool_01M5CBX7A2CG97C16SE79YA765"),
1026
1026
  path: z.string(),
1027
1027
  key: z.string(),
1028
1028
  display_name: z.string().optional(),
@@ -3890,7 +3890,7 @@ export const Tools$outboundSchema: z.ZodType<
3890
3890
  z.ZodTypeDef,
3891
3891
  Tools
3892
3892
  > = z.object({
3893
- id: z.string().default("01M5C6JCJ8QQYX8AWRBS918N8N"),
3893
+ id: z.string().default("01M5CBX76W0RE36TZY6QKS2WE0"),
3894
3894
  name: z.string(),
3895
3895
  description: z.string().optional(),
3896
3896
  schema: z.lazy(() => AgentToolInputRunSchema$outboundSchema),
@@ -3949,7 +3949,7 @@ export const AgentToolInputRunTools$outboundSchema: z.ZodType<
3949
3949
  z.ZodTypeDef,
3950
3950
  AgentToolInputRunTools
3951
3951
  > = z.object({
3952
- id: z.string().default("01M5C6JCK06FTQXJ7MFGB7D939"),
3952
+ id: z.string().default("01M5CBX77MQPRCWG4SB1KR9F75"),
3953
3953
  name: z.string(),
3954
3954
  description: z.string().optional(),
3955
3955
  schema: z.lazy(() =>
@@ -1764,7 +1764,7 @@ export const UpdateToolResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
1764
1764
  z.ZodTypeDef,
1765
1765
  unknown
1766
1766
  > = z.object({
1767
- _id: z.string().default("tool_01M5C6JCN5WESWVHGJPNKGJ87F"),
1767
+ _id: z.string().default("tool_01M5CBX79VKW1WVZDEMRTSHKE5"),
1768
1768
  path: z.string(),
1769
1769
  key: z.string(),
1770
1770
  display_name: z.string().optional(),
@@ -1959,7 +1959,7 @@ export const UpdateToolResponseBodyHTTPTool$inboundSchema: z.ZodType<
1959
1959
  z.ZodTypeDef,
1960
1960
  unknown
1961
1961
  > = z.object({
1962
- _id: z.string().default("tool_01M5C6JCN48E3PATTHTMG1QBD8"),
1962
+ _id: z.string().default("tool_01M5CBX79T5G5448XZS1GH1J65"),
1963
1963
  path: z.string(),
1964
1964
  key: z.string(),
1965
1965
  display_name: z.string().optional(),
@@ -2054,7 +2054,7 @@ export const UpdateToolResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
2054
2054
  z.ZodTypeDef,
2055
2055
  unknown
2056
2056
  > = z.object({
2057
- _id: z.string().default("tool_01M5C6JCN4MXHMEPTNTQZE2RFN"),
2057
+ _id: z.string().default("tool_01M5CBX79SK4S0RZQ0C500H03C"),
2058
2058
  path: z.string(),
2059
2059
  key: z.string(),
2060
2060
  display_name: z.string().optional(),
@@ -2157,7 +2157,7 @@ export const UpdateToolResponseBodyFunctionTool$inboundSchema: z.ZodType<
2157
2157
  z.ZodTypeDef,
2158
2158
  unknown
2159
2159
  > = z.object({
2160
- _id: z.string().default("tool_01M5C6JCN3M2FJ3ZX9V3VW7TW0"),
2160
+ _id: z.string().default("tool_01M5CBX79RR2VAPEFTVVQRJSZT"),
2161
2161
  path: z.string(),
2162
2162
  key: z.string(),
2163
2163
  display_name: z.string().optional(),
@@ -1,173 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod/v3";
6
- import { OrqCore } from "../core.js";
7
- import { encodeJSON } from "../lib/encodings.js";
8
- import { matchStatusCode } from "../lib/http.js";
9
- import * as M from "../lib/matchers.js";
10
- import { compactMap } from "../lib/primitives.js";
11
- import { safeParse } from "../lib/schemas.js";
12
- import { RequestOptions } from "../lib/sdks.js";
13
- import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
14
- import { pathToFunc } from "../lib/url.js";
15
- import {
16
- ConnectionError,
17
- InvalidRequestError,
18
- RequestAbortedError,
19
- RequestTimeoutError,
20
- UnexpectedClientError,
21
- } from "../models/errors/httpclienterrors.js";
22
- import * as errors from "../models/errors/index.js";
23
- import { OrqError } from "../models/errors/orqerror.js";
24
- import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
25
- import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
26
- import * as operations from "../models/operations/index.js";
27
- import { APICall, APIPromise } from "../types/async.js";
28
- import { Result } from "../types/fp.js";
29
-
30
- /**
31
- * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
32
- */
33
- export function feedbackCreateEvaluation(
34
- client: OrqCore,
35
- request?: operations.PostV2FeedbackEvaluationRequestBody | undefined,
36
- options?: RequestOptions,
37
- ): APIPromise<
38
- Result<
39
- void,
40
- | errors.ErrorResponse
41
- | OrqError
42
- | ResponseValidationError
43
- | ConnectionError
44
- | RequestAbortedError
45
- | RequestTimeoutError
46
- | InvalidRequestError
47
- | UnexpectedClientError
48
- | SDKValidationError
49
- >
50
- > {
51
- return new APIPromise($do(
52
- client,
53
- request,
54
- options,
55
- ));
56
- }
57
-
58
- async function $do(
59
- client: OrqCore,
60
- request?: operations.PostV2FeedbackEvaluationRequestBody | undefined,
61
- options?: RequestOptions,
62
- ): Promise<
63
- [
64
- Result<
65
- void,
66
- | errors.ErrorResponse
67
- | OrqError
68
- | ResponseValidationError
69
- | ConnectionError
70
- | RequestAbortedError
71
- | RequestTimeoutError
72
- | InvalidRequestError
73
- | UnexpectedClientError
74
- | SDKValidationError
75
- >,
76
- APICall,
77
- ]
78
- > {
79
- const parsed = safeParse(
80
- request,
81
- (value) =>
82
- operations.PostV2FeedbackEvaluationRequestBody$outboundSchema.optional()
83
- .parse(value),
84
- "Input validation failed",
85
- );
86
- if (!parsed.ok) {
87
- return [parsed, { status: "invalid" }];
88
- }
89
- const payload = parsed.value;
90
- const body = payload === undefined
91
- ? null
92
- : encodeJSON("body", payload, { explode: true });
93
-
94
- const path = pathToFunc("/v2/feedback/evaluation")();
95
-
96
- const headers = new Headers(compactMap({
97
- "Content-Type": "application/json",
98
- Accept: "application/json",
99
- }));
100
-
101
- const secConfig = await extractSecurity(client._options.apiKey);
102
- const securityInput = secConfig == null ? {} : { apiKey: secConfig };
103
- const requestSecurity = resolveGlobalSecurity(securityInput);
104
-
105
- const context = {
106
- options: client._options,
107
- baseURL: options?.serverURL ?? client._baseURL ?? "",
108
- operationID: "post_/v2/feedback/evaluation",
109
- oAuth2Scopes: null,
110
-
111
- resolvedSecurity: requestSecurity,
112
-
113
- securitySource: client._options.apiKey,
114
- retryConfig: options?.retries
115
- || client._options.retryConfig
116
- || { strategy: "none" },
117
- retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
118
- };
119
-
120
- const requestRes = client._createRequest(context, {
121
- security: requestSecurity,
122
- method: "POST",
123
- baseURL: options?.serverURL,
124
- path: path,
125
- headers: headers,
126
- body: body,
127
- userAgent: client._options.userAgent,
128
- timeoutMs: options?.timeoutMs || client._options.timeoutMs || 600000,
129
- }, options);
130
- if (!requestRes.ok) {
131
- return [requestRes, { status: "invalid" }];
132
- }
133
- const req = requestRes.value;
134
-
135
- const doResult = await client._do(req, {
136
- context,
137
- isErrorStatusCode: (statusCode: number) =>
138
- matchStatusCode({ status: statusCode } as Response, ["4XX", "5XX"]),
139
- retryConfig: context.retryConfig,
140
- retryCodes: context.retryCodes,
141
- });
142
- if (!doResult.ok) {
143
- return [doResult, { status: "request-error", request: req }];
144
- }
145
- const response = doResult.value;
146
-
147
- const responseFields = {
148
- HttpMeta: { Response: response, Request: req },
149
- };
150
-
151
- const [result] = await M.match<
152
- void,
153
- | errors.ErrorResponse
154
- | OrqError
155
- | ResponseValidationError
156
- | ConnectionError
157
- | RequestAbortedError
158
- | RequestTimeoutError
159
- | InvalidRequestError
160
- | UnexpectedClientError
161
- | SDKValidationError
162
- >(
163
- M.nil(200, z.void()),
164
- M.jsonErr(401, errors.ErrorResponse$inboundSchema),
165
- M.fail("4XX"),
166
- M.fail("5XX"),
167
- )(response, req, { extraFields: responseFields });
168
- if (!result.ok) {
169
- return [result, { status: "complete", request: req, response }];
170
- }
171
-
172
- return [result, { status: "complete", request: req, response }];
173
- }
@@ -1,173 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod/v3";
6
- import { OrqCore } from "../core.js";
7
- import { encodeJSON } from "../lib/encodings.js";
8
- import { matchStatusCode } from "../lib/http.js";
9
- import * as M from "../lib/matchers.js";
10
- import { compactMap } from "../lib/primitives.js";
11
- import { safeParse } from "../lib/schemas.js";
12
- import { RequestOptions } from "../lib/sdks.js";
13
- import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
14
- import { pathToFunc } from "../lib/url.js";
15
- import {
16
- ConnectionError,
17
- InvalidRequestError,
18
- RequestAbortedError,
19
- RequestTimeoutError,
20
- UnexpectedClientError,
21
- } from "../models/errors/httpclienterrors.js";
22
- import * as errors from "../models/errors/index.js";
23
- import { OrqError } from "../models/errors/orqerror.js";
24
- import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
25
- import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
26
- import * as operations from "../models/operations/index.js";
27
- import { APICall, APIPromise } from "../types/async.js";
28
- import { Result } from "../types/fp.js";
29
-
30
- /**
31
- * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
32
- */
33
- export function feedbackRemoveEvaluation(
34
- client: OrqCore,
35
- request?: operations.PostV2FeedbackEvaluationRemoveRequestBody | undefined,
36
- options?: RequestOptions,
37
- ): APIPromise<
38
- Result<
39
- void,
40
- | errors.ErrorResponse
41
- | OrqError
42
- | ResponseValidationError
43
- | ConnectionError
44
- | RequestAbortedError
45
- | RequestTimeoutError
46
- | InvalidRequestError
47
- | UnexpectedClientError
48
- | SDKValidationError
49
- >
50
- > {
51
- return new APIPromise($do(
52
- client,
53
- request,
54
- options,
55
- ));
56
- }
57
-
58
- async function $do(
59
- client: OrqCore,
60
- request?: operations.PostV2FeedbackEvaluationRemoveRequestBody | undefined,
61
- options?: RequestOptions,
62
- ): Promise<
63
- [
64
- Result<
65
- void,
66
- | errors.ErrorResponse
67
- | OrqError
68
- | ResponseValidationError
69
- | ConnectionError
70
- | RequestAbortedError
71
- | RequestTimeoutError
72
- | InvalidRequestError
73
- | UnexpectedClientError
74
- | SDKValidationError
75
- >,
76
- APICall,
77
- ]
78
- > {
79
- const parsed = safeParse(
80
- request,
81
- (value) =>
82
- operations.PostV2FeedbackEvaluationRemoveRequestBody$outboundSchema
83
- .optional().parse(value),
84
- "Input validation failed",
85
- );
86
- if (!parsed.ok) {
87
- return [parsed, { status: "invalid" }];
88
- }
89
- const payload = parsed.value;
90
- const body = payload === undefined
91
- ? null
92
- : encodeJSON("body", payload, { explode: true });
93
-
94
- const path = pathToFunc("/v2/feedback/evaluation/remove")();
95
-
96
- const headers = new Headers(compactMap({
97
- "Content-Type": "application/json",
98
- Accept: "application/json",
99
- }));
100
-
101
- const secConfig = await extractSecurity(client._options.apiKey);
102
- const securityInput = secConfig == null ? {} : { apiKey: secConfig };
103
- const requestSecurity = resolveGlobalSecurity(securityInput);
104
-
105
- const context = {
106
- options: client._options,
107
- baseURL: options?.serverURL ?? client._baseURL ?? "",
108
- operationID: "post_/v2/feedback/evaluation/remove",
109
- oAuth2Scopes: null,
110
-
111
- resolvedSecurity: requestSecurity,
112
-
113
- securitySource: client._options.apiKey,
114
- retryConfig: options?.retries
115
- || client._options.retryConfig
116
- || { strategy: "none" },
117
- retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
118
- };
119
-
120
- const requestRes = client._createRequest(context, {
121
- security: requestSecurity,
122
- method: "POST",
123
- baseURL: options?.serverURL,
124
- path: path,
125
- headers: headers,
126
- body: body,
127
- userAgent: client._options.userAgent,
128
- timeoutMs: options?.timeoutMs || client._options.timeoutMs || 600000,
129
- }, options);
130
- if (!requestRes.ok) {
131
- return [requestRes, { status: "invalid" }];
132
- }
133
- const req = requestRes.value;
134
-
135
- const doResult = await client._do(req, {
136
- context,
137
- isErrorStatusCode: (statusCode: number) =>
138
- matchStatusCode({ status: statusCode } as Response, ["4XX", "5XX"]),
139
- retryConfig: context.retryConfig,
140
- retryCodes: context.retryCodes,
141
- });
142
- if (!doResult.ok) {
143
- return [doResult, { status: "request-error", request: req }];
144
- }
145
- const response = doResult.value;
146
-
147
- const responseFields = {
148
- HttpMeta: { Response: response, Request: req },
149
- };
150
-
151
- const [result] = await M.match<
152
- void,
153
- | errors.ErrorResponse
154
- | OrqError
155
- | ResponseValidationError
156
- | ConnectionError
157
- | RequestAbortedError
158
- | RequestTimeoutError
159
- | InvalidRequestError
160
- | UnexpectedClientError
161
- | SDKValidationError
162
- >(
163
- M.nil(200, z.void()),
164
- M.jsonErr(401, errors.ErrorResponse$inboundSchema),
165
- M.fail("4XX"),
166
- M.fail("5XX"),
167
- )(response, req, { extraFields: responseFields });
168
- if (!result.ok) {
169
- return [result, { status: "complete", request: req, response }];
170
- }
171
-
172
- return [result, { status: "complete", request: req, response }];
173
- }