syllable-sdk 0.1.0-alpha.39 → 0.1.0-alpha.40
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 +24 -16
- package/docs/sdks/dashboards/README.md +178 -8
- package/docs/sdks/tools/README.md +12 -4
- package/docs/sdks/v1/README.md +178 -8
- package/funcs/dashboardsPostGetDashboard.d.ts +20 -0
- package/funcs/dashboardsPostGetDashboard.d.ts.map +1 -0
- package/funcs/dashboardsPostGetDashboard.js +108 -0
- package/funcs/dashboardsPostGetDashboard.js.map +1 -0
- package/funcs/dashboardsPostListDashboard.d.ts +20 -0
- package/funcs/dashboardsPostListDashboard.d.ts.map +1 -0
- package/funcs/dashboardsPostListDashboard.js +116 -0
- package/funcs/dashboardsPostListDashboard.js.map +1 -0
- package/funcs/dashboardsPostSessionEventsDashboard.d.ts +3 -0
- package/funcs/dashboardsPostSessionEventsDashboard.d.ts.map +1 -1
- package/funcs/dashboardsPostSessionEventsDashboard.js +3 -0
- package/funcs/dashboardsPostSessionEventsDashboard.js.map +1 -1
- package/funcs/dashboardsPostSessionSummaryDashboard.d.ts +3 -0
- package/funcs/dashboardsPostSessionSummaryDashboard.d.ts.map +1 -1
- package/funcs/dashboardsPostSessionSummaryDashboard.js +3 -0
- package/funcs/dashboardsPostSessionSummaryDashboard.js.map +1 -1
- package/funcs/dashboardsPostSessionTransfersDashboard.d.ts +3 -0
- package/funcs/dashboardsPostSessionTransfersDashboard.d.ts.map +1 -1
- package/funcs/dashboardsPostSessionTransfersDashboard.js +3 -0
- package/funcs/dashboardsPostSessionTransfersDashboard.js.map +1 -1
- package/funcs/dashboardsPostSessionsDashboard.d.ts +3 -0
- package/funcs/dashboardsPostSessionsDashboard.d.ts.map +1 -1
- package/funcs/dashboardsPostSessionsDashboard.js +3 -0
- package/funcs/dashboardsPostSessionsDashboard.js.map +1 -1
- package/funcs/v1PostGetDashboard.d.ts +20 -0
- package/funcs/v1PostGetDashboard.d.ts.map +1 -0
- package/funcs/v1PostGetDashboard.js +108 -0
- package/funcs/v1PostGetDashboard.js.map +1 -0
- package/funcs/v1PostListDashboard.d.ts +20 -0
- package/funcs/v1PostListDashboard.d.ts.map +1 -0
- package/funcs/v1PostListDashboard.js +116 -0
- package/funcs/v1PostListDashboard.js.map +1 -0
- package/funcs/v1PostSessionEventsDashboard.d.ts +3 -0
- package/funcs/v1PostSessionEventsDashboard.d.ts.map +1 -1
- package/funcs/v1PostSessionEventsDashboard.js +3 -0
- package/funcs/v1PostSessionEventsDashboard.js.map +1 -1
- package/funcs/v1PostSessionSummaryDashboard.d.ts +3 -0
- package/funcs/v1PostSessionSummaryDashboard.d.ts.map +1 -1
- package/funcs/v1PostSessionSummaryDashboard.js +3 -0
- package/funcs/v1PostSessionSummaryDashboard.js.map +1 -1
- package/funcs/v1PostSessionTransfersDashboard.d.ts +3 -0
- package/funcs/v1PostSessionTransfersDashboard.d.ts.map +1 -1
- package/funcs/v1PostSessionTransfersDashboard.js +3 -0
- package/funcs/v1PostSessionTransfersDashboard.js.map +1 -1
- package/funcs/v1PostSessionsDashboard.d.ts +3 -0
- package/funcs/v1PostSessionsDashboard.d.ts.map +1 -1
- package/funcs/v1PostSessionsDashboard.js +3 -0
- package/funcs/v1PostSessionsDashboard.js.map +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/dashboard.d.ts +3 -0
- package/models/components/dashboard.d.ts.map +1 -1
- package/models/components/dashboard.js.map +1 -1
- package/models/components/dashboardproperties.d.ts +37 -0
- package/models/components/dashboardproperties.d.ts.map +1 -0
- package/models/components/dashboardproperties.js +53 -0
- package/models/components/dashboardproperties.js.map +1 -0
- package/models/components/dashboardresponse.d.ts +50 -0
- package/models/components/dashboardresponse.d.ts.map +1 -0
- package/models/components/dashboardresponse.js +74 -0
- package/models/components/dashboardresponse.js.map +1 -0
- package/models/components/dashboardtokenresponse.d.ts +65 -0
- package/models/components/dashboardtokenresponse.d.ts.map +1 -0
- package/models/components/dashboardtokenresponse.js +86 -0
- package/models/components/dashboardtokenresponse.js.map +1 -0
- package/models/components/index.d.ts +4 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +4 -0
- package/models/components/index.js.map +1 -1
- package/models/components/listresponsedashboardresponse.d.ts +38 -0
- package/models/components/listresponsedashboardresponse.d.ts.map +1 -0
- package/models/components/listresponsedashboardresponse.js +81 -0
- package/models/components/listresponsedashboardresponse.js.map +1 -0
- package/models/components/tooldefinition.d.ts +8 -50
- package/models/components/tooldefinition.d.ts.map +1 -1
- package/models/components/tooldefinition.js +7 -68
- package/models/components/tooldefinition.js.map +1 -1
- package/models/components/toolfunction.d.ts +2 -26
- package/models/components/toolfunction.d.ts.map +1 -1
- package/models/components/toolfunction.js +3 -26
- package/models/components/toolfunction.js.map +1 -1
- 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/postgetdashboard.d.ts +29 -0
- package/models/operations/postgetdashboard.d.ts.map +1 -0
- package/models/operations/postgetdashboard.js +68 -0
- package/models/operations/postgetdashboard.js.map +1 -0
- package/models/operations/postlistdashboard.d.ts +46 -0
- package/models/operations/postlistdashboard.d.ts.map +1 -0
- package/models/operations/postlistdashboard.js +101 -0
- package/models/operations/postlistdashboard.js.map +1 -0
- package/openapi.json +381 -11
- package/package.json +1 -1
- package/sdk/dashboards.d.ts +33 -0
- package/sdk/dashboards.d.ts.map +1 -1
- package/sdk/dashboards.js +38 -0
- package/sdk/dashboards.js.map +1 -1
- package/sdk/v1.d.ts +33 -0
- package/sdk/v1.d.ts.map +1 -1
- package/sdk/v1.js +38 -0
- package/sdk/v1.js.map +1 -1
- package/src/funcs/dashboardsPostGetDashboard.ts +142 -0
- package/src/funcs/dashboardsPostListDashboard.ts +150 -0
- package/src/funcs/dashboardsPostSessionEventsDashboard.ts +3 -0
- package/src/funcs/dashboardsPostSessionSummaryDashboard.ts +3 -0
- package/src/funcs/dashboardsPostSessionTransfersDashboard.ts +3 -0
- package/src/funcs/dashboardsPostSessionsDashboard.ts +3 -0
- package/src/funcs/v1PostGetDashboard.ts +142 -0
- package/src/funcs/v1PostListDashboard.ts +150 -0
- package/src/funcs/v1PostSessionEventsDashboard.ts +3 -0
- package/src/funcs/v1PostSessionSummaryDashboard.ts +3 -0
- package/src/funcs/v1PostSessionTransfersDashboard.ts +3 -0
- package/src/funcs/v1PostSessionsDashboard.ts +3 -0
- package/src/lib/config.ts +2 -2
- package/src/models/components/dashboard.ts +3 -0
- package/src/models/components/dashboardproperties.ts +36 -0
- package/src/models/components/dashboardresponse.ts +102 -0
- package/src/models/components/dashboardtokenresponse.ts +129 -0
- package/src/models/components/index.ts +4 -0
- package/src/models/components/listresponsedashboardresponse.ts +103 -0
- package/src/models/components/tooldefinition.ts +12 -107
- package/src/models/components/toolfunction.ts +4 -53
- package/src/models/operations/index.ts +2 -0
- package/src/models/operations/postgetdashboard.ts +75 -0
- package/src/models/operations/postlistdashboard.ts +124 -0
- package/src/sdk/dashboards.ts +55 -0
- package/src/sdk/v1.ts +55 -0
|
@@ -34,14 +34,10 @@ export const Type = {
|
|
|
34
34
|
} as const;
|
|
35
35
|
export type Type = ClosedEnum<typeof Type>;
|
|
36
36
|
|
|
37
|
-
export type One = {};
|
|
38
|
-
|
|
39
37
|
/**
|
|
40
38
|
* The default values for the parameters of the function/tool call.
|
|
41
39
|
*/
|
|
42
|
-
export type Defaults =
|
|
43
|
-
|
|
44
|
-
export type Result = {};
|
|
40
|
+
export type Defaults = any | { [k: string]: ToolParameterDefault };
|
|
45
41
|
|
|
46
42
|
/**
|
|
47
43
|
* A tool that can be called from an LLM during the conversation.
|
|
@@ -62,11 +58,11 @@ export type ToolDefinition = {
|
|
|
62
58
|
/**
|
|
63
59
|
* The default values for the parameters of the function/tool call.
|
|
64
60
|
*/
|
|
65
|
-
defaults?:
|
|
61
|
+
defaults?: any | { [k: string]: ToolParameterDefault } | null | undefined;
|
|
66
62
|
/**
|
|
67
63
|
* The optional result of the tool call. Only used for `context` tools.
|
|
68
64
|
*/
|
|
69
|
-
result?:
|
|
65
|
+
result?: any | null | undefined;
|
|
70
66
|
};
|
|
71
67
|
|
|
72
68
|
/** @internal */
|
|
@@ -89,56 +85,15 @@ export namespace Type$ {
|
|
|
89
85
|
export const outboundSchema = Type$outboundSchema;
|
|
90
86
|
}
|
|
91
87
|
|
|
92
|
-
/** @internal */
|
|
93
|
-
export const One$inboundSchema: z.ZodType<One, z.ZodTypeDef, unknown> = z
|
|
94
|
-
.object({});
|
|
95
|
-
|
|
96
|
-
/** @internal */
|
|
97
|
-
export type One$Outbound = {};
|
|
98
|
-
|
|
99
|
-
/** @internal */
|
|
100
|
-
export const One$outboundSchema: z.ZodType<One$Outbound, z.ZodTypeDef, One> = z
|
|
101
|
-
.object({});
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
* @internal
|
|
105
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
106
|
-
*/
|
|
107
|
-
export namespace One$ {
|
|
108
|
-
/** @deprecated use `One$inboundSchema` instead. */
|
|
109
|
-
export const inboundSchema = One$inboundSchema;
|
|
110
|
-
/** @deprecated use `One$outboundSchema` instead. */
|
|
111
|
-
export const outboundSchema = One$outboundSchema;
|
|
112
|
-
/** @deprecated use `One$Outbound` instead. */
|
|
113
|
-
export type Outbound = One$Outbound;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
export function oneToJSON(one: One): string {
|
|
117
|
-
return JSON.stringify(One$outboundSchema.parse(one));
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
export function oneFromJSON(
|
|
121
|
-
jsonString: string,
|
|
122
|
-
): SafeParseResult<One, SDKValidationError> {
|
|
123
|
-
return safeParse(
|
|
124
|
-
jsonString,
|
|
125
|
-
(x) => One$inboundSchema.parse(JSON.parse(x)),
|
|
126
|
-
`Failed to parse 'One' from JSON`,
|
|
127
|
-
);
|
|
128
|
-
}
|
|
129
|
-
|
|
130
88
|
/** @internal */
|
|
131
89
|
export const Defaults$inboundSchema: z.ZodType<
|
|
132
90
|
Defaults,
|
|
133
91
|
z.ZodTypeDef,
|
|
134
92
|
unknown
|
|
135
|
-
> = z.union([
|
|
136
|
-
z.lazy(() => One$inboundSchema),
|
|
137
|
-
z.record(ToolParameterDefault$inboundSchema),
|
|
138
|
-
]);
|
|
93
|
+
> = z.union([z.any(), z.record(ToolParameterDefault$inboundSchema)]);
|
|
139
94
|
|
|
140
95
|
/** @internal */
|
|
141
|
-
export type Defaults$Outbound =
|
|
96
|
+
export type Defaults$Outbound = any | {
|
|
142
97
|
[k: string]: ToolParameterDefault$Outbound;
|
|
143
98
|
};
|
|
144
99
|
|
|
@@ -147,10 +102,7 @@ export const Defaults$outboundSchema: z.ZodType<
|
|
|
147
102
|
Defaults$Outbound,
|
|
148
103
|
z.ZodTypeDef,
|
|
149
104
|
Defaults
|
|
150
|
-
> = z.union([
|
|
151
|
-
z.lazy(() => One$outboundSchema),
|
|
152
|
-
z.record(ToolParameterDefault$outboundSchema),
|
|
153
|
-
]);
|
|
105
|
+
> = z.union([z.any(), z.record(ToolParameterDefault$outboundSchema)]);
|
|
154
106
|
|
|
155
107
|
/**
|
|
156
108
|
* @internal
|
|
@@ -179,47 +131,6 @@ export function defaultsFromJSON(
|
|
|
179
131
|
);
|
|
180
132
|
}
|
|
181
133
|
|
|
182
|
-
/** @internal */
|
|
183
|
-
export const Result$inboundSchema: z.ZodType<Result, z.ZodTypeDef, unknown> = z
|
|
184
|
-
.object({});
|
|
185
|
-
|
|
186
|
-
/** @internal */
|
|
187
|
-
export type Result$Outbound = {};
|
|
188
|
-
|
|
189
|
-
/** @internal */
|
|
190
|
-
export const Result$outboundSchema: z.ZodType<
|
|
191
|
-
Result$Outbound,
|
|
192
|
-
z.ZodTypeDef,
|
|
193
|
-
Result
|
|
194
|
-
> = z.object({});
|
|
195
|
-
|
|
196
|
-
/**
|
|
197
|
-
* @internal
|
|
198
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
199
|
-
*/
|
|
200
|
-
export namespace Result$ {
|
|
201
|
-
/** @deprecated use `Result$inboundSchema` instead. */
|
|
202
|
-
export const inboundSchema = Result$inboundSchema;
|
|
203
|
-
/** @deprecated use `Result$outboundSchema` instead. */
|
|
204
|
-
export const outboundSchema = Result$outboundSchema;
|
|
205
|
-
/** @deprecated use `Result$Outbound` instead. */
|
|
206
|
-
export type Outbound = Result$Outbound;
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
export function resultToJSON(result: Result): string {
|
|
210
|
-
return JSON.stringify(Result$outboundSchema.parse(result));
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
export function resultFromJSON(
|
|
214
|
-
jsonString: string,
|
|
215
|
-
): SafeParseResult<Result, SDKValidationError> {
|
|
216
|
-
return safeParse(
|
|
217
|
-
jsonString,
|
|
218
|
-
(x) => Result$inboundSchema.parse(JSON.parse(x)),
|
|
219
|
-
`Failed to parse 'Result' from JSON`,
|
|
220
|
-
);
|
|
221
|
-
}
|
|
222
|
-
|
|
223
134
|
/** @internal */
|
|
224
135
|
export const ToolDefinition$inboundSchema: z.ZodType<
|
|
225
136
|
ToolDefinition,
|
|
@@ -230,12 +141,9 @@ export const ToolDefinition$inboundSchema: z.ZodType<
|
|
|
230
141
|
tool: InternalTool$inboundSchema,
|
|
231
142
|
endpoint: z.nullable(ToolHttpEndpoint$inboundSchema).optional(),
|
|
232
143
|
defaults: z.nullable(
|
|
233
|
-
z.union([
|
|
234
|
-
z.lazy(() => One$inboundSchema),
|
|
235
|
-
z.record(ToolParameterDefault$inboundSchema),
|
|
236
|
-
]),
|
|
144
|
+
z.union([z.any(), z.record(ToolParameterDefault$inboundSchema)]),
|
|
237
145
|
).optional(),
|
|
238
|
-
result: z.nullable(z.
|
|
146
|
+
result: z.nullable(z.any()).optional(),
|
|
239
147
|
});
|
|
240
148
|
|
|
241
149
|
/** @internal */
|
|
@@ -244,11 +152,11 @@ export type ToolDefinition$Outbound = {
|
|
|
244
152
|
tool: InternalTool$Outbound;
|
|
245
153
|
endpoint?: ToolHttpEndpoint$Outbound | null | undefined;
|
|
246
154
|
defaults?:
|
|
247
|
-
|
|
|
155
|
+
| any
|
|
248
156
|
| { [k: string]: ToolParameterDefault$Outbound }
|
|
249
157
|
| null
|
|
250
158
|
| undefined;
|
|
251
|
-
result?:
|
|
159
|
+
result?: any | null | undefined;
|
|
252
160
|
};
|
|
253
161
|
|
|
254
162
|
/** @internal */
|
|
@@ -261,12 +169,9 @@ export const ToolDefinition$outboundSchema: z.ZodType<
|
|
|
261
169
|
tool: InternalTool$outboundSchema,
|
|
262
170
|
endpoint: z.nullable(ToolHttpEndpoint$outboundSchema).optional(),
|
|
263
171
|
defaults: z.nullable(
|
|
264
|
-
z.union([
|
|
265
|
-
z.lazy(() => One$outboundSchema),
|
|
266
|
-
z.record(ToolParameterDefault$outboundSchema),
|
|
267
|
-
]),
|
|
172
|
+
z.union([z.any(), z.record(ToolParameterDefault$outboundSchema)]),
|
|
268
173
|
).optional(),
|
|
269
|
-
result: z.nullable(z.
|
|
174
|
+
result: z.nullable(z.any()).optional(),
|
|
270
175
|
});
|
|
271
176
|
|
|
272
177
|
/**
|
|
@@ -7,11 +7,6 @@ import { safeParse } from "../../lib/schemas.js";
|
|
|
7
7
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
8
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
9
|
|
|
10
|
-
/**
|
|
11
|
-
* The JSON Schema of parameters of the function/tool call.
|
|
12
|
-
*/
|
|
13
|
-
export type ParametersT = {};
|
|
14
|
-
|
|
15
10
|
/**
|
|
16
11
|
* A function available to an agent.
|
|
17
12
|
*
|
|
@@ -32,53 +27,9 @@ export type ToolFunction = {
|
|
|
32
27
|
/**
|
|
33
28
|
* The JSON Schema of parameters of the function/tool call.
|
|
34
29
|
*/
|
|
35
|
-
parameters
|
|
30
|
+
parameters?: any | undefined;
|
|
36
31
|
};
|
|
37
32
|
|
|
38
|
-
/** @internal */
|
|
39
|
-
export const ParametersT$inboundSchema: z.ZodType<
|
|
40
|
-
ParametersT,
|
|
41
|
-
z.ZodTypeDef,
|
|
42
|
-
unknown
|
|
43
|
-
> = z.object({});
|
|
44
|
-
|
|
45
|
-
/** @internal */
|
|
46
|
-
export type ParametersT$Outbound = {};
|
|
47
|
-
|
|
48
|
-
/** @internal */
|
|
49
|
-
export const ParametersT$outboundSchema: z.ZodType<
|
|
50
|
-
ParametersT$Outbound,
|
|
51
|
-
z.ZodTypeDef,
|
|
52
|
-
ParametersT
|
|
53
|
-
> = z.object({});
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* @internal
|
|
57
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
58
|
-
*/
|
|
59
|
-
export namespace ParametersT$ {
|
|
60
|
-
/** @deprecated use `ParametersT$inboundSchema` instead. */
|
|
61
|
-
export const inboundSchema = ParametersT$inboundSchema;
|
|
62
|
-
/** @deprecated use `ParametersT$outboundSchema` instead. */
|
|
63
|
-
export const outboundSchema = ParametersT$outboundSchema;
|
|
64
|
-
/** @deprecated use `ParametersT$Outbound` instead. */
|
|
65
|
-
export type Outbound = ParametersT$Outbound;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export function parametersToJSON(parametersT: ParametersT): string {
|
|
69
|
-
return JSON.stringify(ParametersT$outboundSchema.parse(parametersT));
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
export function parametersFromJSON(
|
|
73
|
-
jsonString: string,
|
|
74
|
-
): SafeParseResult<ParametersT, SDKValidationError> {
|
|
75
|
-
return safeParse(
|
|
76
|
-
jsonString,
|
|
77
|
-
(x) => ParametersT$inboundSchema.parse(JSON.parse(x)),
|
|
78
|
-
`Failed to parse 'ParametersT' from JSON`,
|
|
79
|
-
);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
33
|
/** @internal */
|
|
83
34
|
export const ToolFunction$inboundSchema: z.ZodType<
|
|
84
35
|
ToolFunction,
|
|
@@ -87,14 +38,14 @@ export const ToolFunction$inboundSchema: z.ZodType<
|
|
|
87
38
|
> = z.object({
|
|
88
39
|
name: z.string(),
|
|
89
40
|
description: z.string(),
|
|
90
|
-
parameters: z.
|
|
41
|
+
parameters: z.any().optional(),
|
|
91
42
|
});
|
|
92
43
|
|
|
93
44
|
/** @internal */
|
|
94
45
|
export type ToolFunction$Outbound = {
|
|
95
46
|
name: string;
|
|
96
47
|
description: string;
|
|
97
|
-
parameters
|
|
48
|
+
parameters?: any | undefined;
|
|
98
49
|
};
|
|
99
50
|
|
|
100
51
|
/** @internal */
|
|
@@ -105,7 +56,7 @@ export const ToolFunction$outboundSchema: z.ZodType<
|
|
|
105
56
|
> = z.object({
|
|
106
57
|
name: z.string(),
|
|
107
58
|
description: z.string(),
|
|
108
|
-
parameters: z.
|
|
59
|
+
parameters: z.any().optional(),
|
|
109
60
|
});
|
|
110
61
|
|
|
111
62
|
/**
|
|
@@ -21,6 +21,8 @@ export * from "./datasourcesgetbyname.js";
|
|
|
21
21
|
export * from "./datasourceslist.js";
|
|
22
22
|
export * from "./eventslist.js";
|
|
23
23
|
export * from "./generatesessionrecordingurls.js";
|
|
24
|
+
export * from "./postgetdashboard.js";
|
|
25
|
+
export * from "./postlistdashboard.js";
|
|
24
26
|
export * from "./promptsdelete.js";
|
|
25
27
|
export * from "./promptsgetbyid.js";
|
|
26
28
|
export * from "./promptshistory.js";
|
|
@@ -0,0 +1,75 @@
|
|
|
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 PostGetDashboardRequest = {
|
|
12
|
+
dashboardName: string;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const PostGetDashboardRequest$inboundSchema: z.ZodType<
|
|
17
|
+
PostGetDashboardRequest,
|
|
18
|
+
z.ZodTypeDef,
|
|
19
|
+
unknown
|
|
20
|
+
> = z.object({
|
|
21
|
+
dashboard_name: z.string(),
|
|
22
|
+
}).transform((v) => {
|
|
23
|
+
return remap$(v, {
|
|
24
|
+
"dashboard_name": "dashboardName",
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
/** @internal */
|
|
29
|
+
export type PostGetDashboardRequest$Outbound = {
|
|
30
|
+
dashboard_name: string;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
/** @internal */
|
|
34
|
+
export const PostGetDashboardRequest$outboundSchema: z.ZodType<
|
|
35
|
+
PostGetDashboardRequest$Outbound,
|
|
36
|
+
z.ZodTypeDef,
|
|
37
|
+
PostGetDashboardRequest
|
|
38
|
+
> = z.object({
|
|
39
|
+
dashboardName: z.string(),
|
|
40
|
+
}).transform((v) => {
|
|
41
|
+
return remap$(v, {
|
|
42
|
+
dashboardName: "dashboard_name",
|
|
43
|
+
});
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* @internal
|
|
48
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
49
|
+
*/
|
|
50
|
+
export namespace PostGetDashboardRequest$ {
|
|
51
|
+
/** @deprecated use `PostGetDashboardRequest$inboundSchema` instead. */
|
|
52
|
+
export const inboundSchema = PostGetDashboardRequest$inboundSchema;
|
|
53
|
+
/** @deprecated use `PostGetDashboardRequest$outboundSchema` instead. */
|
|
54
|
+
export const outboundSchema = PostGetDashboardRequest$outboundSchema;
|
|
55
|
+
/** @deprecated use `PostGetDashboardRequest$Outbound` instead. */
|
|
56
|
+
export type Outbound = PostGetDashboardRequest$Outbound;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function postGetDashboardRequestToJSON(
|
|
60
|
+
postGetDashboardRequest: PostGetDashboardRequest,
|
|
61
|
+
): string {
|
|
62
|
+
return JSON.stringify(
|
|
63
|
+
PostGetDashboardRequest$outboundSchema.parse(postGetDashboardRequest),
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function postGetDashboardRequestFromJSON(
|
|
68
|
+
jsonString: string,
|
|
69
|
+
): SafeParseResult<PostGetDashboardRequest, SDKValidationError> {
|
|
70
|
+
return safeParse(
|
|
71
|
+
jsonString,
|
|
72
|
+
(x) => PostGetDashboardRequest$inboundSchema.parse(JSON.parse(x)),
|
|
73
|
+
`Failed to parse 'PostGetDashboardRequest' from JSON`,
|
|
74
|
+
);
|
|
75
|
+
}
|
|
@@ -0,0 +1,124 @@
|
|
|
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 * as components from "../components/index.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
|
|
12
|
+
export type PostListDashboardRequest = {
|
|
13
|
+
page?: number | null | undefined;
|
|
14
|
+
limit?: number | undefined;
|
|
15
|
+
searchFields?: Array<components.DashboardProperties> | undefined;
|
|
16
|
+
searchFieldValues?: Array<string> | undefined;
|
|
17
|
+
orderBy?: components.DashboardProperties | null | undefined;
|
|
18
|
+
orderByDirection?: components.OrderByDirection | null | undefined;
|
|
19
|
+
fields?: Array<components.DashboardProperties> | null | undefined;
|
|
20
|
+
startDatetime?: string | null | undefined;
|
|
21
|
+
endDatetime?: string | null | undefined;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
/** @internal */
|
|
25
|
+
export const PostListDashboardRequest$inboundSchema: z.ZodType<
|
|
26
|
+
PostListDashboardRequest,
|
|
27
|
+
z.ZodTypeDef,
|
|
28
|
+
unknown
|
|
29
|
+
> = z.object({
|
|
30
|
+
page: z.nullable(z.number().int()).optional(),
|
|
31
|
+
limit: z.number().int().default(25),
|
|
32
|
+
search_fields: z.array(components.DashboardProperties$inboundSchema)
|
|
33
|
+
.optional(),
|
|
34
|
+
search_field_values: z.array(z.string()).optional(),
|
|
35
|
+
order_by: z.nullable(components.DashboardProperties$inboundSchema).optional(),
|
|
36
|
+
order_by_direction: z.nullable(components.OrderByDirection$inboundSchema)
|
|
37
|
+
.optional(),
|
|
38
|
+
fields: z.nullable(z.array(components.DashboardProperties$inboundSchema))
|
|
39
|
+
.optional(),
|
|
40
|
+
start_datetime: z.nullable(z.string()).optional(),
|
|
41
|
+
end_datetime: z.nullable(z.string()).optional(),
|
|
42
|
+
}).transform((v) => {
|
|
43
|
+
return remap$(v, {
|
|
44
|
+
"search_fields": "searchFields",
|
|
45
|
+
"search_field_values": "searchFieldValues",
|
|
46
|
+
"order_by": "orderBy",
|
|
47
|
+
"order_by_direction": "orderByDirection",
|
|
48
|
+
"start_datetime": "startDatetime",
|
|
49
|
+
"end_datetime": "endDatetime",
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
/** @internal */
|
|
54
|
+
export type PostListDashboardRequest$Outbound = {
|
|
55
|
+
page?: number | null | undefined;
|
|
56
|
+
limit: number;
|
|
57
|
+
search_fields?: Array<string> | undefined;
|
|
58
|
+
search_field_values?: Array<string> | undefined;
|
|
59
|
+
order_by?: string | null | undefined;
|
|
60
|
+
order_by_direction?: string | null | undefined;
|
|
61
|
+
fields?: Array<string> | null | undefined;
|
|
62
|
+
start_datetime?: string | null | undefined;
|
|
63
|
+
end_datetime?: string | null | undefined;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
/** @internal */
|
|
67
|
+
export const PostListDashboardRequest$outboundSchema: z.ZodType<
|
|
68
|
+
PostListDashboardRequest$Outbound,
|
|
69
|
+
z.ZodTypeDef,
|
|
70
|
+
PostListDashboardRequest
|
|
71
|
+
> = z.object({
|
|
72
|
+
page: z.nullable(z.number().int()).optional(),
|
|
73
|
+
limit: z.number().int().default(25),
|
|
74
|
+
searchFields: z.array(components.DashboardProperties$outboundSchema)
|
|
75
|
+
.optional(),
|
|
76
|
+
searchFieldValues: z.array(z.string()).optional(),
|
|
77
|
+
orderBy: z.nullable(components.DashboardProperties$outboundSchema).optional(),
|
|
78
|
+
orderByDirection: z.nullable(components.OrderByDirection$outboundSchema)
|
|
79
|
+
.optional(),
|
|
80
|
+
fields: z.nullable(z.array(components.DashboardProperties$outboundSchema))
|
|
81
|
+
.optional(),
|
|
82
|
+
startDatetime: z.nullable(z.string()).optional(),
|
|
83
|
+
endDatetime: z.nullable(z.string()).optional(),
|
|
84
|
+
}).transform((v) => {
|
|
85
|
+
return remap$(v, {
|
|
86
|
+
searchFields: "search_fields",
|
|
87
|
+
searchFieldValues: "search_field_values",
|
|
88
|
+
orderBy: "order_by",
|
|
89
|
+
orderByDirection: "order_by_direction",
|
|
90
|
+
startDatetime: "start_datetime",
|
|
91
|
+
endDatetime: "end_datetime",
|
|
92
|
+
});
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* @internal
|
|
97
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
98
|
+
*/
|
|
99
|
+
export namespace PostListDashboardRequest$ {
|
|
100
|
+
/** @deprecated use `PostListDashboardRequest$inboundSchema` instead. */
|
|
101
|
+
export const inboundSchema = PostListDashboardRequest$inboundSchema;
|
|
102
|
+
/** @deprecated use `PostListDashboardRequest$outboundSchema` instead. */
|
|
103
|
+
export const outboundSchema = PostListDashboardRequest$outboundSchema;
|
|
104
|
+
/** @deprecated use `PostListDashboardRequest$Outbound` instead. */
|
|
105
|
+
export type Outbound = PostListDashboardRequest$Outbound;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function postListDashboardRequestToJSON(
|
|
109
|
+
postListDashboardRequest: PostListDashboardRequest,
|
|
110
|
+
): string {
|
|
111
|
+
return JSON.stringify(
|
|
112
|
+
PostListDashboardRequest$outboundSchema.parse(postListDashboardRequest),
|
|
113
|
+
);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export function postListDashboardRequestFromJSON(
|
|
117
|
+
jsonString: string,
|
|
118
|
+
): SafeParseResult<PostListDashboardRequest, SDKValidationError> {
|
|
119
|
+
return safeParse(
|
|
120
|
+
jsonString,
|
|
121
|
+
(x) => PostListDashboardRequest$inboundSchema.parse(JSON.parse(x)),
|
|
122
|
+
`Failed to parse 'PostListDashboardRequest' from JSON`,
|
|
123
|
+
);
|
|
124
|
+
}
|
package/src/sdk/dashboards.ts
CHANGED
|
@@ -2,15 +2,58 @@
|
|
|
2
2
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
+
import { dashboardsPostGetDashboard } from "../funcs/dashboardsPostGetDashboard.js";
|
|
6
|
+
import { dashboardsPostListDashboard } from "../funcs/dashboardsPostListDashboard.js";
|
|
5
7
|
import { dashboardsPostSessionEventsDashboard } from "../funcs/dashboardsPostSessionEventsDashboard.js";
|
|
6
8
|
import { dashboardsPostSessionsDashboard } from "../funcs/dashboardsPostSessionsDashboard.js";
|
|
7
9
|
import { dashboardsPostSessionSummaryDashboard } from "../funcs/dashboardsPostSessionSummaryDashboard.js";
|
|
8
10
|
import { dashboardsPostSessionTransfersDashboard } from "../funcs/dashboardsPostSessionTransfersDashboard.js";
|
|
9
11
|
import { ClientSDK, RequestOptions } from "../lib/sdks.js";
|
|
10
12
|
import * as components from "../models/components/index.js";
|
|
13
|
+
import * as operations from "../models/operations/index.js";
|
|
11
14
|
import { unwrapAsync } from "../types/fp.js";
|
|
12
15
|
|
|
13
16
|
export class Dashboards extends ClientSDK {
|
|
17
|
+
/**
|
|
18
|
+
* Post List Dashboards
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* METHOD: POST
|
|
22
|
+
* URL: /dashboard/list
|
|
23
|
+
* ARGUMENTS: None
|
|
24
|
+
* RETURNS: List of dashboards
|
|
25
|
+
*/
|
|
26
|
+
async postListDashboard(
|
|
27
|
+
request: operations.PostListDashboardRequest,
|
|
28
|
+
options?: RequestOptions,
|
|
29
|
+
): Promise<components.ListResponseDashboardResponse> {
|
|
30
|
+
return unwrapAsync(dashboardsPostListDashboard(
|
|
31
|
+
this,
|
|
32
|
+
request,
|
|
33
|
+
options,
|
|
34
|
+
));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Post Fetch Info
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
* METHOD: POST
|
|
42
|
+
* URL: /dashboard/fetch_info
|
|
43
|
+
* ARGUMENTS: None
|
|
44
|
+
* RETURNS: Dashboard info for embedding
|
|
45
|
+
*/
|
|
46
|
+
async postGetDashboard(
|
|
47
|
+
request: operations.PostGetDashboardRequest,
|
|
48
|
+
options?: RequestOptions,
|
|
49
|
+
): Promise<components.DashboardTokenResponse> {
|
|
50
|
+
return unwrapAsync(dashboardsPostGetDashboard(
|
|
51
|
+
this,
|
|
52
|
+
request,
|
|
53
|
+
options,
|
|
54
|
+
));
|
|
55
|
+
}
|
|
56
|
+
|
|
14
57
|
/**
|
|
15
58
|
* Post Session Events
|
|
16
59
|
*
|
|
@@ -19,6 +62,9 @@ export class Dashboards extends ClientSDK {
|
|
|
19
62
|
* URL: /dashboard/session_events
|
|
20
63
|
* ARGUMENTS: None
|
|
21
64
|
* RETURNS: Dashboard info for embedding
|
|
65
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
66
|
+
*
|
|
67
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
22
68
|
*/
|
|
23
69
|
async postSessionEventsDashboard(
|
|
24
70
|
options?: RequestOptions,
|
|
@@ -37,6 +83,9 @@ export class Dashboards extends ClientSDK {
|
|
|
37
83
|
* URL: /dashboard/session_summary
|
|
38
84
|
* ARGUMENTS: None
|
|
39
85
|
* RETURNS: Dashboard info for embedding
|
|
86
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
87
|
+
*
|
|
88
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
40
89
|
*/
|
|
41
90
|
async postSessionSummaryDashboard(
|
|
42
91
|
options?: RequestOptions,
|
|
@@ -55,6 +104,9 @@ export class Dashboards extends ClientSDK {
|
|
|
55
104
|
* URL: /dashboard/session_transfers
|
|
56
105
|
* ARGUMENTS: None
|
|
57
106
|
* RETURNS: Dashboard info for embedding
|
|
107
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
108
|
+
*
|
|
109
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
58
110
|
*/
|
|
59
111
|
async postSessionTransfersDashboard(
|
|
60
112
|
options?: RequestOptions,
|
|
@@ -73,6 +125,9 @@ export class Dashboards extends ClientSDK {
|
|
|
73
125
|
* URL: /dashboard/sessions
|
|
74
126
|
* ARGUMENTS: None
|
|
75
127
|
* RETURNS: Dashboard info for embedding
|
|
128
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
129
|
+
*
|
|
130
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
76
131
|
*/
|
|
77
132
|
async postSessionsDashboard(
|
|
78
133
|
options?: RequestOptions,
|
package/src/sdk/v1.ts
CHANGED
|
@@ -2,15 +2,58 @@
|
|
|
2
2
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
+
import { v1PostGetDashboard } from "../funcs/v1PostGetDashboard.js";
|
|
6
|
+
import { v1PostListDashboard } from "../funcs/v1PostListDashboard.js";
|
|
5
7
|
import { v1PostSessionEventsDashboard } from "../funcs/v1PostSessionEventsDashboard.js";
|
|
6
8
|
import { v1PostSessionsDashboard } from "../funcs/v1PostSessionsDashboard.js";
|
|
7
9
|
import { v1PostSessionSummaryDashboard } from "../funcs/v1PostSessionSummaryDashboard.js";
|
|
8
10
|
import { v1PostSessionTransfersDashboard } from "../funcs/v1PostSessionTransfersDashboard.js";
|
|
9
11
|
import { ClientSDK, RequestOptions } from "../lib/sdks.js";
|
|
10
12
|
import * as components from "../models/components/index.js";
|
|
13
|
+
import * as operations from "../models/operations/index.js";
|
|
11
14
|
import { unwrapAsync } from "../types/fp.js";
|
|
12
15
|
|
|
13
16
|
export class V1 extends ClientSDK {
|
|
17
|
+
/**
|
|
18
|
+
* Post List Dashboards
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* METHOD: POST
|
|
22
|
+
* URL: /dashboard/list
|
|
23
|
+
* ARGUMENTS: None
|
|
24
|
+
* RETURNS: List of dashboards
|
|
25
|
+
*/
|
|
26
|
+
async postListDashboard(
|
|
27
|
+
request: operations.PostListDashboardRequest,
|
|
28
|
+
options?: RequestOptions,
|
|
29
|
+
): Promise<components.ListResponseDashboardResponse> {
|
|
30
|
+
return unwrapAsync(v1PostListDashboard(
|
|
31
|
+
this,
|
|
32
|
+
request,
|
|
33
|
+
options,
|
|
34
|
+
));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Post Fetch Info
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
* METHOD: POST
|
|
42
|
+
* URL: /dashboard/fetch_info
|
|
43
|
+
* ARGUMENTS: None
|
|
44
|
+
* RETURNS: Dashboard info for embedding
|
|
45
|
+
*/
|
|
46
|
+
async postGetDashboard(
|
|
47
|
+
request: operations.PostGetDashboardRequest,
|
|
48
|
+
options?: RequestOptions,
|
|
49
|
+
): Promise<components.DashboardTokenResponse> {
|
|
50
|
+
return unwrapAsync(v1PostGetDashboard(
|
|
51
|
+
this,
|
|
52
|
+
request,
|
|
53
|
+
options,
|
|
54
|
+
));
|
|
55
|
+
}
|
|
56
|
+
|
|
14
57
|
/**
|
|
15
58
|
* Post Session Events
|
|
16
59
|
*
|
|
@@ -19,6 +62,9 @@ export class V1 extends ClientSDK {
|
|
|
19
62
|
* URL: /dashboard/session_events
|
|
20
63
|
* ARGUMENTS: None
|
|
21
64
|
* RETURNS: Dashboard info for embedding
|
|
65
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
66
|
+
*
|
|
67
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
22
68
|
*/
|
|
23
69
|
async postSessionEventsDashboard(
|
|
24
70
|
options?: RequestOptions,
|
|
@@ -37,6 +83,9 @@ export class V1 extends ClientSDK {
|
|
|
37
83
|
* URL: /dashboard/session_summary
|
|
38
84
|
* ARGUMENTS: None
|
|
39
85
|
* RETURNS: Dashboard info for embedding
|
|
86
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
87
|
+
*
|
|
88
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
40
89
|
*/
|
|
41
90
|
async postSessionSummaryDashboard(
|
|
42
91
|
options?: RequestOptions,
|
|
@@ -55,6 +104,9 @@ export class V1 extends ClientSDK {
|
|
|
55
104
|
* URL: /dashboard/session_transfers
|
|
56
105
|
* ARGUMENTS: None
|
|
57
106
|
* RETURNS: Dashboard info for embedding
|
|
107
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
108
|
+
*
|
|
109
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
58
110
|
*/
|
|
59
111
|
async postSessionTransfersDashboard(
|
|
60
112
|
options?: RequestOptions,
|
|
@@ -73,6 +125,9 @@ export class V1 extends ClientSDK {
|
|
|
73
125
|
* URL: /dashboard/sessions
|
|
74
126
|
* ARGUMENTS: None
|
|
75
127
|
* RETURNS: Dashboard info for embedding
|
|
128
|
+
* DEPRECATED: This endpoint is deprecated. Please use /dashboard/list instead
|
|
129
|
+
*
|
|
130
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
76
131
|
*/
|
|
77
132
|
async postSessionsDashboard(
|
|
78
133
|
options?: RequestOptions,
|