syllable-sdk 1.0.13-rc.4 → 1.0.13-rc.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/bin/mcp-server.js +2001 -59
- package/bin/mcp-server.js.map +34 -11
- package/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.js +1 -1
- package/models/components/bodyinsightsfolderuploadfile.d.ts +8 -8
- package/models/components/bodyinsightsfolderuploadfile.d.ts.map +1 -1
- package/models/components/bodyinsightsfolderuploadfile.js +11 -12
- package/models/components/bodyinsightsfolderuploadfile.js.map +1 -1
- package/models/components/callaction.d.ts +113 -0
- package/models/components/callaction.d.ts.map +1 -0
- package/models/components/callaction.js +174 -0
- package/models/components/callaction.js.map +1 -0
- package/models/components/caseexpression.d.ts +18 -0
- package/models/components/caseexpression.d.ts.map +1 -0
- package/models/components/caseexpression.js +59 -0
- package/models/components/caseexpression.js.map +1 -0
- package/models/components/celexpression.d.ts +28 -0
- package/models/components/celexpression.d.ts.map +1 -0
- package/models/components/celexpression.js +60 -0
- package/models/components/celexpression.js.map +1 -0
- package/models/components/conditionaltext.d.ts +85 -0
- package/models/components/conditionaltext.d.ts.map +1 -0
- package/models/components/conditionaltext.js +147 -0
- package/models/components/conditionaltext.js.map +1 -0
- package/models/components/conditionalvalue.d.ts +147 -0
- package/models/components/conditionalvalue.d.ts.map +1 -0
- package/models/components/conditionalvalue.js +248 -0
- package/models/components/conditionalvalue.js.map +1 -0
- package/models/components/context.d.ts +122 -8
- package/models/components/context.d.ts.map +1 -1
- package/models/components/context.js +199 -6
- package/models/components/context.js.map +1 -1
- package/models/components/contexttaskmetadata.d.ts +22 -0
- package/models/components/contexttaskmetadata.d.ts.map +1 -0
- package/models/components/contexttaskmetadata.js +69 -0
- package/models/components/contexttaskmetadata.js.map +1 -0
- package/models/components/contexttoolinfo.d.ts +25 -0
- package/models/components/contexttoolinfo.d.ts.map +1 -0
- package/models/components/contexttoolinfo.js +60 -0
- package/models/components/contexttoolinfo.js.map +1 -0
- package/models/components/eventtask.d.ts +42 -0
- package/models/components/eventtask.d.ts.map +1 -0
- package/models/components/eventtask.js +76 -0
- package/models/components/eventtask.js.map +1 -0
- package/models/components/eventtaskevents.d.ts +74 -0
- package/models/components/eventtaskevents.d.ts.map +1 -0
- package/models/components/eventtaskevents.js +139 -0
- package/models/components/eventtaskevents.js.map +1 -0
- package/models/components/expressiontask.d.ts +109 -0
- package/models/components/expressiontask.d.ts.map +1 -0
- package/models/components/expressiontask.js +170 -0
- package/models/components/expressiontask.js.map +1 -0
- package/models/components/expressiontaskevents.d.ts +131 -0
- package/models/components/expressiontaskevents.d.ts.map +1 -0
- package/models/components/expressiontaskevents.js +219 -0
- package/models/components/expressiontaskevents.js.map +1 -0
- package/models/components/incrementaction.d.ts +92 -0
- package/models/components/incrementaction.d.ts.map +1 -0
- package/models/components/incrementaction.js +151 -0
- package/models/components/incrementaction.js.map +1 -0
- package/models/components/index.d.ts +24 -1
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +24 -1
- package/models/components/index.js.map +1 -1
- package/models/components/inputparameter.d.ts +51 -0
- package/models/components/inputparameter.d.ts.map +1 -0
- package/models/components/inputparameter.js +87 -0
- package/models/components/inputparameter.js.map +1 -0
- package/models/components/jmespathexpression.d.ts +44 -0
- package/models/components/jmespathexpression.d.ts.map +1 -0
- package/models/components/jmespathexpression.js +71 -0
- package/models/components/jmespathexpression.js.map +1 -0
- package/models/components/loadtoolfromfiletask.d.ts +59 -0
- package/models/components/loadtoolfromfiletask.d.ts.map +1 -0
- package/models/components/loadtoolfromfiletask.js +88 -0
- package/models/components/loadtoolfromfiletask.js.map +1 -0
- package/models/components/nextstep.d.ts +93 -0
- package/models/components/nextstep.d.ts.map +1 -0
- package/models/components/nextstep.js +149 -0
- package/models/components/nextstep.js.map +1 -0
- package/models/components/saveaction.d.ts +92 -0
- package/models/components/saveaction.d.ts.map +1 -0
- package/models/components/saveaction.js +151 -0
- package/models/components/saveaction.js.map +1 -0
- package/models/components/sayaction.d.ts +108 -0
- package/models/components/sayaction.d.ts.map +1 -0
- package/models/components/sayaction.js +162 -0
- package/models/components/sayaction.js.map +1 -0
- package/models/components/session.d.ts +5 -0
- package/models/components/session.d.ts.map +1 -1
- package/models/components/session.js +4 -0
- package/models/components/session.js.map +1 -1
- package/models/components/setvalueaction.d.ts +154 -0
- package/models/components/setvalueaction.d.ts.map +1 -0
- package/models/components/setvalueaction.js +246 -0
- package/models/components/setvalueaction.js.map +1 -0
- package/models/components/step.d.ts +73 -0
- package/models/components/step.d.ts.map +1 -0
- package/models/components/step.js +103 -0
- package/models/components/step.js.map +1 -0
- package/models/components/stepeventactions.d.ts +185 -0
- package/models/components/stepeventactions.d.ts.map +1 -0
- package/models/components/stepeventactions.js +296 -0
- package/models/components/stepeventactions.js.map +1 -0
- package/models/components/stepstask.d.ts +42 -0
- package/models/components/stepstask.d.ts.map +1 -0
- package/models/components/stepstask.js +76 -0
- package/models/components/stepstask.js.map +1 -0
- package/models/components/steptools.d.ts +33 -0
- package/models/components/steptools.d.ts.map +1 -0
- package/models/components/{contexttask.js → steptools.js} +24 -22
- package/models/components/steptools.js.map +1 -0
- package/models/components/variable.d.ts +119 -0
- package/models/components/variable.d.ts.map +1 -0
- package/models/components/variable.js +186 -0
- package/models/components/variable.js.map +1 -0
- package/openapi.json +2453 -662
- package/package.json +1 -1
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/components/bodyinsightsfolderuploadfile.ts +36 -25
- package/src/models/components/callaction.ts +331 -0
- package/src/models/components/caseexpression.ts +53 -0
- package/src/models/components/celexpression.ts +60 -0
- package/src/models/components/conditionaltext.ts +280 -0
- package/src/models/components/conditionalvalue.ts +477 -0
- package/src/models/components/context.ts +413 -16
- package/src/models/components/contexttaskmetadata.ts +67 -0
- package/src/models/components/contexttoolinfo.ts +59 -0
- package/src/models/components/eventtask.ts +102 -0
- package/src/models/components/eventtaskevents.ts +257 -0
- package/src/models/components/expressiontask.ts +333 -0
- package/src/models/components/expressiontaskevents.ts +430 -0
- package/src/models/components/incrementaction.ts +291 -0
- package/src/models/components/index.ts +24 -1
- package/src/models/components/inputparameter.ts +103 -0
- package/src/models/components/jmespathexpression.ts +86 -0
- package/src/models/components/loadtoolfromfiletask.ts +137 -0
- package/src/models/components/nextstep.ts +280 -0
- package/src/models/components/saveaction.ts +281 -0
- package/src/models/components/sayaction.ts +302 -0
- package/src/models/components/session.ts +9 -0
- package/src/models/components/setvalueaction.ts +508 -0
- package/src/models/components/step.ts +174 -0
- package/src/models/components/stepeventactions.ts +619 -0
- package/src/models/components/stepstask.ts +102 -0
- package/src/models/components/steptools.ts +76 -0
- package/src/models/components/variable.ts +332 -0
- package/models/components/contexttask.d.ts +0 -32
- package/models/components/contexttask.d.ts.map +0 -1
- package/models/components/contexttask.js.map +0 -1
- package/src/models/components/contexttask.ts +0 -78
|
@@ -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
|
+
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
|
+
* Configuration for tools available in a step.
|
|
13
|
+
*/
|
|
14
|
+
export type StepTools = {
|
|
15
|
+
/**
|
|
16
|
+
* Whether to force immediate tool call without user interaction.
|
|
17
|
+
*/
|
|
18
|
+
call?: boolean | null | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* List of allowed tool names for this step.
|
|
21
|
+
*/
|
|
22
|
+
allow?: Array<string> | null | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Whether to expose the go_to_step escape hatch to the LLM. Defaults to disabled.
|
|
25
|
+
*/
|
|
26
|
+
allowGoToStep?: boolean | null | undefined;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
/** @internal */
|
|
30
|
+
export const StepTools$inboundSchema: z.ZodType<
|
|
31
|
+
StepTools,
|
|
32
|
+
z.ZodTypeDef,
|
|
33
|
+
unknown
|
|
34
|
+
> = z.object({
|
|
35
|
+
call: z.nullable(z.boolean()).optional(),
|
|
36
|
+
allow: z.nullable(z.array(z.string())).optional(),
|
|
37
|
+
allow_go_to_step: z.nullable(z.boolean()).optional(),
|
|
38
|
+
}).transform((v) => {
|
|
39
|
+
return remap$(v, {
|
|
40
|
+
"allow_go_to_step": "allowGoToStep",
|
|
41
|
+
});
|
|
42
|
+
});
|
|
43
|
+
/** @internal */
|
|
44
|
+
export type StepTools$Outbound = {
|
|
45
|
+
call?: boolean | null | undefined;
|
|
46
|
+
allow?: Array<string> | null | undefined;
|
|
47
|
+
allow_go_to_step?: boolean | null | undefined;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
/** @internal */
|
|
51
|
+
export const StepTools$outboundSchema: z.ZodType<
|
|
52
|
+
StepTools$Outbound,
|
|
53
|
+
z.ZodTypeDef,
|
|
54
|
+
StepTools
|
|
55
|
+
> = z.object({
|
|
56
|
+
call: z.nullable(z.boolean()).optional(),
|
|
57
|
+
allow: z.nullable(z.array(z.string())).optional(),
|
|
58
|
+
allowGoToStep: z.nullable(z.boolean()).optional(),
|
|
59
|
+
}).transform((v) => {
|
|
60
|
+
return remap$(v, {
|
|
61
|
+
allowGoToStep: "allow_go_to_step",
|
|
62
|
+
});
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
export function stepToolsToJSON(stepTools: StepTools): string {
|
|
66
|
+
return JSON.stringify(StepTools$outboundSchema.parse(stepTools));
|
|
67
|
+
}
|
|
68
|
+
export function stepToolsFromJSON(
|
|
69
|
+
jsonString: string,
|
|
70
|
+
): SafeParseResult<StepTools, SDKValidationError> {
|
|
71
|
+
return safeParse(
|
|
72
|
+
jsonString,
|
|
73
|
+
(x) => StepTools$inboundSchema.parse(JSON.parse(x)),
|
|
74
|
+
`Failed to parse 'StepTools' from JSON`,
|
|
75
|
+
);
|
|
76
|
+
}
|
|
@@ -0,0 +1,332 @@
|
|
|
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
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
9
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
import {
|
|
12
|
+
CaseExpression,
|
|
13
|
+
CaseExpression$inboundSchema,
|
|
14
|
+
CaseExpression$Outbound,
|
|
15
|
+
CaseExpression$outboundSchema,
|
|
16
|
+
} from "./caseexpression.js";
|
|
17
|
+
import {
|
|
18
|
+
CelExpression,
|
|
19
|
+
CelExpression$inboundSchema,
|
|
20
|
+
CelExpression$Outbound,
|
|
21
|
+
CelExpression$outboundSchema,
|
|
22
|
+
} from "./celexpression.js";
|
|
23
|
+
import {
|
|
24
|
+
JMESPathExpression,
|
|
25
|
+
JMESPathExpression$inboundSchema,
|
|
26
|
+
JMESPathExpression$Outbound,
|
|
27
|
+
JMESPathExpression$outboundSchema,
|
|
28
|
+
} from "./jmespathexpression.js";
|
|
29
|
+
|
|
30
|
+
export type One =
|
|
31
|
+
| (CelExpression & { type: "cel" })
|
|
32
|
+
| (JMESPathExpression & { type: "jmespath" })
|
|
33
|
+
| (JMESPathExpression & { type: "jp" });
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Expression to compute initial value (mutually exclusive with value).
|
|
37
|
+
*/
|
|
38
|
+
export type VariableValueFrom =
|
|
39
|
+
| CaseExpression
|
|
40
|
+
| (CelExpression & { type: "cel" })
|
|
41
|
+
| (JMESPathExpression & { type: "jmespath" })
|
|
42
|
+
| (JMESPathExpression & { type: "jp" })
|
|
43
|
+
| string;
|
|
44
|
+
|
|
45
|
+
export const VariableType = {
|
|
46
|
+
String: "string",
|
|
47
|
+
Number: "number",
|
|
48
|
+
Integer: "integer",
|
|
49
|
+
Boolean: "boolean",
|
|
50
|
+
Object: "object",
|
|
51
|
+
Array: "array",
|
|
52
|
+
Null: "null",
|
|
53
|
+
} as const;
|
|
54
|
+
export type VariableType = ClosedEnum<typeof VariableType>;
|
|
55
|
+
|
|
56
|
+
export type Variable = {
|
|
57
|
+
/**
|
|
58
|
+
* Initial value of the variable.
|
|
59
|
+
*/
|
|
60
|
+
value?: any | null | undefined;
|
|
61
|
+
/**
|
|
62
|
+
* Expression to compute initial value (mutually exclusive with value).
|
|
63
|
+
*/
|
|
64
|
+
valueFrom?:
|
|
65
|
+
| CaseExpression
|
|
66
|
+
| (CelExpression & { type: "cel" })
|
|
67
|
+
| (JMESPathExpression & { type: "jmespath" })
|
|
68
|
+
| (JMESPathExpression & { type: "jp" })
|
|
69
|
+
| string
|
|
70
|
+
| null
|
|
71
|
+
| undefined;
|
|
72
|
+
/**
|
|
73
|
+
* The name of the property.
|
|
74
|
+
*/
|
|
75
|
+
name: string;
|
|
76
|
+
type?: VariableType | null | undefined;
|
|
77
|
+
description?: string | null | undefined;
|
|
78
|
+
title?: string | null | undefined;
|
|
79
|
+
format?: string | null | undefined;
|
|
80
|
+
pattern?: string | null | undefined;
|
|
81
|
+
enum?: Array<string> | null | undefined;
|
|
82
|
+
examples?: Array<any> | null | undefined;
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
/** @internal */
|
|
86
|
+
export const One$inboundSchema: z.ZodType<One, z.ZodTypeDef, unknown> = z.union(
|
|
87
|
+
[
|
|
88
|
+
CelExpression$inboundSchema.and(
|
|
89
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({ type: v.type })),
|
|
90
|
+
),
|
|
91
|
+
JMESPathExpression$inboundSchema.and(
|
|
92
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
93
|
+
type: v.type,
|
|
94
|
+
})),
|
|
95
|
+
),
|
|
96
|
+
JMESPathExpression$inboundSchema.and(
|
|
97
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({ type: v.type })),
|
|
98
|
+
),
|
|
99
|
+
],
|
|
100
|
+
);
|
|
101
|
+
/** @internal */
|
|
102
|
+
export type One$Outbound =
|
|
103
|
+
| (CelExpression$Outbound & { type: "cel" })
|
|
104
|
+
| (JMESPathExpression$Outbound & { type: "jmespath" })
|
|
105
|
+
| (JMESPathExpression$Outbound & { type: "jp" });
|
|
106
|
+
|
|
107
|
+
/** @internal */
|
|
108
|
+
export const One$outboundSchema: z.ZodType<One$Outbound, z.ZodTypeDef, One> = z
|
|
109
|
+
.union([
|
|
110
|
+
CelExpression$outboundSchema.and(
|
|
111
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({ type: v.type })),
|
|
112
|
+
),
|
|
113
|
+
JMESPathExpression$outboundSchema.and(
|
|
114
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
115
|
+
type: v.type,
|
|
116
|
+
})),
|
|
117
|
+
),
|
|
118
|
+
JMESPathExpression$outboundSchema.and(
|
|
119
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({ type: v.type })),
|
|
120
|
+
),
|
|
121
|
+
]);
|
|
122
|
+
|
|
123
|
+
export function oneToJSON(one: One): string {
|
|
124
|
+
return JSON.stringify(One$outboundSchema.parse(one));
|
|
125
|
+
}
|
|
126
|
+
export function oneFromJSON(
|
|
127
|
+
jsonString: string,
|
|
128
|
+
): SafeParseResult<One, SDKValidationError> {
|
|
129
|
+
return safeParse(
|
|
130
|
+
jsonString,
|
|
131
|
+
(x) => One$inboundSchema.parse(JSON.parse(x)),
|
|
132
|
+
`Failed to parse 'One' from JSON`,
|
|
133
|
+
);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/** @internal */
|
|
137
|
+
export const VariableValueFrom$inboundSchema: z.ZodType<
|
|
138
|
+
VariableValueFrom,
|
|
139
|
+
z.ZodTypeDef,
|
|
140
|
+
unknown
|
|
141
|
+
> = z.union([
|
|
142
|
+
CaseExpression$inboundSchema,
|
|
143
|
+
z.union([
|
|
144
|
+
CelExpression$inboundSchema.and(
|
|
145
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({ type: v.type })),
|
|
146
|
+
),
|
|
147
|
+
JMESPathExpression$inboundSchema.and(
|
|
148
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
149
|
+
type: v.type,
|
|
150
|
+
})),
|
|
151
|
+
),
|
|
152
|
+
JMESPathExpression$inboundSchema.and(
|
|
153
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({ type: v.type })),
|
|
154
|
+
),
|
|
155
|
+
]),
|
|
156
|
+
z.string(),
|
|
157
|
+
]);
|
|
158
|
+
/** @internal */
|
|
159
|
+
export type VariableValueFrom$Outbound =
|
|
160
|
+
| CaseExpression$Outbound
|
|
161
|
+
| (CelExpression$Outbound & { type: "cel" })
|
|
162
|
+
| (JMESPathExpression$Outbound & { type: "jmespath" })
|
|
163
|
+
| (JMESPathExpression$Outbound & { type: "jp" })
|
|
164
|
+
| string;
|
|
165
|
+
|
|
166
|
+
/** @internal */
|
|
167
|
+
export const VariableValueFrom$outboundSchema: z.ZodType<
|
|
168
|
+
VariableValueFrom$Outbound,
|
|
169
|
+
z.ZodTypeDef,
|
|
170
|
+
VariableValueFrom
|
|
171
|
+
> = z.union([
|
|
172
|
+
CaseExpression$outboundSchema,
|
|
173
|
+
z.union([
|
|
174
|
+
CelExpression$outboundSchema.and(
|
|
175
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({ type: v.type })),
|
|
176
|
+
),
|
|
177
|
+
JMESPathExpression$outboundSchema.and(
|
|
178
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
179
|
+
type: v.type,
|
|
180
|
+
})),
|
|
181
|
+
),
|
|
182
|
+
JMESPathExpression$outboundSchema.and(
|
|
183
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({ type: v.type })),
|
|
184
|
+
),
|
|
185
|
+
]),
|
|
186
|
+
z.string(),
|
|
187
|
+
]);
|
|
188
|
+
|
|
189
|
+
export function variableValueFromToJSON(
|
|
190
|
+
variableValueFrom: VariableValueFrom,
|
|
191
|
+
): string {
|
|
192
|
+
return JSON.stringify(
|
|
193
|
+
VariableValueFrom$outboundSchema.parse(variableValueFrom),
|
|
194
|
+
);
|
|
195
|
+
}
|
|
196
|
+
export function variableValueFromFromJSON(
|
|
197
|
+
jsonString: string,
|
|
198
|
+
): SafeParseResult<VariableValueFrom, SDKValidationError> {
|
|
199
|
+
return safeParse(
|
|
200
|
+
jsonString,
|
|
201
|
+
(x) => VariableValueFrom$inboundSchema.parse(JSON.parse(x)),
|
|
202
|
+
`Failed to parse 'VariableValueFrom' from JSON`,
|
|
203
|
+
);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
/** @internal */
|
|
207
|
+
export const VariableType$inboundSchema: z.ZodNativeEnum<typeof VariableType> =
|
|
208
|
+
z.nativeEnum(VariableType);
|
|
209
|
+
/** @internal */
|
|
210
|
+
export const VariableType$outboundSchema: z.ZodNativeEnum<typeof VariableType> =
|
|
211
|
+
VariableType$inboundSchema;
|
|
212
|
+
|
|
213
|
+
/** @internal */
|
|
214
|
+
export const Variable$inboundSchema: z.ZodType<
|
|
215
|
+
Variable,
|
|
216
|
+
z.ZodTypeDef,
|
|
217
|
+
unknown
|
|
218
|
+
> = z.object({
|
|
219
|
+
value: z.nullable(z.any()).optional(),
|
|
220
|
+
value_from: z.nullable(
|
|
221
|
+
z.union([
|
|
222
|
+
CaseExpression$inboundSchema,
|
|
223
|
+
z.union([
|
|
224
|
+
CelExpression$inboundSchema.and(
|
|
225
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({
|
|
226
|
+
type: v.type,
|
|
227
|
+
})),
|
|
228
|
+
),
|
|
229
|
+
JMESPathExpression$inboundSchema.and(
|
|
230
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
231
|
+
type: v.type,
|
|
232
|
+
})),
|
|
233
|
+
),
|
|
234
|
+
JMESPathExpression$inboundSchema.and(
|
|
235
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({
|
|
236
|
+
type: v.type,
|
|
237
|
+
})),
|
|
238
|
+
),
|
|
239
|
+
]),
|
|
240
|
+
z.string(),
|
|
241
|
+
]),
|
|
242
|
+
).optional(),
|
|
243
|
+
name: z.string(),
|
|
244
|
+
type: z.nullable(VariableType$inboundSchema).optional(),
|
|
245
|
+
description: z.nullable(z.string()).optional(),
|
|
246
|
+
title: z.nullable(z.string()).optional(),
|
|
247
|
+
format: z.nullable(z.string()).optional(),
|
|
248
|
+
pattern: z.nullable(z.string()).optional(),
|
|
249
|
+
enum: z.nullable(z.array(z.string())).optional(),
|
|
250
|
+
examples: z.nullable(z.array(z.any())).optional(),
|
|
251
|
+
}).transform((v) => {
|
|
252
|
+
return remap$(v, {
|
|
253
|
+
"value_from": "valueFrom",
|
|
254
|
+
});
|
|
255
|
+
});
|
|
256
|
+
/** @internal */
|
|
257
|
+
export type Variable$Outbound = {
|
|
258
|
+
value?: any | null | undefined;
|
|
259
|
+
value_from?:
|
|
260
|
+
| CaseExpression$Outbound
|
|
261
|
+
| (CelExpression$Outbound & { type: "cel" })
|
|
262
|
+
| (JMESPathExpression$Outbound & { type: "jmespath" })
|
|
263
|
+
| (JMESPathExpression$Outbound & { type: "jp" })
|
|
264
|
+
| string
|
|
265
|
+
| null
|
|
266
|
+
| undefined;
|
|
267
|
+
name: string;
|
|
268
|
+
type?: string | null | undefined;
|
|
269
|
+
description?: string | null | undefined;
|
|
270
|
+
title?: string | null | undefined;
|
|
271
|
+
format?: string | null | undefined;
|
|
272
|
+
pattern?: string | null | undefined;
|
|
273
|
+
enum?: Array<string> | null | undefined;
|
|
274
|
+
examples?: Array<any> | null | undefined;
|
|
275
|
+
};
|
|
276
|
+
|
|
277
|
+
/** @internal */
|
|
278
|
+
export const Variable$outboundSchema: z.ZodType<
|
|
279
|
+
Variable$Outbound,
|
|
280
|
+
z.ZodTypeDef,
|
|
281
|
+
Variable
|
|
282
|
+
> = z.object({
|
|
283
|
+
value: z.nullable(z.any()).optional(),
|
|
284
|
+
valueFrom: z.nullable(
|
|
285
|
+
z.union([
|
|
286
|
+
CaseExpression$outboundSchema,
|
|
287
|
+
z.union([
|
|
288
|
+
CelExpression$outboundSchema.and(
|
|
289
|
+
z.object({ type: z.literal("cel") }).transform((v) => ({
|
|
290
|
+
type: v.type,
|
|
291
|
+
})),
|
|
292
|
+
),
|
|
293
|
+
JMESPathExpression$outboundSchema.and(
|
|
294
|
+
z.object({ type: z.literal("jmespath") }).transform((v) => ({
|
|
295
|
+
type: v.type,
|
|
296
|
+
})),
|
|
297
|
+
),
|
|
298
|
+
JMESPathExpression$outboundSchema.and(
|
|
299
|
+
z.object({ type: z.literal("jp") }).transform((v) => ({
|
|
300
|
+
type: v.type,
|
|
301
|
+
})),
|
|
302
|
+
),
|
|
303
|
+
]),
|
|
304
|
+
z.string(),
|
|
305
|
+
]),
|
|
306
|
+
).optional(),
|
|
307
|
+
name: z.string(),
|
|
308
|
+
type: z.nullable(VariableType$outboundSchema).optional(),
|
|
309
|
+
description: z.nullable(z.string()).optional(),
|
|
310
|
+
title: z.nullable(z.string()).optional(),
|
|
311
|
+
format: z.nullable(z.string()).optional(),
|
|
312
|
+
pattern: z.nullable(z.string()).optional(),
|
|
313
|
+
enum: z.nullable(z.array(z.string())).optional(),
|
|
314
|
+
examples: z.nullable(z.array(z.any())).optional(),
|
|
315
|
+
}).transform((v) => {
|
|
316
|
+
return remap$(v, {
|
|
317
|
+
valueFrom: "value_from",
|
|
318
|
+
});
|
|
319
|
+
});
|
|
320
|
+
|
|
321
|
+
export function variableToJSON(variable: Variable): string {
|
|
322
|
+
return JSON.stringify(Variable$outboundSchema.parse(variable));
|
|
323
|
+
}
|
|
324
|
+
export function variableFromJSON(
|
|
325
|
+
jsonString: string,
|
|
326
|
+
): SafeParseResult<Variable, SDKValidationError> {
|
|
327
|
+
return safeParse(
|
|
328
|
+
jsonString,
|
|
329
|
+
(x) => Variable$inboundSchema.parse(JSON.parse(x)),
|
|
330
|
+
`Failed to parse 'Variable' from JSON`,
|
|
331
|
+
);
|
|
332
|
+
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import * as z from "zod/v3";
|
|
2
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
3
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
4
|
-
/**
|
|
5
|
-
* Metadata describing a context task driven by a tool call.
|
|
6
|
-
*/
|
|
7
|
-
export type ContextTask = {
|
|
8
|
-
/**
|
|
9
|
-
* The type of the task.
|
|
10
|
-
*/
|
|
11
|
-
type?: string | null | undefined;
|
|
12
|
-
/**
|
|
13
|
-
* A unique identifier for the task.
|
|
14
|
-
*/
|
|
15
|
-
id?: string | null | undefined;
|
|
16
|
-
additionalProperties?: {
|
|
17
|
-
[k: string]: any;
|
|
18
|
-
} | undefined;
|
|
19
|
-
};
|
|
20
|
-
/** @internal */
|
|
21
|
-
export declare const ContextTask$inboundSchema: z.ZodType<ContextTask, z.ZodTypeDef, unknown>;
|
|
22
|
-
/** @internal */
|
|
23
|
-
export type ContextTask$Outbound = {
|
|
24
|
-
type?: string | null | undefined;
|
|
25
|
-
id?: string | null | undefined;
|
|
26
|
-
[additionalProperties: string]: unknown;
|
|
27
|
-
};
|
|
28
|
-
/** @internal */
|
|
29
|
-
export declare const ContextTask$outboundSchema: z.ZodType<ContextTask$Outbound, z.ZodTypeDef, ContextTask>;
|
|
30
|
-
export declare function contextTaskToJSON(contextTask: ContextTask): string;
|
|
31
|
-
export declare function contextTaskFromJSON(jsonString: string): SafeParseResult<ContextTask, SDKValidationError>;
|
|
32
|
-
//# sourceMappingURL=contexttask.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contexttask.d.ts","sourceRoot":"","sources":["../../src/models/components/contexttask.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAM5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG;IACxB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACjC;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAC/B,oBAAoB,CAAC,EAAE;QAAE,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,GAAG,SAAS,CAAC;CACzD,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,yBAAyB,EAAE,CAAC,CAAC,OAAO,CAC/C,WAAW,EACX,CAAC,CAAC,UAAU,EACZ,OAAO,CAQR,CAAC;AACF,gBAAgB;AAChB,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACjC,EAAE,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAC/B,CAAC,oBAAoB,EAAE,MAAM,GAAG,OAAO,CAAC;CACzC,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,0BAA0B,EAAE,CAAC,CAAC,OAAO,CAChD,oBAAoB,EACpB,CAAC,CAAC,UAAU,EACZ,WAAW,CAYX,CAAC;AAEH,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,WAAW,GAAG,MAAM,CAElE;AACD,wBAAgB,mBAAmB,CACjC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,WAAW,EAAE,kBAAkB,CAAC,CAMlD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contexttask.js","sourceRoot":"","sources":["../../src/models/components/contexttask.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgEH,8CAEC;AACD,kDAQC;AAzED,0CAA4B;AAC5B,2DAA0D;AAC1D,qDAG8B;AAmB9B,gBAAgB;AACH,QAAA,yBAAyB,GAIlC,IAAA,6BAAiB,EACnB,CAAC,CAAC,MAAM,CAAC;IACP,IAAI,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACvC,EAAE,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;CACtC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,EACpB,sBAAsB,EACtB,IAAI,CACL,CAAC;AAQF,gBAAgB;AACH,QAAA,0BAA0B,GAInC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACvC,EAAE,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACrC,oBAAoB,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE;CACnD,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO;QACL,GAAG,CAAC,CAAC,oBAAoB;QACzB,GAAG,IAAA,qBAAM,EAAC,CAAC,EAAE;YACX,oBAAoB,EAAE,IAAI;SAC3B,CAAC;KACH,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,SAAgB,iBAAiB,CAAC,WAAwB;IACxD,OAAO,IAAI,CAAC,SAAS,CAAC,kCAA0B,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC;AACvE,CAAC;AACD,SAAgB,mBAAmB,CACjC,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,iCAAyB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACrD,yCAAyC,CAC1C,CAAC;AACJ,CAAC"}
|
|
@@ -1,78 +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 { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
-
import {
|
|
8
|
-
collectExtraKeys as collectExtraKeys$,
|
|
9
|
-
safeParse,
|
|
10
|
-
} from "../../lib/schemas.js";
|
|
11
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
12
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Metadata describing a context task driven by a tool call.
|
|
16
|
-
*/
|
|
17
|
-
export type ContextTask = {
|
|
18
|
-
/**
|
|
19
|
-
* The type of the task.
|
|
20
|
-
*/
|
|
21
|
-
type?: string | null | undefined;
|
|
22
|
-
/**
|
|
23
|
-
* A unique identifier for the task.
|
|
24
|
-
*/
|
|
25
|
-
id?: string | null | undefined;
|
|
26
|
-
additionalProperties?: { [k: string]: any } | undefined;
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
/** @internal */
|
|
30
|
-
export const ContextTask$inboundSchema: z.ZodType<
|
|
31
|
-
ContextTask,
|
|
32
|
-
z.ZodTypeDef,
|
|
33
|
-
unknown
|
|
34
|
-
> = collectExtraKeys$(
|
|
35
|
-
z.object({
|
|
36
|
-
type: z.nullable(z.string()).optional(),
|
|
37
|
-
id: z.nullable(z.string()).optional(),
|
|
38
|
-
}).catchall(z.any()),
|
|
39
|
-
"additionalProperties",
|
|
40
|
-
true,
|
|
41
|
-
);
|
|
42
|
-
/** @internal */
|
|
43
|
-
export type ContextTask$Outbound = {
|
|
44
|
-
type?: string | null | undefined;
|
|
45
|
-
id?: string | null | undefined;
|
|
46
|
-
[additionalProperties: string]: unknown;
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
/** @internal */
|
|
50
|
-
export const ContextTask$outboundSchema: z.ZodType<
|
|
51
|
-
ContextTask$Outbound,
|
|
52
|
-
z.ZodTypeDef,
|
|
53
|
-
ContextTask
|
|
54
|
-
> = z.object({
|
|
55
|
-
type: z.nullable(z.string()).optional(),
|
|
56
|
-
id: z.nullable(z.string()).optional(),
|
|
57
|
-
additionalProperties: z.record(z.any()).optional(),
|
|
58
|
-
}).transform((v) => {
|
|
59
|
-
return {
|
|
60
|
-
...v.additionalProperties,
|
|
61
|
-
...remap$(v, {
|
|
62
|
-
additionalProperties: null,
|
|
63
|
-
}),
|
|
64
|
-
};
|
|
65
|
-
});
|
|
66
|
-
|
|
67
|
-
export function contextTaskToJSON(contextTask: ContextTask): string {
|
|
68
|
-
return JSON.stringify(ContextTask$outboundSchema.parse(contextTask));
|
|
69
|
-
}
|
|
70
|
-
export function contextTaskFromJSON(
|
|
71
|
-
jsonString: string,
|
|
72
|
-
): SafeParseResult<ContextTask, SDKValidationError> {
|
|
73
|
-
return safeParse(
|
|
74
|
-
jsonString,
|
|
75
|
-
(x) => ContextTask$inboundSchema.parse(JSON.parse(x)),
|
|
76
|
-
`Failed to parse 'ContextTask' from JSON`,
|
|
77
|
-
);
|
|
78
|
-
}
|