syllable-sdk 0.1.0-alpha.70 → 0.1.0-alpha.71
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 +17 -0
- package/docs/sdks/insights/README.md +97 -0
- package/docs/sdks/prompts/README.md +81 -5
- package/docs/sdks/takeouts/README.md +163 -0
- package/docs/sdks/v1/README.md +251 -1
- package/funcs/insightsList.d.ts +17 -0
- package/funcs/insightsList.d.ts.map +1 -0
- package/funcs/insightsList.js +114 -0
- package/funcs/insightsList.js.map +1 -0
- package/funcs/promptsPromptGetSupportedLlms.d.ts +15 -0
- package/funcs/promptsPromptGetSupportedLlms.d.ts.map +1 -0
- package/funcs/promptsPromptGetSupportedLlms.js +89 -0
- package/funcs/promptsPromptGetSupportedLlms.js.map +1 -0
- package/funcs/takeoutsCreateTakeoutApiV1TakeoutsCreatePost.d.ts +13 -0
- package/funcs/takeoutsCreateTakeoutApiV1TakeoutsCreatePost.d.ts.map +1 -0
- package/funcs/takeoutsCreateTakeoutApiV1TakeoutsCreatePost.js +99 -0
- package/funcs/takeoutsCreateTakeoutApiV1TakeoutsCreatePost.js.map +1 -0
- package/funcs/takeoutsGetTakeoutApiV1TakeoutsGetJobIdGet.d.ts +14 -0
- package/funcs/takeoutsGetTakeoutApiV1TakeoutsGetJobIdGet.d.ts.map +1 -0
- package/funcs/takeoutsGetTakeoutApiV1TakeoutsGetJobIdGet.js +105 -0
- package/funcs/takeoutsGetTakeoutApiV1TakeoutsGetJobIdGet.js.map +1 -0
- package/funcs/v1CreateTakeoutApiV1TakeoutsCreatePost.d.ts +13 -0
- package/funcs/v1CreateTakeoutApiV1TakeoutsCreatePost.d.ts.map +1 -0
- package/funcs/v1CreateTakeoutApiV1TakeoutsCreatePost.js +99 -0
- package/funcs/v1CreateTakeoutApiV1TakeoutsCreatePost.js.map +1 -0
- package/funcs/v1GetTakeoutApiV1TakeoutsGetJobIdGet.d.ts +14 -0
- package/funcs/v1GetTakeoutApiV1TakeoutsGetJobIdGet.d.ts.map +1 -0
- package/funcs/v1GetTakeoutApiV1TakeoutsGetJobIdGet.js +105 -0
- package/funcs/v1GetTakeoutApiV1TakeoutsGetJobIdGet.js.map +1 -0
- package/funcs/v1List.d.ts +17 -0
- package/funcs/v1List.d.ts.map +1 -0
- package/funcs/v1List.js +114 -0
- package/funcs/v1List.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/createtakeoutresponse.d.ts +31 -0
- package/models/components/createtakeoutresponse.d.ts.map +1 -0
- package/models/components/createtakeoutresponse.js +72 -0
- package/models/components/createtakeoutresponse.js.map +1 -0
- package/models/components/daotakeoutcreate.d.ts +31 -0
- package/models/components/daotakeoutcreate.d.ts.map +1 -0
- package/models/components/daotakeoutcreate.js +72 -0
- package/models/components/daotakeoutcreate.js.map +1 -0
- package/models/components/index.d.ts +8 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +8 -0
- package/models/components/index.js.map +1 -1
- package/models/components/insightsoutput.d.ts +104 -0
- package/models/components/insightsoutput.d.ts.map +1 -0
- package/models/components/insightsoutput.js +127 -0
- package/models/components/insightsoutput.js.map +1 -0
- package/models/components/insightsproperties.d.ts +34 -0
- package/models/components/insightsproperties.d.ts.map +1 -0
- package/models/components/insightsproperties.js +52 -0
- package/models/components/insightsproperties.js.map +1 -0
- package/models/components/listresponseinsightsoutput.d.ts +53 -0
- package/models/components/listresponseinsightsoutput.d.ts.map +1 -0
- package/models/components/listresponseinsightsoutput.js +81 -0
- package/models/components/listresponseinsightsoutput.js.map +1 -0
- package/models/components/promptllmconfig.d.ts +1 -1
- package/models/components/supportedllm.d.ts +61 -0
- package/models/components/supportedllm.d.ts.map +1 -0
- package/models/components/supportedllm.js +81 -0
- package/models/components/supportedllm.js.map +1 -0
- package/models/components/takeoutrequeststatus.d.ts +43 -0
- package/models/components/takeoutrequeststatus.d.ts.map +1 -0
- package/models/components/takeoutrequeststatus.js +56 -0
- package/models/components/takeoutrequeststatus.js.map +1 -0
- package/models/components/takeoutstatusresponse.d.ts +39 -0
- package/models/components/takeoutstatusresponse.d.ts.map +1 -0
- package/models/components/takeoutstatusresponse.js +79 -0
- package/models/components/takeoutstatusresponse.js.map +1 -0
- package/models/operations/gettakeoutapiv1takeoutsgetjobidget.d.ts +29 -0
- package/models/operations/gettakeoutapiv1takeoutsgetjobidget.d.ts.map +1 -0
- package/models/operations/gettakeoutapiv1takeoutsgetjobidget.js +68 -0
- package/models/operations/gettakeoutapiv1takeoutsgetjobidget.js.map +1 -0
- package/models/operations/index.d.ts +2 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +2 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/insightslist.d.ts +73 -0
- package/models/operations/insightslist.d.ts.map +1 -0
- package/models/operations/insightslist.js +101 -0
- package/models/operations/insightslist.js.map +1 -0
- package/openapi.json +1080 -233
- package/package.json +1 -1
- package/sdk/insights.d.ts +10 -1
- package/sdk/insights.d.ts.map +1 -1
- package/sdk/insights.js +11 -0
- package/sdk/insights.js.map +1 -1
- package/sdk/prompts.d.ts +7 -0
- package/sdk/prompts.d.ts.map +1 -1
- package/sdk/prompts.js +10 -0
- package/sdk/prompts.js.map +1 -1
- package/sdk/sdk.d.ts +5 -2
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +7 -3
- package/sdk/sdk.js.map +1 -1
- package/sdk/takeouts.d.ts +14 -0
- package/sdk/takeouts.d.ts.map +1 -0
- package/sdk/takeouts.js +26 -0
- package/sdk/takeouts.js.map +1 -0
- package/sdk/v1.d.ts +15 -0
- package/sdk/v1.d.ts.map +1 -1
- package/sdk/v1.js +24 -0
- package/sdk/v1.js.map +1 -1
- package/src/funcs/insightsList.ts +148 -0
- package/src/funcs/promptsPromptGetSupportedLlms.ts +112 -0
- package/src/funcs/takeoutsCreateTakeoutApiV1TakeoutsCreatePost.ts +132 -0
- package/src/funcs/takeoutsGetTakeoutApiV1TakeoutsGetJobIdGet.ts +142 -0
- package/src/funcs/v1CreateTakeoutApiV1TakeoutsCreatePost.ts +132 -0
- package/src/funcs/v1GetTakeoutApiV1TakeoutsGetJobIdGet.ts +142 -0
- package/src/funcs/v1List.ts +148 -0
- package/src/lib/config.ts +2 -2
- package/src/models/components/createtakeoutresponse.ts +81 -0
- package/src/models/components/daotakeoutcreate.ts +81 -0
- package/src/models/components/index.ts +8 -0
- package/src/models/components/insightsoutput.ts +207 -0
- package/src/models/components/insightsproperties.ts +35 -0
- package/src/models/components/listresponseinsightsoutput.ts +116 -0
- package/src/models/components/promptllmconfig.ts +1 -1
- package/src/models/components/supportedllm.ts +119 -0
- package/src/models/components/takeoutrequeststatus.ts +42 -0
- package/src/models/components/takeoutstatusresponse.ts +99 -0
- package/src/models/operations/gettakeoutapiv1takeoutsgetjobidget.ts +87 -0
- package/src/models/operations/index.ts +2 -0
- package/src/models/operations/insightslist.ts +151 -0
- package/src/sdk/insights.ts +22 -1
- package/src/sdk/prompts.ts +16 -0
- package/src/sdk/sdk.ts +11 -5
- package/src/sdk/takeouts.ts +40 -0
- package/src/sdk/v1.ts +48 -0
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
export type CreateTakeoutResponse = {
|
|
12
|
+
jobId: string;
|
|
13
|
+
createdAt: Date;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const CreateTakeoutResponse$inboundSchema: z.ZodType<
|
|
18
|
+
CreateTakeoutResponse,
|
|
19
|
+
z.ZodTypeDef,
|
|
20
|
+
unknown
|
|
21
|
+
> = z.object({
|
|
22
|
+
job_id: z.string(),
|
|
23
|
+
created_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
24
|
+
}).transform((v) => {
|
|
25
|
+
return remap$(v, {
|
|
26
|
+
"job_id": "jobId",
|
|
27
|
+
"created_at": "createdAt",
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
/** @internal */
|
|
32
|
+
export type CreateTakeoutResponse$Outbound = {
|
|
33
|
+
job_id: string;
|
|
34
|
+
created_at: string;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/** @internal */
|
|
38
|
+
export const CreateTakeoutResponse$outboundSchema: z.ZodType<
|
|
39
|
+
CreateTakeoutResponse$Outbound,
|
|
40
|
+
z.ZodTypeDef,
|
|
41
|
+
CreateTakeoutResponse
|
|
42
|
+
> = z.object({
|
|
43
|
+
jobId: z.string(),
|
|
44
|
+
createdAt: z.date().transform(v => v.toISOString()),
|
|
45
|
+
}).transform((v) => {
|
|
46
|
+
return remap$(v, {
|
|
47
|
+
jobId: "job_id",
|
|
48
|
+
createdAt: "created_at",
|
|
49
|
+
});
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* @internal
|
|
54
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
55
|
+
*/
|
|
56
|
+
export namespace CreateTakeoutResponse$ {
|
|
57
|
+
/** @deprecated use `CreateTakeoutResponse$inboundSchema` instead. */
|
|
58
|
+
export const inboundSchema = CreateTakeoutResponse$inboundSchema;
|
|
59
|
+
/** @deprecated use `CreateTakeoutResponse$outboundSchema` instead. */
|
|
60
|
+
export const outboundSchema = CreateTakeoutResponse$outboundSchema;
|
|
61
|
+
/** @deprecated use `CreateTakeoutResponse$Outbound` instead. */
|
|
62
|
+
export type Outbound = CreateTakeoutResponse$Outbound;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function createTakeoutResponseToJSON(
|
|
66
|
+
createTakeoutResponse: CreateTakeoutResponse,
|
|
67
|
+
): string {
|
|
68
|
+
return JSON.stringify(
|
|
69
|
+
CreateTakeoutResponse$outboundSchema.parse(createTakeoutResponse),
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function createTakeoutResponseFromJSON(
|
|
74
|
+
jsonString: string,
|
|
75
|
+
): SafeParseResult<CreateTakeoutResponse, SDKValidationError> {
|
|
76
|
+
return safeParse(
|
|
77
|
+
jsonString,
|
|
78
|
+
(x) => CreateTakeoutResponse$inboundSchema.parse(JSON.parse(x)),
|
|
79
|
+
`Failed to parse 'CreateTakeoutResponse' from JSON`,
|
|
80
|
+
);
|
|
81
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
export type DaoTakeoutCreate = {
|
|
12
|
+
subOrganizationId: number;
|
|
13
|
+
requestedBy?: number | null | undefined;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const DaoTakeoutCreate$inboundSchema: z.ZodType<
|
|
18
|
+
DaoTakeoutCreate,
|
|
19
|
+
z.ZodTypeDef,
|
|
20
|
+
unknown
|
|
21
|
+
> = z.object({
|
|
22
|
+
sub_organization_id: z.number().int(),
|
|
23
|
+
requested_by: z.nullable(z.number().int()).optional(),
|
|
24
|
+
}).transform((v) => {
|
|
25
|
+
return remap$(v, {
|
|
26
|
+
"sub_organization_id": "subOrganizationId",
|
|
27
|
+
"requested_by": "requestedBy",
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
/** @internal */
|
|
32
|
+
export type DaoTakeoutCreate$Outbound = {
|
|
33
|
+
sub_organization_id: number;
|
|
34
|
+
requested_by?: number | null | undefined;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/** @internal */
|
|
38
|
+
export const DaoTakeoutCreate$outboundSchema: z.ZodType<
|
|
39
|
+
DaoTakeoutCreate$Outbound,
|
|
40
|
+
z.ZodTypeDef,
|
|
41
|
+
DaoTakeoutCreate
|
|
42
|
+
> = z.object({
|
|
43
|
+
subOrganizationId: z.number().int(),
|
|
44
|
+
requestedBy: z.nullable(z.number().int()).optional(),
|
|
45
|
+
}).transform((v) => {
|
|
46
|
+
return remap$(v, {
|
|
47
|
+
subOrganizationId: "sub_organization_id",
|
|
48
|
+
requestedBy: "requested_by",
|
|
49
|
+
});
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* @internal
|
|
54
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
55
|
+
*/
|
|
56
|
+
export namespace DaoTakeoutCreate$ {
|
|
57
|
+
/** @deprecated use `DaoTakeoutCreate$inboundSchema` instead. */
|
|
58
|
+
export const inboundSchema = DaoTakeoutCreate$inboundSchema;
|
|
59
|
+
/** @deprecated use `DaoTakeoutCreate$outboundSchema` instead. */
|
|
60
|
+
export const outboundSchema = DaoTakeoutCreate$outboundSchema;
|
|
61
|
+
/** @deprecated use `DaoTakeoutCreate$Outbound` instead. */
|
|
62
|
+
export type Outbound = DaoTakeoutCreate$Outbound;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function daoTakeoutCreateToJSON(
|
|
66
|
+
daoTakeoutCreate: DaoTakeoutCreate,
|
|
67
|
+
): string {
|
|
68
|
+
return JSON.stringify(
|
|
69
|
+
DaoTakeoutCreate$outboundSchema.parse(daoTakeoutCreate),
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function daoTakeoutCreateFromJSON(
|
|
74
|
+
jsonString: string,
|
|
75
|
+
): SafeParseResult<DaoTakeoutCreate, SDKValidationError> {
|
|
76
|
+
return safeParse(
|
|
77
|
+
jsonString,
|
|
78
|
+
(x) => DaoTakeoutCreate$inboundSchema.parse(JSON.parse(x)),
|
|
79
|
+
`Failed to parse 'DaoTakeoutCreate' from JSON`,
|
|
80
|
+
);
|
|
81
|
+
}
|
|
@@ -27,11 +27,13 @@ export * from "./channeltargetresponse.js";
|
|
|
27
27
|
export * from "./channeltargetupdaterequest.js";
|
|
28
28
|
export * from "./conversation.js";
|
|
29
29
|
export * from "./conversationproperties.js";
|
|
30
|
+
export * from "./createtakeoutresponse.js";
|
|
30
31
|
export * from "./custommessagecreaterequest.js";
|
|
31
32
|
export * from "./custommessageproperties.js";
|
|
32
33
|
export * from "./custommessageresponse.js";
|
|
33
34
|
export * from "./custommessagerule.js";
|
|
34
35
|
export * from "./custommessageupdaterequest.js";
|
|
36
|
+
export * from "./daotakeoutcreate.js";
|
|
35
37
|
export * from "./dashboard.js";
|
|
36
38
|
export * from "./dashboardproperties.js";
|
|
37
39
|
export * from "./dashboardresponse.js";
|
|
@@ -47,6 +49,8 @@ export * from "./dialogrole.js";
|
|
|
47
49
|
export * from "./dialogtoolcall.js";
|
|
48
50
|
export * from "./event.js";
|
|
49
51
|
export * from "./eventproperties.js";
|
|
52
|
+
export * from "./insightsoutput.js";
|
|
53
|
+
export * from "./insightsproperties.js";
|
|
50
54
|
export * from "./insighttooldefinition.js";
|
|
51
55
|
export * from "./insighttoolinput.js";
|
|
52
56
|
export * from "./insighttooloutput.js";
|
|
@@ -71,6 +75,7 @@ export * from "./listresponsecustommessageresponse.js";
|
|
|
71
75
|
export * from "./listresponsedashboardresponse.js";
|
|
72
76
|
export * from "./listresponsedatasourcemetadataresponse.js";
|
|
73
77
|
export * from "./listresponseevent.js";
|
|
78
|
+
export * from "./listresponseinsightsoutput.js";
|
|
74
79
|
export * from "./listresponseinsighttooloutput.js";
|
|
75
80
|
export * from "./listresponseinsightworkflowoutput.js";
|
|
76
81
|
export * from "./listresponselanguagegroupresponse.js";
|
|
@@ -106,6 +111,9 @@ export * from "./sessiontext.js";
|
|
|
106
111
|
export * from "./sessiontranscriptionresponse.js";
|
|
107
112
|
export * from "./statictoolparameter.js";
|
|
108
113
|
export * from "./statictoolparametertype.js";
|
|
114
|
+
export * from "./supportedllm.js";
|
|
115
|
+
export * from "./takeoutrequeststatus.js";
|
|
116
|
+
export * from "./takeoutstatusresponse.js";
|
|
109
117
|
export * from "./targetmodes.js";
|
|
110
118
|
export * from "./testmessage.js";
|
|
111
119
|
export * from "./testmessageresponse.js";
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* JSON value of insight tool result
|
|
13
|
+
*/
|
|
14
|
+
export type JsonValue = {};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Response model for an insight tool.
|
|
18
|
+
*/
|
|
19
|
+
export type InsightsOutput = {
|
|
20
|
+
/**
|
|
21
|
+
* Unique ID for insight tool
|
|
22
|
+
*/
|
|
23
|
+
id: number;
|
|
24
|
+
/**
|
|
25
|
+
* Unique ID for session
|
|
26
|
+
*/
|
|
27
|
+
sessionId: number;
|
|
28
|
+
/**
|
|
29
|
+
* Unique ID for insight tool
|
|
30
|
+
*/
|
|
31
|
+
insightToolId: number;
|
|
32
|
+
/**
|
|
33
|
+
* Version of insight tool
|
|
34
|
+
*/
|
|
35
|
+
insightToolVersion: number;
|
|
36
|
+
/**
|
|
37
|
+
* Key for insight tool result
|
|
38
|
+
*/
|
|
39
|
+
insightKey: string;
|
|
40
|
+
/**
|
|
41
|
+
* String value of insight tool result
|
|
42
|
+
*/
|
|
43
|
+
stringValue?: string | null | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* Numeric value of insight tool result
|
|
46
|
+
*/
|
|
47
|
+
numericValue?: number | null | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* JSON value of insight tool result
|
|
50
|
+
*/
|
|
51
|
+
jsonValue: JsonValue;
|
|
52
|
+
/**
|
|
53
|
+
* Timestamp at which insight tool result was created
|
|
54
|
+
*/
|
|
55
|
+
createdAt?: Date | undefined;
|
|
56
|
+
/**
|
|
57
|
+
* Timestamp at which insight tool result was last updated
|
|
58
|
+
*/
|
|
59
|
+
updatedAt?: Date | undefined;
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
/** @internal */
|
|
63
|
+
export const JsonValue$inboundSchema: z.ZodType<
|
|
64
|
+
JsonValue,
|
|
65
|
+
z.ZodTypeDef,
|
|
66
|
+
unknown
|
|
67
|
+
> = z.object({});
|
|
68
|
+
|
|
69
|
+
/** @internal */
|
|
70
|
+
export type JsonValue$Outbound = {};
|
|
71
|
+
|
|
72
|
+
/** @internal */
|
|
73
|
+
export const JsonValue$outboundSchema: z.ZodType<
|
|
74
|
+
JsonValue$Outbound,
|
|
75
|
+
z.ZodTypeDef,
|
|
76
|
+
JsonValue
|
|
77
|
+
> = z.object({});
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* @internal
|
|
81
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
82
|
+
*/
|
|
83
|
+
export namespace JsonValue$ {
|
|
84
|
+
/** @deprecated use `JsonValue$inboundSchema` instead. */
|
|
85
|
+
export const inboundSchema = JsonValue$inboundSchema;
|
|
86
|
+
/** @deprecated use `JsonValue$outboundSchema` instead. */
|
|
87
|
+
export const outboundSchema = JsonValue$outboundSchema;
|
|
88
|
+
/** @deprecated use `JsonValue$Outbound` instead. */
|
|
89
|
+
export type Outbound = JsonValue$Outbound;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function jsonValueToJSON(jsonValue: JsonValue): string {
|
|
93
|
+
return JSON.stringify(JsonValue$outboundSchema.parse(jsonValue));
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export function jsonValueFromJSON(
|
|
97
|
+
jsonString: string,
|
|
98
|
+
): SafeParseResult<JsonValue, SDKValidationError> {
|
|
99
|
+
return safeParse(
|
|
100
|
+
jsonString,
|
|
101
|
+
(x) => JsonValue$inboundSchema.parse(JSON.parse(x)),
|
|
102
|
+
`Failed to parse 'JsonValue' from JSON`,
|
|
103
|
+
);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
/** @internal */
|
|
107
|
+
export const InsightsOutput$inboundSchema: z.ZodType<
|
|
108
|
+
InsightsOutput,
|
|
109
|
+
z.ZodTypeDef,
|
|
110
|
+
unknown
|
|
111
|
+
> = z.object({
|
|
112
|
+
id: z.number().int(),
|
|
113
|
+
session_id: z.number().int(),
|
|
114
|
+
insight_tool_id: z.number().int(),
|
|
115
|
+
insight_tool_version: z.number().int(),
|
|
116
|
+
insight_key: z.string(),
|
|
117
|
+
string_value: z.nullable(z.string()).optional(),
|
|
118
|
+
numeric_value: z.nullable(z.number()).optional(),
|
|
119
|
+
json_value: z.lazy(() => JsonValue$inboundSchema),
|
|
120
|
+
created_at: z.string().datetime({ offset: true }).transform(v => new Date(v))
|
|
121
|
+
.optional(),
|
|
122
|
+
updated_at: z.string().datetime({ offset: true }).transform(v => new Date(v))
|
|
123
|
+
.optional(),
|
|
124
|
+
}).transform((v) => {
|
|
125
|
+
return remap$(v, {
|
|
126
|
+
"session_id": "sessionId",
|
|
127
|
+
"insight_tool_id": "insightToolId",
|
|
128
|
+
"insight_tool_version": "insightToolVersion",
|
|
129
|
+
"insight_key": "insightKey",
|
|
130
|
+
"string_value": "stringValue",
|
|
131
|
+
"numeric_value": "numericValue",
|
|
132
|
+
"json_value": "jsonValue",
|
|
133
|
+
"created_at": "createdAt",
|
|
134
|
+
"updated_at": "updatedAt",
|
|
135
|
+
});
|
|
136
|
+
});
|
|
137
|
+
|
|
138
|
+
/** @internal */
|
|
139
|
+
export type InsightsOutput$Outbound = {
|
|
140
|
+
id: number;
|
|
141
|
+
session_id: number;
|
|
142
|
+
insight_tool_id: number;
|
|
143
|
+
insight_tool_version: number;
|
|
144
|
+
insight_key: string;
|
|
145
|
+
string_value?: string | null | undefined;
|
|
146
|
+
numeric_value?: number | null | undefined;
|
|
147
|
+
json_value: JsonValue$Outbound;
|
|
148
|
+
created_at?: string | undefined;
|
|
149
|
+
updated_at?: string | undefined;
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
/** @internal */
|
|
153
|
+
export const InsightsOutput$outboundSchema: z.ZodType<
|
|
154
|
+
InsightsOutput$Outbound,
|
|
155
|
+
z.ZodTypeDef,
|
|
156
|
+
InsightsOutput
|
|
157
|
+
> = z.object({
|
|
158
|
+
id: z.number().int(),
|
|
159
|
+
sessionId: z.number().int(),
|
|
160
|
+
insightToolId: z.number().int(),
|
|
161
|
+
insightToolVersion: z.number().int(),
|
|
162
|
+
insightKey: z.string(),
|
|
163
|
+
stringValue: z.nullable(z.string()).optional(),
|
|
164
|
+
numericValue: z.nullable(z.number()).optional(),
|
|
165
|
+
jsonValue: z.lazy(() => JsonValue$outboundSchema),
|
|
166
|
+
createdAt: z.date().transform(v => v.toISOString()).optional(),
|
|
167
|
+
updatedAt: z.date().transform(v => v.toISOString()).optional(),
|
|
168
|
+
}).transform((v) => {
|
|
169
|
+
return remap$(v, {
|
|
170
|
+
sessionId: "session_id",
|
|
171
|
+
insightToolId: "insight_tool_id",
|
|
172
|
+
insightToolVersion: "insight_tool_version",
|
|
173
|
+
insightKey: "insight_key",
|
|
174
|
+
stringValue: "string_value",
|
|
175
|
+
numericValue: "numeric_value",
|
|
176
|
+
jsonValue: "json_value",
|
|
177
|
+
createdAt: "created_at",
|
|
178
|
+
updatedAt: "updated_at",
|
|
179
|
+
});
|
|
180
|
+
});
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* @internal
|
|
184
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
185
|
+
*/
|
|
186
|
+
export namespace InsightsOutput$ {
|
|
187
|
+
/** @deprecated use `InsightsOutput$inboundSchema` instead. */
|
|
188
|
+
export const inboundSchema = InsightsOutput$inboundSchema;
|
|
189
|
+
/** @deprecated use `InsightsOutput$outboundSchema` instead. */
|
|
190
|
+
export const outboundSchema = InsightsOutput$outboundSchema;
|
|
191
|
+
/** @deprecated use `InsightsOutput$Outbound` instead. */
|
|
192
|
+
export type Outbound = InsightsOutput$Outbound;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
export function insightsOutputToJSON(insightsOutput: InsightsOutput): string {
|
|
196
|
+
return JSON.stringify(InsightsOutput$outboundSchema.parse(insightsOutput));
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
export function insightsOutputFromJSON(
|
|
200
|
+
jsonString: string,
|
|
201
|
+
): SafeParseResult<InsightsOutput, SDKValidationError> {
|
|
202
|
+
return safeParse(
|
|
203
|
+
jsonString,
|
|
204
|
+
(x) => InsightsOutput$inboundSchema.parse(JSON.parse(x)),
|
|
205
|
+
`Failed to parse 'InsightsOutput' from JSON`,
|
|
206
|
+
);
|
|
207
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const InsightsProperties = {
|
|
9
|
+
Id: "id",
|
|
10
|
+
SessionId: "session_id",
|
|
11
|
+
InsightKey: "insight_key",
|
|
12
|
+
InsightToolId: "insight_tool_id",
|
|
13
|
+
} as const;
|
|
14
|
+
export type InsightsProperties = ClosedEnum<typeof InsightsProperties>;
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const InsightsProperties$inboundSchema: z.ZodNativeEnum<
|
|
18
|
+
typeof InsightsProperties
|
|
19
|
+
> = z.nativeEnum(InsightsProperties);
|
|
20
|
+
|
|
21
|
+
/** @internal */
|
|
22
|
+
export const InsightsProperties$outboundSchema: z.ZodNativeEnum<
|
|
23
|
+
typeof InsightsProperties
|
|
24
|
+
> = InsightsProperties$inboundSchema;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @internal
|
|
28
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
29
|
+
*/
|
|
30
|
+
export namespace InsightsProperties$ {
|
|
31
|
+
/** @deprecated use `InsightsProperties$inboundSchema` instead. */
|
|
32
|
+
export const inboundSchema = InsightsProperties$inboundSchema;
|
|
33
|
+
/** @deprecated use `InsightsProperties$outboundSchema` instead. */
|
|
34
|
+
export const outboundSchema = InsightsProperties$outboundSchema;
|
|
35
|
+
}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
InsightsOutput,
|
|
12
|
+
InsightsOutput$inboundSchema,
|
|
13
|
+
InsightsOutput$Outbound,
|
|
14
|
+
InsightsOutput$outboundSchema,
|
|
15
|
+
} from "./insightsoutput.js";
|
|
16
|
+
|
|
17
|
+
export type ListResponseInsightsOutput = {
|
|
18
|
+
/**
|
|
19
|
+
* List of items returned from the query
|
|
20
|
+
*/
|
|
21
|
+
items: Array<InsightsOutput>;
|
|
22
|
+
/**
|
|
23
|
+
* The page number of the results (0-based)
|
|
24
|
+
*/
|
|
25
|
+
page: number;
|
|
26
|
+
/**
|
|
27
|
+
* The number of items returned per page
|
|
28
|
+
*/
|
|
29
|
+
pageSize: number;
|
|
30
|
+
/**
|
|
31
|
+
* The total number of pages of results given the indicated page size
|
|
32
|
+
*/
|
|
33
|
+
totalPages?: number | null | undefined;
|
|
34
|
+
/**
|
|
35
|
+
* The total number of items returned from the query
|
|
36
|
+
*/
|
|
37
|
+
totalCount?: number | null | undefined;
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
/** @internal */
|
|
41
|
+
export const ListResponseInsightsOutput$inboundSchema: z.ZodType<
|
|
42
|
+
ListResponseInsightsOutput,
|
|
43
|
+
z.ZodTypeDef,
|
|
44
|
+
unknown
|
|
45
|
+
> = z.object({
|
|
46
|
+
items: z.array(InsightsOutput$inboundSchema),
|
|
47
|
+
page: z.number().int(),
|
|
48
|
+
page_size: z.number().int(),
|
|
49
|
+
total_pages: z.nullable(z.number().int()).optional(),
|
|
50
|
+
total_count: z.nullable(z.number().int()).optional(),
|
|
51
|
+
}).transform((v) => {
|
|
52
|
+
return remap$(v, {
|
|
53
|
+
"page_size": "pageSize",
|
|
54
|
+
"total_pages": "totalPages",
|
|
55
|
+
"total_count": "totalCount",
|
|
56
|
+
});
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
/** @internal */
|
|
60
|
+
export type ListResponseInsightsOutput$Outbound = {
|
|
61
|
+
items: Array<InsightsOutput$Outbound>;
|
|
62
|
+
page: number;
|
|
63
|
+
page_size: number;
|
|
64
|
+
total_pages?: number | null | undefined;
|
|
65
|
+
total_count?: number | null | undefined;
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
/** @internal */
|
|
69
|
+
export const ListResponseInsightsOutput$outboundSchema: z.ZodType<
|
|
70
|
+
ListResponseInsightsOutput$Outbound,
|
|
71
|
+
z.ZodTypeDef,
|
|
72
|
+
ListResponseInsightsOutput
|
|
73
|
+
> = z.object({
|
|
74
|
+
items: z.array(InsightsOutput$outboundSchema),
|
|
75
|
+
page: z.number().int(),
|
|
76
|
+
pageSize: z.number().int(),
|
|
77
|
+
totalPages: z.nullable(z.number().int()).optional(),
|
|
78
|
+
totalCount: z.nullable(z.number().int()).optional(),
|
|
79
|
+
}).transform((v) => {
|
|
80
|
+
return remap$(v, {
|
|
81
|
+
pageSize: "page_size",
|
|
82
|
+
totalPages: "total_pages",
|
|
83
|
+
totalCount: "total_count",
|
|
84
|
+
});
|
|
85
|
+
});
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* @internal
|
|
89
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
90
|
+
*/
|
|
91
|
+
export namespace ListResponseInsightsOutput$ {
|
|
92
|
+
/** @deprecated use `ListResponseInsightsOutput$inboundSchema` instead. */
|
|
93
|
+
export const inboundSchema = ListResponseInsightsOutput$inboundSchema;
|
|
94
|
+
/** @deprecated use `ListResponseInsightsOutput$outboundSchema` instead. */
|
|
95
|
+
export const outboundSchema = ListResponseInsightsOutput$outboundSchema;
|
|
96
|
+
/** @deprecated use `ListResponseInsightsOutput$Outbound` instead. */
|
|
97
|
+
export type Outbound = ListResponseInsightsOutput$Outbound;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export function listResponseInsightsOutputToJSON(
|
|
101
|
+
listResponseInsightsOutput: ListResponseInsightsOutput,
|
|
102
|
+
): string {
|
|
103
|
+
return JSON.stringify(
|
|
104
|
+
ListResponseInsightsOutput$outboundSchema.parse(listResponseInsightsOutput),
|
|
105
|
+
);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function listResponseInsightsOutputFromJSON(
|
|
109
|
+
jsonString: string,
|
|
110
|
+
): SafeParseResult<ListResponseInsightsOutput, SDKValidationError> {
|
|
111
|
+
return safeParse(
|
|
112
|
+
jsonString,
|
|
113
|
+
(x) => ListResponseInsightsOutput$inboundSchema.parse(JSON.parse(x)),
|
|
114
|
+
`Failed to parse 'ListResponseInsightsOutput' from JSON`,
|
|
115
|
+
);
|
|
116
|
+
}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
PromptLlmProvider,
|
|
12
|
+
PromptLlmProvider$inboundSchema,
|
|
13
|
+
PromptLlmProvider$outboundSchema,
|
|
14
|
+
} from "./promptllmprovider.js";
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* LLM config option that can be used on a prompt.
|
|
18
|
+
*/
|
|
19
|
+
export type SupportedLlm = {
|
|
20
|
+
/**
|
|
21
|
+
* LLM API provider.
|
|
22
|
+
*/
|
|
23
|
+
provider?: PromptLlmProvider | undefined;
|
|
24
|
+
/**
|
|
25
|
+
* Name of the model. Must match the deployment name in Azure AI Studio.
|
|
26
|
+
*/
|
|
27
|
+
model?: string | undefined;
|
|
28
|
+
/**
|
|
29
|
+
* Display name of the model. This is used for display purposes in the Console UI.
|
|
30
|
+
*/
|
|
31
|
+
displayName: string;
|
|
32
|
+
/**
|
|
33
|
+
* Model version.
|
|
34
|
+
*/
|
|
35
|
+
version?: string | null | undefined;
|
|
36
|
+
/**
|
|
37
|
+
* Version of the provider's API.
|
|
38
|
+
*/
|
|
39
|
+
apiVersion?: string | null | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Whether the LLM config is deprecated and should not be used.
|
|
42
|
+
*/
|
|
43
|
+
deprecated: boolean;
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
/** @internal */
|
|
47
|
+
export const SupportedLlm$inboundSchema: z.ZodType<
|
|
48
|
+
SupportedLlm,
|
|
49
|
+
z.ZodTypeDef,
|
|
50
|
+
unknown
|
|
51
|
+
> = z.object({
|
|
52
|
+
provider: PromptLlmProvider$inboundSchema.optional(),
|
|
53
|
+
model: z.string().default("gpt-4o"),
|
|
54
|
+
display_name: z.string(),
|
|
55
|
+
version: z.nullable(z.string()).optional(),
|
|
56
|
+
api_version: z.nullable(z.string()).optional(),
|
|
57
|
+
deprecated: z.boolean(),
|
|
58
|
+
}).transform((v) => {
|
|
59
|
+
return remap$(v, {
|
|
60
|
+
"display_name": "displayName",
|
|
61
|
+
"api_version": "apiVersion",
|
|
62
|
+
});
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
/** @internal */
|
|
66
|
+
export type SupportedLlm$Outbound = {
|
|
67
|
+
provider?: string | undefined;
|
|
68
|
+
model: string;
|
|
69
|
+
display_name: string;
|
|
70
|
+
version?: string | null | undefined;
|
|
71
|
+
api_version?: string | null | undefined;
|
|
72
|
+
deprecated: boolean;
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
/** @internal */
|
|
76
|
+
export const SupportedLlm$outboundSchema: z.ZodType<
|
|
77
|
+
SupportedLlm$Outbound,
|
|
78
|
+
z.ZodTypeDef,
|
|
79
|
+
SupportedLlm
|
|
80
|
+
> = z.object({
|
|
81
|
+
provider: PromptLlmProvider$outboundSchema.optional(),
|
|
82
|
+
model: z.string().default("gpt-4o"),
|
|
83
|
+
displayName: z.string(),
|
|
84
|
+
version: z.nullable(z.string()).optional(),
|
|
85
|
+
apiVersion: z.nullable(z.string()).optional(),
|
|
86
|
+
deprecated: z.boolean(),
|
|
87
|
+
}).transform((v) => {
|
|
88
|
+
return remap$(v, {
|
|
89
|
+
displayName: "display_name",
|
|
90
|
+
apiVersion: "api_version",
|
|
91
|
+
});
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* @internal
|
|
96
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
97
|
+
*/
|
|
98
|
+
export namespace SupportedLlm$ {
|
|
99
|
+
/** @deprecated use `SupportedLlm$inboundSchema` instead. */
|
|
100
|
+
export const inboundSchema = SupportedLlm$inboundSchema;
|
|
101
|
+
/** @deprecated use `SupportedLlm$outboundSchema` instead. */
|
|
102
|
+
export const outboundSchema = SupportedLlm$outboundSchema;
|
|
103
|
+
/** @deprecated use `SupportedLlm$Outbound` instead. */
|
|
104
|
+
export type Outbound = SupportedLlm$Outbound;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export function supportedLlmToJSON(supportedLlm: SupportedLlm): string {
|
|
108
|
+
return JSON.stringify(SupportedLlm$outboundSchema.parse(supportedLlm));
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export function supportedLlmFromJSON(
|
|
112
|
+
jsonString: string,
|
|
113
|
+
): SafeParseResult<SupportedLlm, SDKValidationError> {
|
|
114
|
+
return safeParse(
|
|
115
|
+
jsonString,
|
|
116
|
+
(x) => SupportedLlm$inboundSchema.parse(JSON.parse(x)),
|
|
117
|
+
`Failed to parse 'SupportedLlm' from JSON`,
|
|
118
|
+
);
|
|
119
|
+
}
|