@orq-ai/node 4.9.3 → 4.9.6
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/jsr.json +1 -1
- package/langchain/async-handler.d.mts.map +1 -1
- package/langchain/async-handler.mjs +8 -11
- package/langchain/async-handler.mjs.map +1 -1
- package/langchain/events.d.mts.map +1 -1
- package/langchain/events.mjs +12 -0
- package/langchain/events.mjs.map +1 -1
- package/langchain/handler.d.mts.map +1 -1
- package/langchain/handler.mjs +8 -11
- package/langchain/handler.mjs.map +1 -1
- package/langchain/span-builder.mjs +3 -3
- package/langchain/span-builder.mjs.map +1 -1
- package/langchain/utils.d.mts.map +1 -1
- package/langchain/utils.mjs +115 -0
- package/langchain/utils.mjs.map +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/models/components/reasoningpart.js +1 -1
- package/models/operations/createcontact.js +1 -1
- package/models/operations/createdataset.js +1 -1
- package/models/operations/createdatasetitem.js +4 -4
- package/models/operations/createdatasource.js +1 -1
- package/models/operations/createeval.js +16 -16
- package/models/operations/createidentity.js +1 -1
- package/models/operations/createrouterresponse.d.ts +6 -11
- package/models/operations/createrouterresponse.d.ts.map +1 -1
- package/models/operations/createrouterresponse.js +2 -8
- package/models/operations/createrouterresponse.js.map +1 -1
- package/models/operations/createtool.js +6 -6
- package/models/operations/getalltools.js +6 -6
- package/models/operations/getevals.js +16 -16
- package/models/operations/getv2humanevalsets.js +2 -2
- package/models/operations/getv2humanevalsetsid.js +2 -2
- package/models/operations/listdatasetdatapoints.js +4 -4
- package/models/operations/listdatasets.js +1 -1
- package/models/operations/listdatasources.js +1 -1
- package/models/operations/listidentities.js +1 -1
- package/models/operations/patchv2humanevalsetsid.js +2 -2
- package/models/operations/postv2feedbackevaluation.js +3 -3
- package/models/operations/postv2humanevalsets.js +2 -2
- package/models/operations/retrievedatapoint.js +4 -4
- package/models/operations/retrievedataset.js +1 -1
- package/models/operations/retrievedatasource.js +1 -1
- package/models/operations/retrieveidentity.js +1 -1
- package/models/operations/retrievetool.js +6 -6
- package/models/operations/runagent.js +1 -1
- package/models/operations/streamrunagent.js +1 -1
- package/models/operations/updatedatapoint.js +4 -4
- package/models/operations/updatedataset.js +1 -1
- package/models/operations/updatedatasource.js +1 -1
- package/models/operations/updateeval.js +16 -16
- package/models/operations/updateidentity.js +1 -1
- package/models/operations/updatetool.js +7 -7
- package/package.json +7 -7
- package/packages/orq-rc/src/funcs/identitiesCreate.ts +10 -15
- package/packages/orq-rc/src/funcs/identitiesDelete.ts +7 -16
- package/packages/orq-rc/src/funcs/identitiesList.ts +6 -5
- package/packages/orq-rc/src/funcs/identitiesRetrieve.ts +6 -18
- package/packages/orq-rc/src/funcs/identitiesUpdate.ts +9 -15
- package/packages/orq-rc/src/funcs/projectsCreate.ts +1 -1
- package/packages/orq-rc/src/funcs/projectsDelete.ts +3 -0
- package/packages/orq-rc/src/funcs/projectsList.ts +1 -1
- package/packages/orq-rc/src/funcs/{contactsCreate.ts → reportingQuery.ts} +13 -13
- package/packages/orq-rc/src/funcs/skillsCreate.ts +1 -1
- package/packages/orq-rc/src/funcs/skillsDelete.ts +3 -0
- package/packages/orq-rc/src/funcs/skillsGet.ts +1 -1
- package/packages/orq-rc/src/funcs/skillsList.ts +1 -1
- package/packages/orq-rc/src/funcs/skillsUpdate.ts +1 -1
- package/packages/orq-rc/src/lib/config.ts +3 -3
- package/packages/orq-rc/src/models/components/createidentityrequest.ts +76 -0
- package/packages/orq-rc/src/models/components/createidentityresponse.ts +32 -0
- package/packages/orq-rc/src/models/components/createprojectrequest.ts +6 -0
- package/packages/orq-rc/src/models/components/createprojectresponse.ts +3 -0
- package/packages/orq-rc/src/models/components/createskillrequest.ts +18 -0
- package/packages/orq-rc/src/models/components/createskillresponse.ts +3 -0
- package/packages/orq-rc/src/models/components/datapoint.ts +60 -0
- package/packages/orq-rc/src/models/components/deleteidentityresponse.ts +27 -0
- package/packages/orq-rc/src/models/components/file.ts +0 -3
- package/packages/orq-rc/src/models/components/filter.ts +137 -0
- package/packages/orq-rc/src/models/components/getprojectresponse.ts +3 -0
- package/packages/orq-rc/src/models/components/getskillresponse.ts +3 -0
- package/packages/orq-rc/src/models/components/identity.ts +83 -0
- package/packages/orq-rc/src/models/components/identitymetrics.ts +45 -0
- package/packages/orq-rc/src/models/components/index.ts +15 -0
- package/packages/orq-rc/src/models/components/invokedeploymentrequest.ts +17 -10
- package/packages/orq-rc/src/models/components/listidentitiesresponse.ts +41 -0
- package/packages/orq-rc/src/models/components/listprojectsresponse.ts +12 -0
- package/packages/orq-rc/src/models/components/listskillsresponse.ts +12 -0
- package/packages/orq-rc/src/models/components/modelref.ts +6 -0
- package/packages/orq-rc/src/models/components/project.ts +42 -3
- package/packages/orq-rc/src/models/components/queryreportrequest.ts +237 -0
- package/packages/orq-rc/src/models/components/queryreportresponse.ts +96 -0
- package/packages/orq-rc/src/models/components/reasoningpart.ts +1 -1
- package/packages/orq-rc/src/models/components/responsemeta.ts +103 -0
- package/packages/orq-rc/src/models/components/retrieveidentityresponse.ts +32 -0
- package/packages/orq-rc/src/models/components/skill.ts +37 -3
- package/packages/orq-rc/src/models/components/totals.ts +34 -0
- package/packages/orq-rc/src/models/components/updateidentityrequest.ts +75 -0
- package/packages/orq-rc/src/models/components/updateidentityresponse.ts +32 -0
- package/packages/orq-rc/src/models/components/updateprojectrequest.ts +12 -0
- package/packages/orq-rc/src/models/components/updateprojectresponse.ts +3 -0
- package/packages/orq-rc/src/models/components/updateskillrequest.ts +21 -0
- package/packages/orq-rc/src/models/components/updateskillresponse.ts +3 -0
- package/packages/orq-rc/src/models/errors/index.ts +0 -3
- package/packages/orq-rc/src/models/operations/createagentrequest.ts +3 -3
- package/packages/orq-rc/src/models/operations/createannotation.ts +7 -11
- package/packages/orq-rc/src/models/operations/createdataset.ts +4 -4
- package/packages/orq-rc/src/models/operations/createdatasetitem.ts +4 -4
- package/packages/orq-rc/src/models/operations/createdatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/createeval.ts +31 -31
- package/packages/orq-rc/src/models/operations/createknowledge.ts +9 -9
- package/packages/orq-rc/src/models/operations/creatememorystore.ts +3 -3
- package/packages/orq-rc/src/models/operations/createprompt.ts +3 -3
- package/packages/orq-rc/src/models/operations/createrouterresponse.ts +3 -24
- package/packages/orq-rc/src/models/operations/createtool.ts +36 -36
- package/packages/orq-rc/src/models/operations/deleteidentity.ts +0 -3
- package/packages/orq-rc/src/models/operations/getalltools.ts +21 -21
- package/packages/orq-rc/src/models/operations/getevals.ts +16 -16
- package/packages/orq-rc/src/models/operations/getoneknowledge.ts +6 -6
- package/packages/orq-rc/src/models/operations/getv2humanevalsets.ts +2 -2
- package/packages/orq-rc/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/packages/orq-rc/src/models/operations/index.ts +0 -3
- package/packages/orq-rc/src/models/operations/invokeeval.ts +83 -80
- package/packages/orq-rc/src/models/operations/listagents.ts +3 -3
- package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +4 -4
- package/packages/orq-rc/src/models/operations/listdatasets.ts +1 -1
- package/packages/orq-rc/src/models/operations/listdatasources.ts +1 -1
- package/packages/orq-rc/src/models/operations/listidentities.ts +9 -230
- package/packages/orq-rc/src/models/operations/listknowledgebases.ts +6 -6
- package/packages/orq-rc/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/packages/orq-rc/src/models/operations/postv2agentsa2a.ts +14 -17
- package/packages/orq-rc/src/models/operations/postv2feedback.ts +34 -27
- package/packages/orq-rc/src/models/operations/postv2feedbackevaluation.ts +3 -3
- package/packages/orq-rc/src/models/operations/postv2feedbackremove.ts +14 -17
- package/packages/orq-rc/src/models/operations/postv2humanevalsets.ts +2 -2
- package/packages/orq-rc/src/models/operations/projectdelete.ts +3 -0
- package/packages/orq-rc/src/models/operations/projectget.ts +3 -0
- package/packages/orq-rc/src/models/operations/projectlist.ts +15 -0
- package/packages/orq-rc/src/models/operations/projectupdate.ts +3 -0
- package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +3 -3
- package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +4 -4
- package/packages/orq-rc/src/models/operations/retrievedataset.ts +1 -1
- package/packages/orq-rc/src/models/operations/retrievedatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/retrieveidentity.ts +3 -138
- package/packages/orq-rc/src/models/operations/retrievetool.ts +21 -21
- package/packages/orq-rc/src/models/operations/runagent.ts +4 -4
- package/packages/orq-rc/src/models/operations/skilldelete.ts +3 -0
- package/packages/orq-rc/src/models/operations/skilllist.ts +12 -0
- package/packages/orq-rc/src/models/operations/skillupdate.ts +3 -0
- package/packages/orq-rc/src/models/operations/streamrunagent.ts +4 -4
- package/packages/orq-rc/src/models/operations/updateagent.ts +6 -6
- package/packages/orq-rc/src/models/operations/updatedatapoint.ts +4 -4
- package/packages/orq-rc/src/models/operations/updatedataset.ts +4 -4
- package/packages/orq-rc/src/models/operations/updatedatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/updateeval.ts +16 -16
- package/packages/orq-rc/src/models/operations/updateidentity.ts +5 -154
- package/packages/orq-rc/src/models/operations/updateknowledge.ts +12 -12
- package/packages/orq-rc/src/models/operations/updateprompt.ts +3 -3
- package/packages/orq-rc/src/models/operations/updatetool.ts +37 -37
- package/packages/orq-rc/src/sdk/feedback.ts +8 -8
- package/packages/orq-rc/src/sdk/identities.ts +18 -17
- package/packages/orq-rc/src/sdk/projects.ts +5 -2
- package/packages/orq-rc/src/sdk/reporting.ts +27 -0
- package/packages/orq-rc/src/sdk/sdk.ts +16 -22
- package/packages/orq-rc/src/sdk/skills.ts +7 -4
- package/src/lib/config.ts +3 -3
- package/src/models/components/reasoningpart.ts +1 -1
- package/src/models/operations/createcontact.ts +1 -1
- package/src/models/operations/createdataset.ts +1 -1
- package/src/models/operations/createdatasetitem.ts +4 -4
- package/src/models/operations/createdatasource.ts +1 -1
- package/src/models/operations/createeval.ts +16 -16
- package/src/models/operations/createidentity.ts +1 -1
- package/src/models/operations/createrouterresponse.ts +3 -24
- package/src/models/operations/createtool.ts +6 -6
- package/src/models/operations/getalltools.ts +6 -6
- package/src/models/operations/getevals.ts +16 -16
- package/src/models/operations/getv2humanevalsets.ts +2 -2
- package/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/src/models/operations/listdatasetdatapoints.ts +4 -4
- package/src/models/operations/listdatasets.ts +1 -1
- package/src/models/operations/listdatasources.ts +1 -1
- package/src/models/operations/listidentities.ts +1 -1
- package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/src/models/operations/postv2feedbackevaluation.ts +3 -3
- package/src/models/operations/postv2humanevalsets.ts +2 -2
- package/src/models/operations/retrievedatapoint.ts +4 -4
- package/src/models/operations/retrievedataset.ts +1 -1
- package/src/models/operations/retrievedatasource.ts +1 -1
- package/src/models/operations/retrieveidentity.ts +1 -1
- package/src/models/operations/retrievetool.ts +6 -6
- package/src/models/operations/runagent.ts +1 -1
- package/src/models/operations/streamrunagent.ts +1 -1
- package/src/models/operations/updatedatapoint.ts +4 -4
- package/src/models/operations/updatedataset.ts +1 -1
- package/src/models/operations/updatedatasource.ts +1 -1
- package/src/models/operations/updateeval.ts +16 -16
- package/src/models/operations/updateidentity.ts +1 -1
- package/src/models/operations/updatetool.ts +7 -7
- package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -163
- package/packages/orq-rc/src/models/errors/deleteidentity.ts +0 -62
- package/packages/orq-rc/src/models/errors/retrieveidentity.ts +0 -118
- package/packages/orq-rc/src/models/errors/updateidentity.ts +0 -54
- package/packages/orq-rc/src/models/operations/createcontact.ts +0 -156
- package/packages/orq-rc/src/models/operations/createidentity.ts +0 -162
- package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -108
- package/packages/orq-rc/src/sdk/contacts.ts +0 -27
- package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
|
@@ -11,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
11
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
12
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
14
15
|
import {
|
|
15
16
|
ConnectionError,
|
|
16
17
|
InvalidRequestError,
|
|
@@ -21,7 +22,6 @@ import {
|
|
|
21
22
|
import { OrqError } from "../models/errors/orqerror.js";
|
|
22
23
|
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
23
24
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
-
import * as operations from "../models/operations/index.js";
|
|
25
25
|
import { APICall, APIPromise } from "../types/async.js";
|
|
26
26
|
import { Result } from "../types/fp.js";
|
|
27
27
|
|
|
@@ -29,15 +29,15 @@ import { Result } from "../types/fp.js";
|
|
|
29
29
|
* Create an identity
|
|
30
30
|
*
|
|
31
31
|
* @remarks
|
|
32
|
-
* Creates a new identity with a unique external_id. If an identity with the same external_id already exists, the operation will fail.
|
|
32
|
+
* Creates a new identity with a unique external_id. If an identity with the same external_id already exists, the operation will fail.
|
|
33
33
|
*/
|
|
34
34
|
export function identitiesCreate(
|
|
35
35
|
client: OrqCore,
|
|
36
|
-
request
|
|
36
|
+
request: components.CreateIdentityRequest,
|
|
37
37
|
options?: RequestOptions,
|
|
38
38
|
): APIPromise<
|
|
39
39
|
Result<
|
|
40
|
-
|
|
40
|
+
components.CreateIdentityResponse,
|
|
41
41
|
| OrqError
|
|
42
42
|
| ResponseValidationError
|
|
43
43
|
| ConnectionError
|
|
@@ -57,12 +57,12 @@ export function identitiesCreate(
|
|
|
57
57
|
|
|
58
58
|
async function $do(
|
|
59
59
|
client: OrqCore,
|
|
60
|
-
request
|
|
60
|
+
request: components.CreateIdentityRequest,
|
|
61
61
|
options?: RequestOptions,
|
|
62
62
|
): Promise<
|
|
63
63
|
[
|
|
64
64
|
Result<
|
|
65
|
-
|
|
65
|
+
components.CreateIdentityResponse,
|
|
66
66
|
| OrqError
|
|
67
67
|
| ResponseValidationError
|
|
68
68
|
| ConnectionError
|
|
@@ -77,19 +77,14 @@ async function $do(
|
|
|
77
77
|
> {
|
|
78
78
|
const parsed = safeParse(
|
|
79
79
|
request,
|
|
80
|
-
(value) =>
|
|
81
|
-
operations.CreateIdentityRequestBody$outboundSchema.optional().parse(
|
|
82
|
-
value,
|
|
83
|
-
),
|
|
80
|
+
(value) => components.CreateIdentityRequest$outboundSchema.parse(value),
|
|
84
81
|
"Input validation failed",
|
|
85
82
|
);
|
|
86
83
|
if (!parsed.ok) {
|
|
87
84
|
return [parsed, { status: "invalid" }];
|
|
88
85
|
}
|
|
89
86
|
const payload = parsed.value;
|
|
90
|
-
const body = payload
|
|
91
|
-
? null
|
|
92
|
-
: encodeJSON("body", payload, { explode: true });
|
|
87
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
93
88
|
|
|
94
89
|
const path = pathToFunc("/v2/identities")();
|
|
95
90
|
|
|
@@ -145,7 +140,7 @@ async function $do(
|
|
|
145
140
|
const response = doResult.value;
|
|
146
141
|
|
|
147
142
|
const [result] = await M.match<
|
|
148
|
-
|
|
143
|
+
components.CreateIdentityResponse,
|
|
149
144
|
| OrqError
|
|
150
145
|
| ResponseValidationError
|
|
151
146
|
| ConnectionError
|
|
@@ -155,7 +150,7 @@ async function $do(
|
|
|
155
150
|
| UnexpectedClientError
|
|
156
151
|
| SDKValidationError
|
|
157
152
|
>(
|
|
158
|
-
M.json(
|
|
153
|
+
M.json(200, components.CreateIdentityResponse$inboundSchema),
|
|
159
154
|
M.fail("4XX"),
|
|
160
155
|
M.fail("5XX"),
|
|
161
156
|
)(response, req);
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
import * as z from "zod/v3";
|
|
6
5
|
import { OrqCore } from "../core.js";
|
|
7
6
|
import { encodeSimple } from "../lib/encodings.js";
|
|
8
7
|
import { matchStatusCode } from "../lib/http.js";
|
|
@@ -12,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
12
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
13
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
14
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
15
15
|
import {
|
|
16
16
|
ConnectionError,
|
|
17
17
|
InvalidRequestError,
|
|
@@ -19,7 +19,6 @@ import {
|
|
|
19
19
|
RequestTimeoutError,
|
|
20
20
|
UnexpectedClientError,
|
|
21
21
|
} from "../models/errors/httpclienterrors.js";
|
|
22
|
-
import * as errors from "../models/errors/index.js";
|
|
23
22
|
import { OrqError } from "../models/errors/orqerror.js";
|
|
24
23
|
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
25
24
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
@@ -31,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
31
30
|
* Delete an identity
|
|
32
31
|
*
|
|
33
32
|
* @remarks
|
|
34
|
-
* Permanently deletes an identity from your workspace and cleans up associated budget configurations.
|
|
33
|
+
* Permanently deletes an identity from your workspace and cleans up associated budget configurations.
|
|
35
34
|
*/
|
|
36
35
|
export function identitiesDelete(
|
|
37
36
|
client: OrqCore,
|
|
@@ -39,8 +38,7 @@ export function identitiesDelete(
|
|
|
39
38
|
options?: RequestOptions,
|
|
40
39
|
): APIPromise<
|
|
41
40
|
Result<
|
|
42
|
-
|
|
43
|
-
| errors.DeleteIdentityResponseBody
|
|
41
|
+
components.DeleteIdentityResponse,
|
|
44
42
|
| OrqError
|
|
45
43
|
| ResponseValidationError
|
|
46
44
|
| ConnectionError
|
|
@@ -65,8 +63,7 @@ async function $do(
|
|
|
65
63
|
): Promise<
|
|
66
64
|
[
|
|
67
65
|
Result<
|
|
68
|
-
|
|
69
|
-
| errors.DeleteIdentityResponseBody
|
|
66
|
+
components.DeleteIdentityResponse,
|
|
70
67
|
| OrqError
|
|
71
68
|
| ResponseValidationError
|
|
72
69
|
| ConnectionError
|
|
@@ -148,13 +145,8 @@ async function $do(
|
|
|
148
145
|
}
|
|
149
146
|
const response = doResult.value;
|
|
150
147
|
|
|
151
|
-
const responseFields = {
|
|
152
|
-
HttpMeta: { Response: response, Request: req },
|
|
153
|
-
};
|
|
154
|
-
|
|
155
148
|
const [result] = await M.match<
|
|
156
|
-
|
|
157
|
-
| errors.DeleteIdentityResponseBody
|
|
149
|
+
components.DeleteIdentityResponse,
|
|
158
150
|
| OrqError
|
|
159
151
|
| ResponseValidationError
|
|
160
152
|
| ConnectionError
|
|
@@ -164,11 +156,10 @@ async function $do(
|
|
|
164
156
|
| UnexpectedClientError
|
|
165
157
|
| SDKValidationError
|
|
166
158
|
>(
|
|
167
|
-
M.
|
|
168
|
-
M.jsonErr(404, errors.DeleteIdentityResponseBody$inboundSchema),
|
|
159
|
+
M.json(200, components.DeleteIdentityResponse$inboundSchema),
|
|
169
160
|
M.fail("4XX"),
|
|
170
161
|
M.fail("5XX"),
|
|
171
|
-
)(response, req
|
|
162
|
+
)(response, req);
|
|
172
163
|
if (!result.ok) {
|
|
173
164
|
return [result, { status: "complete", request: req, response }];
|
|
174
165
|
}
|
|
@@ -11,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
11
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
12
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
14
15
|
import {
|
|
15
16
|
ConnectionError,
|
|
16
17
|
InvalidRequestError,
|
|
@@ -37,7 +38,7 @@ export function identitiesList(
|
|
|
37
38
|
options?: RequestOptions,
|
|
38
39
|
): APIPromise<
|
|
39
40
|
Result<
|
|
40
|
-
|
|
41
|
+
components.ListIdentitiesResponse,
|
|
41
42
|
| OrqError
|
|
42
43
|
| ResponseValidationError
|
|
43
44
|
| ConnectionError
|
|
@@ -62,7 +63,7 @@ async function $do(
|
|
|
62
63
|
): Promise<
|
|
63
64
|
[
|
|
64
65
|
Result<
|
|
65
|
-
|
|
66
|
+
components.ListIdentitiesResponse,
|
|
66
67
|
| OrqError
|
|
67
68
|
| ResponseValidationError
|
|
68
69
|
| ConnectionError
|
|
@@ -91,7 +92,7 @@ async function $do(
|
|
|
91
92
|
|
|
92
93
|
const query = encodeFormQuery({
|
|
93
94
|
"ending_before": payload?.ending_before,
|
|
94
|
-
"filter_by": payload?.filter_by,
|
|
95
|
+
"filter_by.tags": payload?.["filter_by.tags"],
|
|
95
96
|
"include_metrics": payload?.include_metrics,
|
|
96
97
|
"limit": payload?.limit,
|
|
97
98
|
"search": payload?.search,
|
|
@@ -150,7 +151,7 @@ async function $do(
|
|
|
150
151
|
const response = doResult.value;
|
|
151
152
|
|
|
152
153
|
const [result] = await M.match<
|
|
153
|
-
|
|
154
|
+
components.ListIdentitiesResponse,
|
|
154
155
|
| OrqError
|
|
155
156
|
| ResponseValidationError
|
|
156
157
|
| ConnectionError
|
|
@@ -160,7 +161,7 @@ async function $do(
|
|
|
160
161
|
| UnexpectedClientError
|
|
161
162
|
| SDKValidationError
|
|
162
163
|
>(
|
|
163
|
-
M.json(200,
|
|
164
|
+
M.json(200, components.ListIdentitiesResponse$inboundSchema),
|
|
164
165
|
M.fail("4XX"),
|
|
165
166
|
M.fail("5XX"),
|
|
166
167
|
)(response, req);
|
|
@@ -11,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
11
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
12
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
14
15
|
import {
|
|
15
16
|
ConnectionError,
|
|
16
17
|
InvalidRequestError,
|
|
@@ -18,7 +19,6 @@ import {
|
|
|
18
19
|
RequestTimeoutError,
|
|
19
20
|
UnexpectedClientError,
|
|
20
21
|
} from "../models/errors/httpclienterrors.js";
|
|
21
|
-
import * as errors from "../models/errors/index.js";
|
|
22
22
|
import { OrqError } from "../models/errors/orqerror.js";
|
|
23
23
|
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
24
24
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
@@ -38,9 +38,7 @@ export function identitiesRetrieve(
|
|
|
38
38
|
options?: RequestOptions,
|
|
39
39
|
): APIPromise<
|
|
40
40
|
Result<
|
|
41
|
-
|
|
42
|
-
| errors.RetrieveIdentityResponseBody
|
|
43
|
-
| errors.RetrieveIdentityIdentitiesResponseBody
|
|
41
|
+
components.RetrieveIdentityResponse,
|
|
44
42
|
| OrqError
|
|
45
43
|
| ResponseValidationError
|
|
46
44
|
| ConnectionError
|
|
@@ -65,9 +63,7 @@ async function $do(
|
|
|
65
63
|
): Promise<
|
|
66
64
|
[
|
|
67
65
|
Result<
|
|
68
|
-
|
|
69
|
-
| errors.RetrieveIdentityResponseBody
|
|
70
|
-
| errors.RetrieveIdentityIdentitiesResponseBody
|
|
66
|
+
components.RetrieveIdentityResponse,
|
|
71
67
|
| OrqError
|
|
72
68
|
| ResponseValidationError
|
|
73
69
|
| ConnectionError
|
|
@@ -154,14 +150,8 @@ async function $do(
|
|
|
154
150
|
}
|
|
155
151
|
const response = doResult.value;
|
|
156
152
|
|
|
157
|
-
const responseFields = {
|
|
158
|
-
HttpMeta: { Response: response, Request: req },
|
|
159
|
-
};
|
|
160
|
-
|
|
161
153
|
const [result] = await M.match<
|
|
162
|
-
|
|
163
|
-
| errors.RetrieveIdentityResponseBody
|
|
164
|
-
| errors.RetrieveIdentityIdentitiesResponseBody
|
|
154
|
+
components.RetrieveIdentityResponse,
|
|
165
155
|
| OrqError
|
|
166
156
|
| ResponseValidationError
|
|
167
157
|
| ConnectionError
|
|
@@ -171,12 +161,10 @@ async function $do(
|
|
|
171
161
|
| UnexpectedClientError
|
|
172
162
|
| SDKValidationError
|
|
173
163
|
>(
|
|
174
|
-
M.json(200,
|
|
175
|
-
M.jsonErr(404, errors.RetrieveIdentityResponseBody$inboundSchema),
|
|
176
|
-
M.jsonErr(500, errors.RetrieveIdentityIdentitiesResponseBody$inboundSchema),
|
|
164
|
+
M.json(200, components.RetrieveIdentityResponse$inboundSchema),
|
|
177
165
|
M.fail("4XX"),
|
|
178
166
|
M.fail("5XX"),
|
|
179
|
-
)(response, req
|
|
167
|
+
)(response, req);
|
|
180
168
|
if (!result.ok) {
|
|
181
169
|
return [result, { status: "complete", request: req, response }];
|
|
182
170
|
}
|
|
@@ -11,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
11
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
12
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
14
15
|
import {
|
|
15
16
|
ConnectionError,
|
|
16
17
|
InvalidRequestError,
|
|
@@ -18,7 +19,6 @@ import {
|
|
|
18
19
|
RequestTimeoutError,
|
|
19
20
|
UnexpectedClientError,
|
|
20
21
|
} from "../models/errors/httpclienterrors.js";
|
|
21
|
-
import * as errors from "../models/errors/index.js";
|
|
22
22
|
import { OrqError } from "../models/errors/orqerror.js";
|
|
23
23
|
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
24
24
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
@@ -38,8 +38,7 @@ export function identitiesUpdate(
|
|
|
38
38
|
options?: RequestOptions,
|
|
39
39
|
): APIPromise<
|
|
40
40
|
Result<
|
|
41
|
-
|
|
42
|
-
| errors.UpdateIdentityResponseBody
|
|
41
|
+
components.UpdateIdentityResponse,
|
|
43
42
|
| OrqError
|
|
44
43
|
| ResponseValidationError
|
|
45
44
|
| ConnectionError
|
|
@@ -64,8 +63,7 @@ async function $do(
|
|
|
64
63
|
): Promise<
|
|
65
64
|
[
|
|
66
65
|
Result<
|
|
67
|
-
|
|
68
|
-
| errors.UpdateIdentityResponseBody
|
|
66
|
+
components.UpdateIdentityResponse,
|
|
69
67
|
| OrqError
|
|
70
68
|
| ResponseValidationError
|
|
71
69
|
| ConnectionError
|
|
@@ -87,7 +85,9 @@ async function $do(
|
|
|
87
85
|
return [parsed, { status: "invalid" }];
|
|
88
86
|
}
|
|
89
87
|
const payload = parsed.value;
|
|
90
|
-
const body = encodeJSON("body", payload.
|
|
88
|
+
const body = encodeJSON("body", payload.UpdateIdentityRequest, {
|
|
89
|
+
explode: true,
|
|
90
|
+
});
|
|
91
91
|
|
|
92
92
|
const pathParams = {
|
|
93
93
|
id: encodeSimple("id", payload.id, {
|
|
@@ -148,13 +148,8 @@ async function $do(
|
|
|
148
148
|
}
|
|
149
149
|
const response = doResult.value;
|
|
150
150
|
|
|
151
|
-
const responseFields = {
|
|
152
|
-
HttpMeta: { Response: response, Request: req },
|
|
153
|
-
};
|
|
154
|
-
|
|
155
151
|
const [result] = await M.match<
|
|
156
|
-
|
|
157
|
-
| errors.UpdateIdentityResponseBody
|
|
152
|
+
components.UpdateIdentityResponse,
|
|
158
153
|
| OrqError
|
|
159
154
|
| ResponseValidationError
|
|
160
155
|
| ConnectionError
|
|
@@ -164,11 +159,10 @@ async function $do(
|
|
|
164
159
|
| UnexpectedClientError
|
|
165
160
|
| SDKValidationError
|
|
166
161
|
>(
|
|
167
|
-
M.json(200,
|
|
168
|
-
M.jsonErr(404, errors.UpdateIdentityResponseBody$inboundSchema),
|
|
162
|
+
M.json(200, components.UpdateIdentityResponse$inboundSchema),
|
|
169
163
|
M.fail("4XX"),
|
|
170
164
|
M.fail("5XX"),
|
|
171
|
-
)(response, req
|
|
165
|
+
)(response, req);
|
|
172
166
|
if (!result.ok) {
|
|
173
167
|
return [result, { status: "complete", request: req, response }];
|
|
174
168
|
}
|
|
@@ -29,7 +29,7 @@ import { Result } from "../types/fp.js";
|
|
|
29
29
|
* Create a new project
|
|
30
30
|
*
|
|
31
31
|
* @remarks
|
|
32
|
-
* Creates a
|
|
32
|
+
* Creates a project in the current workspace. Projects are workspace-level containers for resources such as skills, deployments, datasets, rules, and related team access.
|
|
33
33
|
*/
|
|
34
34
|
export function projectsCreate(
|
|
35
35
|
client: OrqCore,
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* List all projects
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Returns
|
|
33
|
+
* Returns projects visible to the current workspace, ordered by creation time with the newest project first. Use `starting_after` or `ending_before` to page through large collections.
|
|
34
34
|
*/
|
|
35
35
|
export function projectsList(
|
|
36
36
|
client: OrqCore,
|
|
@@ -11,6 +11,7 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
11
11
|
import { RequestOptions } from "../lib/sdks.js";
|
|
12
12
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
13
|
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
14
15
|
import {
|
|
15
16
|
ConnectionError,
|
|
16
17
|
InvalidRequestError,
|
|
@@ -21,23 +22,22 @@ import {
|
|
|
21
22
|
import { OrqError } from "../models/errors/orqerror.js";
|
|
22
23
|
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
23
24
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
-
import * as operations from "../models/operations/index.js";
|
|
25
25
|
import { APICall, APIPromise } from "../types/async.js";
|
|
26
26
|
import { Result } from "../types/fp.js";
|
|
27
27
|
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* Query reporting metrics
|
|
30
30
|
*
|
|
31
31
|
* @remarks
|
|
32
|
-
*
|
|
32
|
+
* Returns time-series analytics for AI usage, cost, latency, evaluator results, and guardrail outcomes. Select a metric and time range, break results down by supported dimensions, apply filters, and optionally include totals for the full range.
|
|
33
33
|
*/
|
|
34
|
-
export function
|
|
34
|
+
export function reportingQuery(
|
|
35
35
|
client: OrqCore,
|
|
36
|
-
request:
|
|
36
|
+
request: components.QueryReportRequest,
|
|
37
37
|
options?: RequestOptions,
|
|
38
38
|
): APIPromise<
|
|
39
39
|
Result<
|
|
40
|
-
|
|
40
|
+
components.QueryReportResponse,
|
|
41
41
|
| OrqError
|
|
42
42
|
| ResponseValidationError
|
|
43
43
|
| ConnectionError
|
|
@@ -57,12 +57,12 @@ export function contactsCreate(
|
|
|
57
57
|
|
|
58
58
|
async function $do(
|
|
59
59
|
client: OrqCore,
|
|
60
|
-
request:
|
|
60
|
+
request: components.QueryReportRequest,
|
|
61
61
|
options?: RequestOptions,
|
|
62
62
|
): Promise<
|
|
63
63
|
[
|
|
64
64
|
Result<
|
|
65
|
-
|
|
65
|
+
components.QueryReportResponse,
|
|
66
66
|
| OrqError
|
|
67
67
|
| ResponseValidationError
|
|
68
68
|
| ConnectionError
|
|
@@ -77,7 +77,7 @@ async function $do(
|
|
|
77
77
|
> {
|
|
78
78
|
const parsed = safeParse(
|
|
79
79
|
request,
|
|
80
|
-
(value) =>
|
|
80
|
+
(value) => components.QueryReportRequest$outboundSchema.parse(value),
|
|
81
81
|
"Input validation failed",
|
|
82
82
|
);
|
|
83
83
|
if (!parsed.ok) {
|
|
@@ -86,7 +86,7 @@ async function $do(
|
|
|
86
86
|
const payload = parsed.value;
|
|
87
87
|
const body = encodeJSON("body", payload, { explode: true });
|
|
88
88
|
|
|
89
|
-
const path = pathToFunc("/v2/
|
|
89
|
+
const path = pathToFunc("/v2/reporting")();
|
|
90
90
|
|
|
91
91
|
const headers = new Headers(compactMap({
|
|
92
92
|
"Content-Type": "application/json",
|
|
@@ -100,7 +100,7 @@ async function $do(
|
|
|
100
100
|
const context = {
|
|
101
101
|
options: client._options,
|
|
102
102
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
103
|
-
operationID: "
|
|
103
|
+
operationID: "ReportingQuery",
|
|
104
104
|
oAuth2Scopes: null,
|
|
105
105
|
|
|
106
106
|
resolvedSecurity: requestSecurity,
|
|
@@ -140,7 +140,7 @@ async function $do(
|
|
|
140
140
|
const response = doResult.value;
|
|
141
141
|
|
|
142
142
|
const [result] = await M.match<
|
|
143
|
-
|
|
143
|
+
components.QueryReportResponse,
|
|
144
144
|
| OrqError
|
|
145
145
|
| ResponseValidationError
|
|
146
146
|
| ConnectionError
|
|
@@ -150,7 +150,7 @@ async function $do(
|
|
|
150
150
|
| UnexpectedClientError
|
|
151
151
|
| SDKValidationError
|
|
152
152
|
>(
|
|
153
|
-
M.json(200,
|
|
153
|
+
M.json(200, components.QueryReportResponse$inboundSchema),
|
|
154
154
|
M.fail("4XX"),
|
|
155
155
|
M.fail("5XX"),
|
|
156
156
|
)(response, req);
|
|
@@ -29,7 +29,7 @@ import { Result } from "../types/fp.js";
|
|
|
29
29
|
* Create a new skill
|
|
30
30
|
*
|
|
31
31
|
* @remarks
|
|
32
|
-
*
|
|
32
|
+
* Creates a reusable skill in the workspace. Skills store instructions, metadata, and an optional project location so teams can standardize repeatable AI workflows.
|
|
33
33
|
*/
|
|
34
34
|
export function skillsCreate(
|
|
35
35
|
client: OrqCore,
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* Retrieve a skill
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Retrieves an existing skill by
|
|
33
|
+
* Retrieves an existing skill by skill ID. Display names are also accepted for compatibility because they are unique within a workspace.
|
|
34
34
|
*/
|
|
35
35
|
export function skillsGet(
|
|
36
36
|
client: OrqCore,
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* List all skills
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Returns
|
|
33
|
+
* Returns the skills visible to the current workspace, ordered by creation time with the newest skill first. Use `starting_after` or `ending_before` to page through large collections.
|
|
34
34
|
*/
|
|
35
35
|
export function skillsList(
|
|
36
36
|
client: OrqCore,
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* Update a skill
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Updates
|
|
33
|
+
* Updates mutable skill fields. Omitted optional fields keep their current values. Repeated fields such as `tags` replace the existing collection when provided.
|
|
34
34
|
*/
|
|
35
35
|
export function skillsUpdate(
|
|
36
36
|
client: OrqCore,
|
|
@@ -68,7 +68,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
68
68
|
export const SDK_METADATA = {
|
|
69
69
|
language: "typescript",
|
|
70
70
|
openapiDocVersion: "2.0",
|
|
71
|
-
sdkVersion: "4.10.0-rc.
|
|
72
|
-
genVersion: "2.
|
|
73
|
-
userAgent: "speakeasy-sdk/typescript 4.10.0-rc.
|
|
71
|
+
sdkVersion: "4.10.0-rc.11",
|
|
72
|
+
genVersion: "2.884.4",
|
|
73
|
+
userAgent: "speakeasy-sdk/typescript 4.10.0-rc.11 2.884.4 2.0 @orq-ai/node",
|
|
74
74
|
} as const;
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
|
|
8
|
+
export type CreateIdentityRequestMetadata = {};
|
|
9
|
+
|
|
10
|
+
export type CreateIdentityRequest = {
|
|
11
|
+
externalId?: string | undefined;
|
|
12
|
+
displayName?: string | undefined;
|
|
13
|
+
email?: string | undefined;
|
|
14
|
+
avatarUrl?: string | undefined;
|
|
15
|
+
tags?: Array<string> | undefined;
|
|
16
|
+
metadata?: CreateIdentityRequestMetadata | undefined;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/** @internal */
|
|
20
|
+
export type CreateIdentityRequestMetadata$Outbound = {};
|
|
21
|
+
|
|
22
|
+
/** @internal */
|
|
23
|
+
export const CreateIdentityRequestMetadata$outboundSchema: z.ZodType<
|
|
24
|
+
CreateIdentityRequestMetadata$Outbound,
|
|
25
|
+
z.ZodTypeDef,
|
|
26
|
+
CreateIdentityRequestMetadata
|
|
27
|
+
> = z.object({});
|
|
28
|
+
|
|
29
|
+
export function createIdentityRequestMetadataToJSON(
|
|
30
|
+
createIdentityRequestMetadata: CreateIdentityRequestMetadata,
|
|
31
|
+
): string {
|
|
32
|
+
return JSON.stringify(
|
|
33
|
+
CreateIdentityRequestMetadata$outboundSchema.parse(
|
|
34
|
+
createIdentityRequestMetadata,
|
|
35
|
+
),
|
|
36
|
+
);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/** @internal */
|
|
40
|
+
export type CreateIdentityRequest$Outbound = {
|
|
41
|
+
external_id?: string | undefined;
|
|
42
|
+
display_name?: string | undefined;
|
|
43
|
+
email?: string | undefined;
|
|
44
|
+
avatar_url?: string | undefined;
|
|
45
|
+
tags?: Array<string> | undefined;
|
|
46
|
+
metadata?: CreateIdentityRequestMetadata$Outbound | undefined;
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
/** @internal */
|
|
50
|
+
export const CreateIdentityRequest$outboundSchema: z.ZodType<
|
|
51
|
+
CreateIdentityRequest$Outbound,
|
|
52
|
+
z.ZodTypeDef,
|
|
53
|
+
CreateIdentityRequest
|
|
54
|
+
> = z.object({
|
|
55
|
+
externalId: z.string().optional(),
|
|
56
|
+
displayName: z.string().optional(),
|
|
57
|
+
email: z.string().optional(),
|
|
58
|
+
avatarUrl: z.string().optional(),
|
|
59
|
+
tags: z.array(z.string()).optional(),
|
|
60
|
+
metadata: z.lazy(() => CreateIdentityRequestMetadata$outboundSchema)
|
|
61
|
+
.optional(),
|
|
62
|
+
}).transform((v) => {
|
|
63
|
+
return remap$(v, {
|
|
64
|
+
externalId: "external_id",
|
|
65
|
+
displayName: "display_name",
|
|
66
|
+
avatarUrl: "avatar_url",
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
export function createIdentityRequestToJSON(
|
|
71
|
+
createIdentityRequest: CreateIdentityRequest,
|
|
72
|
+
): string {
|
|
73
|
+
return JSON.stringify(
|
|
74
|
+
CreateIdentityRequest$outboundSchema.parse(createIdentityRequest),
|
|
75
|
+
);
|
|
76
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import { Identity, Identity$inboundSchema } from "./identity.js";
|
|
10
|
+
|
|
11
|
+
export type CreateIdentityResponse = {
|
|
12
|
+
identity?: Identity | undefined;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const CreateIdentityResponse$inboundSchema: z.ZodType<
|
|
17
|
+
CreateIdentityResponse,
|
|
18
|
+
z.ZodTypeDef,
|
|
19
|
+
unknown
|
|
20
|
+
> = z.object({
|
|
21
|
+
identity: Identity$inboundSchema.optional(),
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
export function createIdentityResponseFromJSON(
|
|
25
|
+
jsonString: string,
|
|
26
|
+
): SafeParseResult<CreateIdentityResponse, SDKValidationError> {
|
|
27
|
+
return safeParse(
|
|
28
|
+
jsonString,
|
|
29
|
+
(x) => CreateIdentityResponse$inboundSchema.parse(JSON.parse(x)),
|
|
30
|
+
`Failed to parse 'CreateIdentityResponse' from JSON`,
|
|
31
|
+
);
|
|
32
|
+
}
|