@orq-ai/node 4.17.0-rc.41 → 4.17.0-rc.44
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.
- package/README.md +77 -81
- package/funcs/humanReviewSetsCreate.d.ts +5 -0
- package/funcs/humanReviewSetsCreate.d.ts.map +1 -1
- package/funcs/humanReviewSetsCreate.js +5 -0
- package/funcs/humanReviewSetsCreate.js.map +1 -1
- package/funcs/humanReviewSetsDelete.d.ts +5 -0
- package/funcs/humanReviewSetsDelete.d.ts.map +1 -1
- package/funcs/humanReviewSetsDelete.js +5 -0
- package/funcs/humanReviewSetsDelete.js.map +1 -1
- package/funcs/humanReviewSetsGet.d.ts +5 -0
- package/funcs/humanReviewSetsGet.d.ts.map +1 -1
- package/funcs/humanReviewSetsGet.js +5 -0
- package/funcs/humanReviewSetsGet.js.map +1 -1
- package/funcs/humanReviewSetsList.d.ts +5 -0
- package/funcs/humanReviewSetsList.d.ts.map +1 -1
- package/funcs/humanReviewSetsList.js +5 -0
- package/funcs/humanReviewSetsList.js.map +1 -1
- package/funcs/humanReviewSetsUpdate.d.ts +5 -0
- package/funcs/humanReviewSetsUpdate.d.ts.map +1 -1
- package/funcs/humanReviewSetsUpdate.js +5 -0
- package/funcs/humanReviewSetsUpdate.js.map +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/models/components/filecontentpartschema.d.ts +1 -1
- package/models/components/publicresponseresource.d.ts +1 -1
- package/models/components/reasoningpart.js +1 -1
- package/models/components/redactresponse.d.ts +1 -1
- package/models/operations/createprompt.d.ts +1 -1
- package/models/operations/createrouterresponse.d.ts +3 -3
- package/models/operations/createtool.js +4 -4
- package/models/operations/deploymentgetconfig.d.ts +1 -1
- package/models/operations/deploymentinvoke.d.ts +5 -5
- package/models/operations/deploymentinvoke.d.ts.map +1 -1
- package/models/operations/deploymentinvoke.js +8 -7
- package/models/operations/deploymentinvoke.js.map +1 -1
- package/models/operations/deployments.d.ts +1 -1
- package/models/operations/deploymentstream.d.ts +5 -5
- package/models/operations/deploymentstream.d.ts.map +1 -1
- package/models/operations/deploymentstream.js +7 -7
- package/models/operations/deploymentstream.js.map +1 -1
- package/models/operations/getallprompts.d.ts +1 -1
- package/models/operations/getalltools.js +4 -4
- package/models/operations/getoneprompt.d.ts +1 -1
- package/models/operations/getpromptversion.d.ts +1 -1
- package/models/operations/getv2humanevalsets.js +2 -2
- package/models/operations/getv2humanevalsetsid.js +2 -2
- package/models/operations/index.d.ts +0 -2
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +0 -2
- package/models/operations/index.js.map +1 -1
- package/models/operations/listdeploymentversions.d.ts +1 -1
- package/models/operations/listdeploymentversions.js +1 -1
- package/models/operations/listpromptversions.d.ts +1 -1
- package/models/operations/patchv2humanevalsetsid.js +2 -2
- package/models/operations/postv2humanevalsets.d.ts +10 -10
- package/models/operations/postv2humanevalsets.d.ts.map +1 -1
- package/models/operations/postv2humanevalsets.js +13 -13
- package/models/operations/postv2humanevalsets.js.map +1 -1
- package/models/operations/retrieveresponse.d.ts +1 -1
- package/models/operations/retrievetool.js +4 -4
- package/models/operations/runagent.js +1 -1
- package/models/operations/streamrunagent.js +1 -1
- package/models/operations/updateprompt.d.ts +1 -1
- package/models/operations/updatetool.js +4 -4
- package/package.json +1 -1
- package/sdk/feedback.d.ts +0 -8
- package/sdk/feedback.d.ts.map +1 -1
- package/sdk/feedback.js +0 -14
- package/sdk/feedback.js.map +1 -1
- package/sdk/humanreviewsets.d.ts +25 -0
- package/sdk/humanreviewsets.d.ts.map +1 -1
- package/sdk/humanreviewsets.js +25 -0
- package/sdk/humanreviewsets.js.map +1 -1
- package/sdk/sdk.d.ts +2 -2
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +3 -3
- package/sdk/sdk.js.map +1 -1
- package/src/funcs/humanReviewSetsCreate.ts +5 -0
- package/src/funcs/humanReviewSetsDelete.ts +5 -0
- package/src/funcs/humanReviewSetsGet.ts +5 -0
- package/src/funcs/humanReviewSetsList.ts +5 -0
- package/src/funcs/humanReviewSetsUpdate.ts +5 -0
- package/src/lib/config.ts +3 -3
- package/src/models/components/filecontentpartschema.ts +1 -1
- package/src/models/components/publicresponseresource.ts +1 -1
- package/src/models/components/reasoningpart.ts +1 -1
- package/src/models/components/redactresponse.ts +1 -1
- package/src/models/operations/createprompt.ts +1 -1
- package/src/models/operations/createrouterresponse.ts +3 -3
- package/src/models/operations/createtool.ts +4 -4
- package/src/models/operations/deploymentgetconfig.ts +1 -1
- package/src/models/operations/deploymentinvoke.ts +15 -18
- package/src/models/operations/deployments.ts +1 -1
- package/src/models/operations/deploymentstream.ts +11 -14
- package/src/models/operations/getallprompts.ts +1 -1
- package/src/models/operations/getalltools.ts +4 -4
- package/src/models/operations/getoneprompt.ts +1 -1
- package/src/models/operations/getpromptversion.ts +1 -1
- package/src/models/operations/getv2humanevalsets.ts +2 -2
- package/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/src/models/operations/index.ts +0 -2
- package/src/models/operations/listdeploymentversions.ts +2 -2
- package/src/models/operations/listpromptversions.ts +1 -1
- package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/src/models/operations/postv2humanevalsets.ts +21 -35
- package/src/models/operations/retrieveresponse.ts +1 -1
- package/src/models/operations/retrievetool.ts +4 -4
- package/src/models/operations/runagent.ts +1 -1
- package/src/models/operations/streamrunagent.ts +1 -1
- package/src/models/operations/updateprompt.ts +1 -1
- package/src/models/operations/updatetool.ts +4 -4
- package/src/sdk/feedback.ts +0 -30
- package/src/sdk/humanreviewsets.ts +25 -0
- package/src/sdk/sdk.ts +5 -5
- package/funcs/feedbackCreateEvaluation.d.ts +0 -15
- package/funcs/feedbackCreateEvaluation.d.ts.map +0 -1
- package/funcs/feedbackCreateEvaluation.js +0 -120
- package/funcs/feedbackCreateEvaluation.js.map +0 -1
- package/funcs/feedbackRemoveEvaluation.d.ts +0 -15
- package/funcs/feedbackRemoveEvaluation.d.ts.map +0 -1
- package/funcs/feedbackRemoveEvaluation.js +0 -120
- package/funcs/feedbackRemoveEvaluation.js.map +0 -1
- package/models/operations/postv2feedbackevaluation.d.ts +0 -257
- package/models/operations/postv2feedbackevaluation.d.ts.map +0 -1
- package/models/operations/postv2feedbackevaluation.js +0 -210
- package/models/operations/postv2feedbackevaluation.js.map +0 -1
- package/models/operations/postv2feedbackevaluationremove.d.ts +0 -14
- package/models/operations/postv2feedbackevaluationremove.d.ts.map +0 -1
- package/models/operations/postv2feedbackevaluationremove.js +0 -55
- package/models/operations/postv2feedbackevaluationremove.js.map +0 -1
- package/src/funcs/feedbackCreateEvaluation.ts +0 -173
- package/src/funcs/feedbackRemoveEvaluation.ts +0 -173
- package/src/models/operations/postv2feedbackevaluation.ts +0 -453
- package/src/models/operations/postv2feedbackevaluationremove.ts +0 -43
|
@@ -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
|
-
}
|