@scout9/app 1.0.0-alpha.0.1.86 → 1.0.0-alpha.0.1.87
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/dist/{exports-291eb22e.cjs → exports-85e8c05c.cjs} +389 -234
- package/dist/index.cjs +11 -2
- package/dist/{multipart-parser-caa634a9.cjs → multipart-parser-1f8d78d0.cjs} +1 -1
- package/dist/testing-tools.cjs +1 -1
- package/package.json +1 -1
- package/src/core/index.js +15 -35
- package/src/exports.js +11 -7
- package/src/platform.js +213 -211
- package/src/public.d.ts +43 -80
- package/src/runtime/client/api.js +51 -159
- package/src/runtime/client/config.js +43 -7
- package/src/runtime/client/entity.js +19 -5
- package/src/runtime/client/index.js +2 -1
- package/src/runtime/client/message.js +12 -3
- package/src/runtime/client/platform.js +86 -0
- package/src/runtime/client/{agent.js → users.js} +25 -4
- package/src/runtime/client/utils.js +3 -2
- package/src/runtime/client/workflow.js +73 -5
- package/types/index.d.ts +2923 -1261
- package/types/index.d.ts.map +53 -20
package/types/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
declare module '@scout9/app' {
|
|
2
2
|
/**
|
|
3
3
|
* Represents the configuration provided in src/index.{js | ts} in a project
|
|
4
|
+
* @deprecated use IScout9ProjectConfig
|
|
4
5
|
*/
|
|
5
6
|
export interface Scout9ProjectConfig {
|
|
6
7
|
|
|
@@ -64,6 +65,7 @@ declare module '@scout9/app' {
|
|
|
64
65
|
|
|
65
66
|
/**
|
|
66
67
|
* Entity config the user provides
|
|
68
|
+
* @deprecated use IEntityConfiguration
|
|
67
69
|
*/
|
|
68
70
|
export interface EntityBuildConfig {
|
|
69
71
|
definitions?: {
|
|
@@ -85,6 +87,7 @@ declare module '@scout9/app' {
|
|
|
85
87
|
|
|
86
88
|
/**
|
|
87
89
|
* What gets exported to the scout9 backend, properties are constructed by @scout/app build
|
|
90
|
+
* @deprecated use IEntityRootProjectConfiguration instead
|
|
88
91
|
*/
|
|
89
92
|
export interface ExportedEntityBuildConfig extends EntityBuildConfig {
|
|
90
93
|
entities: string[];
|
|
@@ -100,15 +103,27 @@ declare module '@scout9/app' {
|
|
|
100
103
|
} | null;
|
|
101
104
|
}
|
|
102
105
|
|
|
106
|
+
/**
|
|
107
|
+
* @deprecated use IEntitiesRootProjectConfiguration instead
|
|
108
|
+
*/
|
|
103
109
|
export type EntitiesBuildConfig = ExportedEntityBuildConfig[];
|
|
104
110
|
|
|
111
|
+
/**
|
|
112
|
+
* @deprecated use IWorkflowConfiguration instead
|
|
113
|
+
*/
|
|
105
114
|
export type WorkflowBuildConfig = {
|
|
106
115
|
entities: string[];
|
|
107
116
|
entity: string;
|
|
108
117
|
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* @deprecated use IWorkflowsConfiguration instead
|
|
121
|
+
*/
|
|
109
122
|
export type WorkflowsBuildConfig = WorkflowBuildConfig[];
|
|
123
|
+
|
|
110
124
|
/**
|
|
111
125
|
* Including the provided project config, this is the manifest for all entities and workflows to be managed in build
|
|
126
|
+
* @deprecated IScout9ProjectBuildConfig
|
|
112
127
|
*/
|
|
113
128
|
export interface Scout9ProjectBuildConfig extends Scout9ProjectConfig {
|
|
114
129
|
agents: Agent[];
|
|
@@ -131,6 +146,9 @@ declare module '@scout9/app' {
|
|
|
131
146
|
mode?: 'remote' | 'local';
|
|
132
147
|
}
|
|
133
148
|
|
|
149
|
+
/**
|
|
150
|
+
* @deprecated use IConversation
|
|
151
|
+
*/
|
|
134
152
|
export interface Conversation {
|
|
135
153
|
$agent: string;
|
|
136
154
|
$customer: string;
|
|
@@ -158,6 +176,9 @@ declare module '@scout9/app' {
|
|
|
158
176
|
intentScore?: number | null;
|
|
159
177
|
}
|
|
160
178
|
|
|
179
|
+
/**
|
|
180
|
+
* @deprecated use IMessage
|
|
181
|
+
*/
|
|
161
182
|
export interface Message {
|
|
162
183
|
id: string;
|
|
163
184
|
|
|
@@ -185,6 +206,9 @@ declare module '@scout9/app' {
|
|
|
185
206
|
intentScore?: number | null;
|
|
186
207
|
}
|
|
187
208
|
|
|
209
|
+
/**
|
|
210
|
+
* @deprecated use ICustomer
|
|
211
|
+
*/
|
|
188
212
|
export interface Customer {
|
|
189
213
|
id: string;
|
|
190
214
|
name: string;
|
|
@@ -205,6 +229,9 @@ declare module '@scout9/app' {
|
|
|
205
229
|
[key: string]: any;
|
|
206
230
|
}
|
|
207
231
|
|
|
232
|
+
/**
|
|
233
|
+
* @deprecated use IAgent
|
|
234
|
+
*/
|
|
208
235
|
export interface Agent {
|
|
209
236
|
// Generated Info
|
|
210
237
|
id: string;
|
|
@@ -236,10 +263,14 @@ declare module '@scout9/app' {
|
|
|
236
263
|
audios?: any[];
|
|
237
264
|
}
|
|
238
265
|
|
|
266
|
+
/**
|
|
267
|
+
* @deprecated use IPersona
|
|
268
|
+
*/
|
|
239
269
|
export type Persona = Agent;
|
|
240
270
|
|
|
241
271
|
/**
|
|
242
272
|
* The input event provided to the application
|
|
273
|
+
* @deprecated use IWorkflowEvent
|
|
243
274
|
*/
|
|
244
275
|
export interface WorkflowEvent<Type = any> {
|
|
245
276
|
messages: Message[];
|
|
@@ -256,11 +287,17 @@ declare module '@scout9/app' {
|
|
|
256
287
|
stagnationCount: number;
|
|
257
288
|
}
|
|
258
289
|
|
|
290
|
+
/**
|
|
291
|
+
* @deprecated use IInstruction
|
|
292
|
+
*/
|
|
259
293
|
export interface Instruction {
|
|
260
294
|
id: string;
|
|
261
295
|
content: string;
|
|
262
296
|
}
|
|
263
297
|
|
|
298
|
+
/**
|
|
299
|
+
* @deprecated use IWorkflowResponseSlot
|
|
300
|
+
*/
|
|
264
301
|
export interface WorkflowResponseSlot<Type = any> {
|
|
265
302
|
forward?: string | boolean | {
|
|
266
303
|
to?: string;
|
|
@@ -281,89 +318,15 @@ declare module '@scout9/app' {
|
|
|
281
318
|
resetIntent?: boolean;
|
|
282
319
|
}
|
|
283
320
|
|
|
321
|
+
/**
|
|
322
|
+
* @deprecated use IWorkflowResponse
|
|
323
|
+
*/
|
|
284
324
|
export type WorkflowResponse<Type = any> = WorkflowResponseSlot<Type> | WorkflowResponseSlot<Type>[];
|
|
285
325
|
|
|
326
|
+
/**
|
|
327
|
+
* @deprecated use IWorkflowFunction
|
|
328
|
+
*/
|
|
286
329
|
export type WorkflowFunction<Type = any> = (event: WorkflowEvent) => Promise<WorkflowResponse<Type>> | WorkflowResponse<Type>;
|
|
287
|
-
|
|
288
|
-
export function json<Type = any>(data: Type, init?: ResponseInit): Promise<EventResponse<Type>>;
|
|
289
|
-
|
|
290
|
-
export function run<Type = any>(event: WorkflowEvent, options?: RunOptions): Promise<WorkflowResponse<Type>>;
|
|
291
|
-
|
|
292
|
-
export function sendEvent<Type = any>(event: WorkflowEvent, options?: RunOptions): Promise<WorkflowResponse<Type>>;
|
|
293
|
-
|
|
294
|
-
export function build(options?: BuildOptions): Promise<Scout9ProjectBuildConfig>;
|
|
295
|
-
|
|
296
|
-
export function deploy(options?: DeployOptions): Promise<Scout9ProjectBuildConfig>;
|
|
297
|
-
|
|
298
|
-
export class EventResponse<Type = any> {
|
|
299
|
-
/**
|
|
300
|
-
* Static method to create an EventResponse object.
|
|
301
|
-
* @param body The body of the response, expected to be an object.
|
|
302
|
-
* @param options Additional options for the response.
|
|
303
|
-
*/
|
|
304
|
-
static json<Type = any>(body: object, options?: ResponseInit): EventResponse<Type>;
|
|
305
|
-
|
|
306
|
-
/**
|
|
307
|
-
* The body of the response.
|
|
308
|
-
*/
|
|
309
|
-
body: object;
|
|
310
|
-
|
|
311
|
-
// Alias to body
|
|
312
|
-
readonly data: object;
|
|
313
|
-
|
|
314
|
-
/**
|
|
315
|
-
* Initialization options for the response.
|
|
316
|
-
*/
|
|
317
|
-
init?: ResponseInit;
|
|
318
|
-
|
|
319
|
-
/**
|
|
320
|
-
* Creates an instance of EventResponse.
|
|
321
|
-
* @param body The body of the response, expected to be an object.
|
|
322
|
-
* @param init Initialization options for the response.
|
|
323
|
-
*/
|
|
324
|
-
constructor(body: Type, init?: ResponseInit);
|
|
325
|
-
|
|
326
|
-
/**
|
|
327
|
-
* Returns a Response object with JSON body.
|
|
328
|
-
*/
|
|
329
|
-
readonly response: Response;
|
|
330
|
-
}
|
|
331
|
-
|
|
332
|
-
export type ApiFunctionParams<Params = Record<string, string>> = {
|
|
333
|
-
searchParams: {[key: string]: string | string[] };
|
|
334
|
-
params: Params;
|
|
335
|
-
}
|
|
336
|
-
// export type ApiEntityFunctionParams<Params = Record<string, string>> = ApiFunctionParams<Params> & {id: string};
|
|
337
|
-
export type ApiFunction<Params = Record<string, string>, Response = any> = (params: ApiFunctionParams<Params>) => Promise<EventResponse<Response>>;
|
|
338
|
-
export type QueryApiFunction<Params = Record<string, string>, Response = any> = (params: ApiFunctionParams<Params>) => Promise<EventResponse<Response>>;
|
|
339
|
-
export type GetApiFunction<Params = Record<string, string>, Response = any> = (params: ApiFunctionParams<Params>) => Promise<EventResponse<Response>>;
|
|
340
|
-
export type PostApiFunction<Params = Record<string, string>, RequestBody = any, Response = any> = (params: ApiFunctionParams<Params> & {body: Partial<RequestBody>}) => Promise<EventResponse<Response>>;
|
|
341
|
-
export type PutApiFunction<Params = Record<string, string>, RequestBody = any, Response = any> = (params: ApiFunctionParams<Params> & {body: Partial<RequestBody>}) => Promise<EventResponse<Response>>;
|
|
342
|
-
export type PatchApiFunction<Params = Record<string, string>, RequestBody = any, Response = any> = (params: ApiFunctionParams<Params> & {body: Partial<RequestBody>}) => Promise<EventResponse<Response>>;
|
|
343
|
-
export type DeleteApiFunction<Params = Record<string, string>, Response = any> = (params: ApiFunctionParams<Params>) => Promise<EventResponse<Response>>;
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
export type mimicCustomerMessage = (input: {
|
|
347
|
-
message: string;
|
|
348
|
-
messages?: Message[];
|
|
349
|
-
workflowFn: WorkflowFunction;
|
|
350
|
-
customer?: Customer;
|
|
351
|
-
context?: any;
|
|
352
|
-
/**
|
|
353
|
-
* Agent or persona id
|
|
354
|
-
*/
|
|
355
|
-
persona?: string;
|
|
356
|
-
|
|
357
|
-
conversation?: Conversation;
|
|
358
|
-
|
|
359
|
-
cwd?: string;
|
|
360
|
-
src?: string;
|
|
361
|
-
mode?: 'development' | 'production';
|
|
362
|
-
}) => Promise<{
|
|
363
|
-
messages: Message[];
|
|
364
|
-
conversation: Conversation;
|
|
365
|
-
context: any;
|
|
366
|
-
}>
|
|
367
330
|
}
|
|
368
331
|
|
|
369
332
|
declare module '@scout9/app/testing-tools' {
|
|
@@ -540,6 +503,7 @@ declare module '@scout9/app/testing-tools' {
|
|
|
540
503
|
declare module '@scout9/app/types' {
|
|
541
504
|
import type { z } from 'zod';
|
|
542
505
|
export const customerValueSchema: z.ZodUnion<[z.ZodBoolean, z.ZodNumber, z.ZodString]>;
|
|
506
|
+
|
|
543
507
|
export const customerSchema: z.ZodObject<{
|
|
544
508
|
firstName: z.ZodOptional<z.ZodString>;
|
|
545
509
|
lastName: z.ZodOptional<z.ZodString>;
|
|
@@ -595,6 +559,7 @@ declare module '@scout9/app/types' {
|
|
|
595
559
|
stripe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
596
560
|
stripeDev: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
597
561
|
}, z.ZodUnion<[z.ZodBoolean, z.ZodNumber, z.ZodString]>, "strip">>;
|
|
562
|
+
|
|
598
563
|
export const agentBaseConfigurationSchema: z.ZodObject<{
|
|
599
564
|
deployed: z.ZodOptional<z.ZodObject<{
|
|
600
565
|
web: z.ZodOptional<z.ZodString>;
|
|
@@ -609,6 +574,7 @@ declare module '@scout9/app/types' {
|
|
|
609
574
|
phone?: string | undefined;
|
|
610
575
|
email?: string | undefined;
|
|
611
576
|
}>>;
|
|
577
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
612
578
|
firstName: z.ZodOptional<z.ZodString>;
|
|
613
579
|
lastName: z.ZodOptional<z.ZodString>;
|
|
614
580
|
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -623,20 +589,35 @@ declare module '@scout9/app/types' {
|
|
|
623
589
|
excludedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
624
590
|
model: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Scout9", "bard", "openai"]>>>;
|
|
625
591
|
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
626
|
-
|
|
592
|
+
id: z.ZodString;
|
|
627
593
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
594
|
+
content: z.ZodString;
|
|
628
595
|
time: z.ZodString;
|
|
629
596
|
name: z.ZodOptional<z.ZodString>;
|
|
597
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
598
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
599
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
600
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
630
601
|
}, "strip", z.ZodTypeAny, {
|
|
631
602
|
time: string;
|
|
603
|
+
id: string;
|
|
632
604
|
content: string;
|
|
633
605
|
role: "agent" | "customer" | "system";
|
|
634
606
|
name?: string | undefined;
|
|
607
|
+
scheduled?: string | undefined;
|
|
608
|
+
context?: any;
|
|
609
|
+
intent?: string | null | undefined;
|
|
610
|
+
intentScore?: number | null | undefined;
|
|
635
611
|
}, {
|
|
636
612
|
time: string;
|
|
613
|
+
id: string;
|
|
637
614
|
content: string;
|
|
638
615
|
role: "agent" | "customer" | "system";
|
|
639
616
|
name?: string | undefined;
|
|
617
|
+
scheduled?: string | undefined;
|
|
618
|
+
context?: any;
|
|
619
|
+
intent?: string | null | undefined;
|
|
620
|
+
intentScore?: number | null | undefined;
|
|
640
621
|
}>, "many">, "many">>;
|
|
641
622
|
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
642
623
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -648,6 +629,7 @@ declare module '@scout9/app/types' {
|
|
|
648
629
|
phone?: string | undefined;
|
|
649
630
|
email?: string | undefined;
|
|
650
631
|
} | undefined;
|
|
632
|
+
img?: string | null | undefined;
|
|
651
633
|
firstName?: string | undefined;
|
|
652
634
|
lastName?: string | undefined;
|
|
653
635
|
inactive?: boolean | undefined;
|
|
@@ -660,9 +642,14 @@ declare module '@scout9/app/types' {
|
|
|
660
642
|
excludedLocations?: string[] | undefined;
|
|
661
643
|
transcripts?: {
|
|
662
644
|
time: string;
|
|
645
|
+
id: string;
|
|
663
646
|
content: string;
|
|
664
647
|
role: "agent" | "customer" | "system";
|
|
665
648
|
name?: string | undefined;
|
|
649
|
+
scheduled?: string | undefined;
|
|
650
|
+
context?: any;
|
|
651
|
+
intent?: string | null | undefined;
|
|
652
|
+
intentScore?: number | null | undefined;
|
|
666
653
|
}[][] | undefined;
|
|
667
654
|
audios?: any[] | undefined;
|
|
668
655
|
}, {
|
|
@@ -671,6 +658,7 @@ declare module '@scout9/app/types' {
|
|
|
671
658
|
phone?: string | undefined;
|
|
672
659
|
email?: string | undefined;
|
|
673
660
|
} | undefined;
|
|
661
|
+
img?: string | null | undefined;
|
|
674
662
|
firstName?: string | undefined;
|
|
675
663
|
lastName?: string | undefined;
|
|
676
664
|
inactive?: boolean | undefined;
|
|
@@ -686,33 +674,55 @@ declare module '@scout9/app/types' {
|
|
|
686
674
|
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
687
675
|
transcripts?: {
|
|
688
676
|
time: string;
|
|
677
|
+
id: string;
|
|
689
678
|
content: string;
|
|
690
679
|
role: "agent" | "customer" | "system";
|
|
691
680
|
name?: string | undefined;
|
|
681
|
+
scheduled?: string | undefined;
|
|
682
|
+
context?: any;
|
|
683
|
+
intent?: string | null | undefined;
|
|
684
|
+
intentScore?: number | null | undefined;
|
|
692
685
|
}[][] | undefined;
|
|
693
686
|
audios?: any[] | undefined;
|
|
694
687
|
}>;
|
|
688
|
+
|
|
695
689
|
export const agentConfigurationSchema: z.ZodObject<{
|
|
696
690
|
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
691
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
697
692
|
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
698
693
|
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
699
694
|
firstName: z.ZodOptional<z.ZodString>;
|
|
700
695
|
lastName: z.ZodOptional<z.ZodString>;
|
|
701
696
|
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
702
|
-
|
|
697
|
+
id: z.ZodString;
|
|
703
698
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
699
|
+
content: z.ZodString;
|
|
704
700
|
time: z.ZodString;
|
|
705
701
|
name: z.ZodOptional<z.ZodString>;
|
|
702
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
703
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
704
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
705
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
706
706
|
}, "strip", z.ZodTypeAny, {
|
|
707
707
|
time: string;
|
|
708
|
+
id: string;
|
|
708
709
|
content: string;
|
|
709
710
|
role: "agent" | "customer" | "system";
|
|
710
711
|
name?: string | undefined;
|
|
712
|
+
scheduled?: string | undefined;
|
|
713
|
+
context?: any;
|
|
714
|
+
intent?: string | null | undefined;
|
|
715
|
+
intentScore?: number | null | undefined;
|
|
711
716
|
}, {
|
|
712
717
|
time: string;
|
|
718
|
+
id: string;
|
|
713
719
|
content: string;
|
|
714
720
|
role: "agent" | "customer" | "system";
|
|
715
721
|
name?: string | undefined;
|
|
722
|
+
scheduled?: string | undefined;
|
|
723
|
+
context?: any;
|
|
724
|
+
intent?: string | null | undefined;
|
|
725
|
+
intentScore?: number | null | undefined;
|
|
716
726
|
}>, "many">, "many">>;
|
|
717
727
|
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
718
728
|
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
@@ -743,13 +753,19 @@ declare module '@scout9/app/types' {
|
|
|
743
753
|
context: string;
|
|
744
754
|
model: "openai" | "bard" | "Scout9";
|
|
745
755
|
inactive?: boolean | undefined;
|
|
756
|
+
img?: string | null | undefined;
|
|
746
757
|
firstName?: string | undefined;
|
|
747
758
|
lastName?: string | undefined;
|
|
748
759
|
transcripts?: {
|
|
749
760
|
time: string;
|
|
761
|
+
id: string;
|
|
750
762
|
content: string;
|
|
751
763
|
role: "agent" | "customer" | "system";
|
|
752
764
|
name?: string | undefined;
|
|
765
|
+
scheduled?: string | undefined;
|
|
766
|
+
context?: any;
|
|
767
|
+
intent?: string | null | undefined;
|
|
768
|
+
intentScore?: number | null | undefined;
|
|
753
769
|
}[][] | undefined;
|
|
754
770
|
audios?: any[] | undefined;
|
|
755
771
|
includedLocations?: string[] | undefined;
|
|
@@ -767,15 +783,21 @@ declare module '@scout9/app/types' {
|
|
|
767
783
|
}, {
|
|
768
784
|
id: string;
|
|
769
785
|
inactive?: boolean | undefined;
|
|
786
|
+
img?: string | null | undefined;
|
|
770
787
|
title?: string | undefined;
|
|
771
788
|
context?: string | undefined;
|
|
772
789
|
firstName?: string | undefined;
|
|
773
790
|
lastName?: string | undefined;
|
|
774
791
|
transcripts?: {
|
|
775
792
|
time: string;
|
|
793
|
+
id: string;
|
|
776
794
|
content: string;
|
|
777
795
|
role: "agent" | "customer" | "system";
|
|
778
796
|
name?: string | undefined;
|
|
797
|
+
scheduled?: string | undefined;
|
|
798
|
+
context?: any;
|
|
799
|
+
intent?: string | null | undefined;
|
|
800
|
+
intentScore?: number | null | undefined;
|
|
779
801
|
}[][] | undefined;
|
|
780
802
|
audios?: any[] | undefined;
|
|
781
803
|
includedLocations?: string[] | undefined;
|
|
@@ -792,27 +814,44 @@ declare module '@scout9/app/types' {
|
|
|
792
814
|
forwardEmail?: string | undefined;
|
|
793
815
|
forwardPhone?: string | undefined;
|
|
794
816
|
}>;
|
|
817
|
+
|
|
795
818
|
export const agentsConfigurationSchema: z.ZodArray<z.ZodObject<{
|
|
796
819
|
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
820
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
797
821
|
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
798
822
|
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
799
823
|
firstName: z.ZodOptional<z.ZodString>;
|
|
800
824
|
lastName: z.ZodOptional<z.ZodString>;
|
|
801
825
|
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
802
|
-
|
|
826
|
+
id: z.ZodString;
|
|
803
827
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
828
|
+
content: z.ZodString;
|
|
804
829
|
time: z.ZodString;
|
|
805
830
|
name: z.ZodOptional<z.ZodString>;
|
|
831
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
832
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
833
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
834
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
806
835
|
}, "strip", z.ZodTypeAny, {
|
|
807
836
|
time: string;
|
|
837
|
+
id: string;
|
|
808
838
|
content: string;
|
|
809
839
|
role: "agent" | "customer" | "system";
|
|
810
840
|
name?: string | undefined;
|
|
841
|
+
scheduled?: string | undefined;
|
|
842
|
+
context?: any;
|
|
843
|
+
intent?: string | null | undefined;
|
|
844
|
+
intentScore?: number | null | undefined;
|
|
811
845
|
}, {
|
|
812
846
|
time: string;
|
|
847
|
+
id: string;
|
|
813
848
|
content: string;
|
|
814
849
|
role: "agent" | "customer" | "system";
|
|
815
850
|
name?: string | undefined;
|
|
851
|
+
scheduled?: string | undefined;
|
|
852
|
+
context?: any;
|
|
853
|
+
intent?: string | null | undefined;
|
|
854
|
+
intentScore?: number | null | undefined;
|
|
816
855
|
}>, "many">, "many">>;
|
|
817
856
|
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
818
857
|
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
@@ -843,13 +882,19 @@ declare module '@scout9/app/types' {
|
|
|
843
882
|
context: string;
|
|
844
883
|
model: "openai" | "bard" | "Scout9";
|
|
845
884
|
inactive?: boolean | undefined;
|
|
885
|
+
img?: string | null | undefined;
|
|
846
886
|
firstName?: string | undefined;
|
|
847
887
|
lastName?: string | undefined;
|
|
848
888
|
transcripts?: {
|
|
849
889
|
time: string;
|
|
890
|
+
id: string;
|
|
850
891
|
content: string;
|
|
851
892
|
role: "agent" | "customer" | "system";
|
|
852
893
|
name?: string | undefined;
|
|
894
|
+
scheduled?: string | undefined;
|
|
895
|
+
context?: any;
|
|
896
|
+
intent?: string | null | undefined;
|
|
897
|
+
intentScore?: number | null | undefined;
|
|
853
898
|
}[][] | undefined;
|
|
854
899
|
audios?: any[] | undefined;
|
|
855
900
|
includedLocations?: string[] | undefined;
|
|
@@ -867,15 +912,21 @@ declare module '@scout9/app/types' {
|
|
|
867
912
|
}, {
|
|
868
913
|
id: string;
|
|
869
914
|
inactive?: boolean | undefined;
|
|
915
|
+
img?: string | null | undefined;
|
|
870
916
|
title?: string | undefined;
|
|
871
917
|
context?: string | undefined;
|
|
872
918
|
firstName?: string | undefined;
|
|
873
919
|
lastName?: string | undefined;
|
|
874
920
|
transcripts?: {
|
|
875
921
|
time: string;
|
|
922
|
+
id: string;
|
|
876
923
|
content: string;
|
|
877
924
|
role: "agent" | "customer" | "system";
|
|
878
925
|
name?: string | undefined;
|
|
926
|
+
scheduled?: string | undefined;
|
|
927
|
+
context?: any;
|
|
928
|
+
intent?: string | null | undefined;
|
|
929
|
+
intentScore?: number | null | undefined;
|
|
879
930
|
}[][] | undefined;
|
|
880
931
|
audios?: any[] | undefined;
|
|
881
932
|
includedLocations?: string[] | undefined;
|
|
@@ -892,6 +943,7 @@ declare module '@scout9/app/types' {
|
|
|
892
943
|
forwardEmail?: string | undefined;
|
|
893
944
|
forwardPhone?: string | undefined;
|
|
894
945
|
}>, "many">;
|
|
946
|
+
|
|
895
947
|
export const agentsBaseConfigurationSchema: z.ZodArray<z.ZodObject<{
|
|
896
948
|
deployed: z.ZodOptional<z.ZodObject<{
|
|
897
949
|
web: z.ZodOptional<z.ZodString>;
|
|
@@ -906,6 +958,7 @@ declare module '@scout9/app/types' {
|
|
|
906
958
|
phone?: string | undefined;
|
|
907
959
|
email?: string | undefined;
|
|
908
960
|
}>>;
|
|
961
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
909
962
|
firstName: z.ZodOptional<z.ZodString>;
|
|
910
963
|
lastName: z.ZodOptional<z.ZodString>;
|
|
911
964
|
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -920,20 +973,35 @@ declare module '@scout9/app/types' {
|
|
|
920
973
|
excludedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
921
974
|
model: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Scout9", "bard", "openai"]>>>;
|
|
922
975
|
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
923
|
-
|
|
976
|
+
id: z.ZodString;
|
|
924
977
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
978
|
+
content: z.ZodString;
|
|
925
979
|
time: z.ZodString;
|
|
926
980
|
name: z.ZodOptional<z.ZodString>;
|
|
981
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
982
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
983
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
984
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
927
985
|
}, "strip", z.ZodTypeAny, {
|
|
928
986
|
time: string;
|
|
987
|
+
id: string;
|
|
929
988
|
content: string;
|
|
930
989
|
role: "agent" | "customer" | "system";
|
|
931
990
|
name?: string | undefined;
|
|
991
|
+
scheduled?: string | undefined;
|
|
992
|
+
context?: any;
|
|
993
|
+
intent?: string | null | undefined;
|
|
994
|
+
intentScore?: number | null | undefined;
|
|
932
995
|
}, {
|
|
933
996
|
time: string;
|
|
997
|
+
id: string;
|
|
934
998
|
content: string;
|
|
935
999
|
role: "agent" | "customer" | "system";
|
|
936
1000
|
name?: string | undefined;
|
|
1001
|
+
scheduled?: string | undefined;
|
|
1002
|
+
context?: any;
|
|
1003
|
+
intent?: string | null | undefined;
|
|
1004
|
+
intentScore?: number | null | undefined;
|
|
937
1005
|
}>, "many">, "many">>;
|
|
938
1006
|
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
939
1007
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -945,6 +1013,7 @@ declare module '@scout9/app/types' {
|
|
|
945
1013
|
phone?: string | undefined;
|
|
946
1014
|
email?: string | undefined;
|
|
947
1015
|
} | undefined;
|
|
1016
|
+
img?: string | null | undefined;
|
|
948
1017
|
firstName?: string | undefined;
|
|
949
1018
|
lastName?: string | undefined;
|
|
950
1019
|
inactive?: boolean | undefined;
|
|
@@ -957,9 +1026,14 @@ declare module '@scout9/app/types' {
|
|
|
957
1026
|
excludedLocations?: string[] | undefined;
|
|
958
1027
|
transcripts?: {
|
|
959
1028
|
time: string;
|
|
1029
|
+
id: string;
|
|
960
1030
|
content: string;
|
|
961
1031
|
role: "agent" | "customer" | "system";
|
|
962
1032
|
name?: string | undefined;
|
|
1033
|
+
scheduled?: string | undefined;
|
|
1034
|
+
context?: any;
|
|
1035
|
+
intent?: string | null | undefined;
|
|
1036
|
+
intentScore?: number | null | undefined;
|
|
963
1037
|
}[][] | undefined;
|
|
964
1038
|
audios?: any[] | undefined;
|
|
965
1039
|
}, {
|
|
@@ -968,6 +1042,7 @@ declare module '@scout9/app/types' {
|
|
|
968
1042
|
phone?: string | undefined;
|
|
969
1043
|
email?: string | undefined;
|
|
970
1044
|
} | undefined;
|
|
1045
|
+
img?: string | null | undefined;
|
|
971
1046
|
firstName?: string | undefined;
|
|
972
1047
|
lastName?: string | undefined;
|
|
973
1048
|
inactive?: boolean | undefined;
|
|
@@ -983,325 +1058,122 @@ declare module '@scout9/app/types' {
|
|
|
983
1058
|
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
984
1059
|
transcripts?: {
|
|
985
1060
|
time: string;
|
|
1061
|
+
id: string;
|
|
986
1062
|
content: string;
|
|
987
1063
|
role: "agent" | "customer" | "system";
|
|
988
1064
|
name?: string | undefined;
|
|
1065
|
+
scheduled?: string | undefined;
|
|
1066
|
+
context?: any;
|
|
1067
|
+
intent?: string | null | undefined;
|
|
1068
|
+
intentScore?: number | null | undefined;
|
|
989
1069
|
}[][] | undefined;
|
|
990
1070
|
audios?: any[] | undefined;
|
|
991
1071
|
}>, "many">;
|
|
1072
|
+
export type ICustomerValue = import('zod').infer<typeof customerValueSchema>;
|
|
1073
|
+
export type ICustomer = import('zod').infer<typeof customerSchema>;
|
|
1074
|
+
export type IAgentBase = import('zod').infer<typeof agentBaseConfigurationSchema>;
|
|
1075
|
+
export type IAgent = import('zod').infer<typeof agentBaseConfigurationSchema>;
|
|
1076
|
+
export type IPersona = import('zod').infer<typeof agentBaseConfigurationSchema>;
|
|
1077
|
+
export type IAgentsConfiguration = import('zod').infer<typeof agentsConfigurationSchema>;
|
|
1078
|
+
export type IAgentsBaseConfiguration = import('zod').infer<typeof agentsBaseConfigurationSchema>;
|
|
992
1079
|
/**
|
|
993
1080
|
* Utility runtime class used to guide event output
|
|
994
|
-
*/
|
|
995
|
-
export class EventResponse {
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1081
|
+
* */
|
|
1082
|
+
export class EventResponse<T> {
|
|
1083
|
+
/**
|
|
1084
|
+
* Create a new EventResponse instance with a JSON body.
|
|
1085
|
+
* @param body - The body of the response.
|
|
1086
|
+
* @param options - Additional options for the response.
|
|
1087
|
+
* @returns A new EventResponse instance.
|
|
1088
|
+
*/
|
|
1089
|
+
static json<T_1>(body: T_1, options?: ResponseInit | undefined): EventResponse<T_1>;
|
|
1090
|
+
/**
|
|
1091
|
+
* Create an EventResponse.
|
|
1092
|
+
* @param body - The body of the response.
|
|
1093
|
+
* @param init - Additional options for the response.
|
|
1094
|
+
* @throws {Error} If the body is not a valid object.
|
|
1095
|
+
*/
|
|
1096
|
+
constructor(body: T, init?: ResponseInit | undefined);
|
|
1097
|
+
|
|
1098
|
+
private body;
|
|
1099
|
+
|
|
1100
|
+
private init;
|
|
1101
|
+
/**
|
|
1102
|
+
* Get the response object.
|
|
1103
|
+
* @returns The response object.
|
|
1104
|
+
*/
|
|
1000
1105
|
get response(): Response;
|
|
1001
|
-
|
|
1106
|
+
/**
|
|
1107
|
+
* Get the data of the response.
|
|
1108
|
+
* @returns The body of the response.
|
|
1109
|
+
*/
|
|
1110
|
+
get data(): T;
|
|
1002
1111
|
}
|
|
1003
|
-
|
|
1112
|
+
|
|
1113
|
+
export const eventResponseSchema: z.ZodObject<{
|
|
1114
|
+
body: z.ZodAny;
|
|
1115
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
1116
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
1117
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
1118
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
1119
|
+
}, "strip", z.ZodTypeAny, {
|
|
1120
|
+
status?: number | undefined;
|
|
1121
|
+
statusText?: string | undefined;
|
|
1122
|
+
headers?: any;
|
|
1123
|
+
}, {
|
|
1124
|
+
status?: number | undefined;
|
|
1125
|
+
statusText?: string | undefined;
|
|
1126
|
+
headers?: any;
|
|
1127
|
+
}>>;
|
|
1128
|
+
}, "strip", z.ZodTypeAny, {
|
|
1129
|
+
body?: any;
|
|
1130
|
+
init?: {
|
|
1131
|
+
status?: number | undefined;
|
|
1132
|
+
statusText?: string | undefined;
|
|
1133
|
+
headers?: any;
|
|
1134
|
+
} | undefined;
|
|
1135
|
+
}, {
|
|
1136
|
+
body?: any;
|
|
1137
|
+
init?: {
|
|
1138
|
+
status?: number | undefined;
|
|
1139
|
+
statusText?: string | undefined;
|
|
1140
|
+
headers?: any;
|
|
1141
|
+
} | undefined;
|
|
1142
|
+
}>;
|
|
1143
|
+
export type IEventResponse<T> = {
|
|
1144
|
+
/**
|
|
1145
|
+
* - The body of the response.
|
|
1146
|
+
*/
|
|
1147
|
+
body: T;
|
|
1148
|
+
/**
|
|
1149
|
+
* - Additional options for the response.
|
|
1150
|
+
*/
|
|
1151
|
+
init?: ResponseInit | undefined;
|
|
1152
|
+
/**
|
|
1153
|
+
* - The response object.
|
|
1154
|
+
*/
|
|
1155
|
+
response: Response;
|
|
1156
|
+
/**
|
|
1157
|
+
* - The body of the response.
|
|
1158
|
+
*/
|
|
1159
|
+
data: T;
|
|
1160
|
+
};
|
|
1161
|
+
/**
|
|
1162
|
+
* Represents the configuration provided in src/index.{js | ts} in a project
|
|
1163
|
+
*
|
|
1164
|
+
*/
|
|
1165
|
+
export const Scout9ProjectConfigSchema: z.ZodObject<{
|
|
1166
|
+
/**
|
|
1167
|
+
* Tag to reference this application
|
|
1168
|
+
* @defaut your local package.json name + version, or scout9-app-v1.0.0
|
|
1169
|
+
*/
|
|
1004
1170
|
tag: z.ZodOptional<z.ZodString>;
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
1009
|
-
email: z.ZodOptional<z.ZodString>;
|
|
1010
|
-
}, "strip", z.ZodTypeAny, {
|
|
1011
|
-
web?: string | undefined;
|
|
1012
|
-
phone?: string | undefined;
|
|
1013
|
-
email?: string | undefined;
|
|
1014
|
-
}, {
|
|
1015
|
-
web?: string | undefined;
|
|
1016
|
-
phone?: string | undefined;
|
|
1017
|
-
email?: string | undefined;
|
|
1018
|
-
}>>;
|
|
1019
|
-
firstName: z.ZodOptional<z.ZodString>;
|
|
1020
|
-
lastName: z.ZodOptional<z.ZodString>;
|
|
1021
|
-
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
1022
|
-
programmablePhoneNumber: z.ZodOptional<z.ZodString>;
|
|
1023
|
-
programmablePhoneNumberSid: z.ZodOptional<z.ZodString>;
|
|
1024
|
-
programmableEmail: z.ZodOptional<z.ZodString>;
|
|
1025
|
-
forwardEmail: z.ZodOptional<z.ZodString>;
|
|
1026
|
-
forwardPhone: z.ZodOptional<z.ZodString>;
|
|
1027
|
-
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1028
|
-
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1029
|
-
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1030
|
-
excludedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1031
|
-
model: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Scout9", "bard", "openai"]>>>;
|
|
1032
|
-
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
1033
|
-
content: z.ZodString;
|
|
1034
|
-
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
1035
|
-
time: z.ZodString;
|
|
1036
|
-
name: z.ZodOptional<z.ZodString>;
|
|
1037
|
-
}, "strip", z.ZodTypeAny, {
|
|
1038
|
-
time: string;
|
|
1039
|
-
content: string;
|
|
1040
|
-
role: "agent" | "customer" | "system";
|
|
1041
|
-
name?: string | undefined;
|
|
1042
|
-
}, {
|
|
1043
|
-
time: string;
|
|
1044
|
-
content: string;
|
|
1045
|
-
role: "agent" | "customer" | "system";
|
|
1046
|
-
name?: string | undefined;
|
|
1047
|
-
}>, "many">, "many">>;
|
|
1048
|
-
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
1171
|
+
llm: z.ZodUnion<[z.ZodObject<{
|
|
1172
|
+
engine: z.ZodLiteral<"openai">;
|
|
1173
|
+
model: z.ZodUnion<[z.ZodLiteral<"gpt-4-1106-preview">, z.ZodLiteral<"gpt-4-vision-preview">, z.ZodLiteral<"gpt-4">, z.ZodLiteral<"gpt-4-0314">, z.ZodLiteral<"gpt-4-0613">, z.ZodLiteral<"gpt-4-32k">, z.ZodLiteral<"gpt-4-32k-0314">, z.ZodLiteral<"gpt-4-32k-0613">, z.ZodLiteral<"gpt-3.5-turbo">, z.ZodLiteral<"gpt-3.5-turbo-16k">, z.ZodLiteral<"gpt-3.5-turbo-0301">, z.ZodLiteral<"gpt-3.5-turbo-0613">, z.ZodLiteral<"gpt-3.5-turbo-16k-0613">, z.ZodString]>;
|
|
1049
1174
|
}, "strip", z.ZodTypeAny, {
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
model: "openai" | "bard" | "Scout9";
|
|
1053
|
-
deployed?: {
|
|
1054
|
-
web?: string | undefined;
|
|
1055
|
-
phone?: string | undefined;
|
|
1056
|
-
email?: string | undefined;
|
|
1057
|
-
} | undefined;
|
|
1058
|
-
firstName?: string | undefined;
|
|
1059
|
-
lastName?: string | undefined;
|
|
1060
|
-
inactive?: boolean | undefined;
|
|
1061
|
-
programmablePhoneNumber?: string | undefined;
|
|
1062
|
-
programmablePhoneNumberSid?: string | undefined;
|
|
1063
|
-
programmableEmail?: string | undefined;
|
|
1064
|
-
forwardEmail?: string | undefined;
|
|
1065
|
-
forwardPhone?: string | undefined;
|
|
1066
|
-
includedLocations?: string[] | undefined;
|
|
1067
|
-
excludedLocations?: string[] | undefined;
|
|
1068
|
-
transcripts?: {
|
|
1069
|
-
time: string;
|
|
1070
|
-
content: string;
|
|
1071
|
-
role: "agent" | "customer" | "system";
|
|
1072
|
-
name?: string | undefined;
|
|
1073
|
-
}[][] | undefined;
|
|
1074
|
-
audios?: any[] | undefined;
|
|
1075
|
-
}, {
|
|
1076
|
-
deployed?: {
|
|
1077
|
-
web?: string | undefined;
|
|
1078
|
-
phone?: string | undefined;
|
|
1079
|
-
email?: string | undefined;
|
|
1080
|
-
} | undefined;
|
|
1081
|
-
firstName?: string | undefined;
|
|
1082
|
-
lastName?: string | undefined;
|
|
1083
|
-
inactive?: boolean | undefined;
|
|
1084
|
-
programmablePhoneNumber?: string | undefined;
|
|
1085
|
-
programmablePhoneNumberSid?: string | undefined;
|
|
1086
|
-
programmableEmail?: string | undefined;
|
|
1087
|
-
forwardEmail?: string | undefined;
|
|
1088
|
-
forwardPhone?: string | undefined;
|
|
1089
|
-
title?: string | undefined;
|
|
1090
|
-
context?: string | undefined;
|
|
1091
|
-
includedLocations?: string[] | undefined;
|
|
1092
|
-
excludedLocations?: string[] | undefined;
|
|
1093
|
-
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
1094
|
-
transcripts?: {
|
|
1095
|
-
time: string;
|
|
1096
|
-
content: string;
|
|
1097
|
-
role: "agent" | "customer" | "system";
|
|
1098
|
-
name?: string | undefined;
|
|
1099
|
-
}[][] | undefined;
|
|
1100
|
-
audios?: any[] | undefined;
|
|
1101
|
-
}>, "many">;
|
|
1102
|
-
entities: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
1103
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1104
|
-
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1105
|
-
intent: z.ZodString;
|
|
1106
|
-
text: z.ZodString;
|
|
1107
|
-
}, "strip", z.ZodTypeAny, {
|
|
1108
|
-
text: string;
|
|
1109
|
-
intent: string;
|
|
1110
|
-
}, {
|
|
1111
|
-
text: string;
|
|
1112
|
-
intent: string;
|
|
1113
|
-
}>, "many">>;
|
|
1114
|
-
tests: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1115
|
-
text: z.ZodString;
|
|
1116
|
-
expected: z.ZodObject<{
|
|
1117
|
-
intent: z.ZodString;
|
|
1118
|
-
context: z.ZodAny;
|
|
1119
|
-
}, "strip", z.ZodTypeAny, {
|
|
1120
|
-
intent: string;
|
|
1121
|
-
context?: any;
|
|
1122
|
-
}, {
|
|
1123
|
-
intent: string;
|
|
1124
|
-
context?: any;
|
|
1125
|
-
}>;
|
|
1126
|
-
}, "strip", z.ZodTypeAny, {
|
|
1127
|
-
text: string;
|
|
1128
|
-
expected: {
|
|
1129
|
-
intent: string;
|
|
1130
|
-
context?: any;
|
|
1131
|
-
};
|
|
1132
|
-
}, {
|
|
1133
|
-
text: string;
|
|
1134
|
-
expected: {
|
|
1135
|
-
intent: string;
|
|
1136
|
-
context?: any;
|
|
1137
|
-
};
|
|
1138
|
-
}>, "many">>;
|
|
1139
|
-
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1140
|
-
utterance: z.ZodOptional<z.ZodString>;
|
|
1141
|
-
value: z.ZodString;
|
|
1142
|
-
text: z.ZodArray<z.ZodString, "many">;
|
|
1143
|
-
}, "strip", z.ZodTypeAny, {
|
|
1144
|
-
value: string;
|
|
1145
|
-
text: string[];
|
|
1146
|
-
utterance?: string | undefined;
|
|
1147
|
-
}, {
|
|
1148
|
-
value: string;
|
|
1149
|
-
text: string[];
|
|
1150
|
-
utterance?: string | undefined;
|
|
1151
|
-
}>, "many">>;
|
|
1152
|
-
entities: z.ZodArray<z.ZodString, "many">;
|
|
1153
|
-
entity: z.ZodString;
|
|
1154
|
-
api: z.ZodNullable<z.ZodObject<{
|
|
1155
|
-
GET: z.ZodOptional<z.ZodBoolean>;
|
|
1156
|
-
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
1157
|
-
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
1158
|
-
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
1159
|
-
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
1160
|
-
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
1161
|
-
}, "strip", z.ZodTypeAny, {
|
|
1162
|
-
GET?: boolean | undefined;
|
|
1163
|
-
UPDATE?: boolean | undefined;
|
|
1164
|
-
QUERY?: boolean | undefined;
|
|
1165
|
-
PUT?: boolean | undefined;
|
|
1166
|
-
PATCH?: boolean | undefined;
|
|
1167
|
-
DELETE?: boolean | undefined;
|
|
1168
|
-
}, {
|
|
1169
|
-
GET?: boolean | undefined;
|
|
1170
|
-
UPDATE?: boolean | undefined;
|
|
1171
|
-
QUERY?: boolean | undefined;
|
|
1172
|
-
PUT?: boolean | undefined;
|
|
1173
|
-
PATCH?: boolean | undefined;
|
|
1174
|
-
DELETE?: boolean | undefined;
|
|
1175
|
-
}>>;
|
|
1176
|
-
}, "strict", z.ZodTypeAny, {
|
|
1177
|
-
entity: string;
|
|
1178
|
-
entities: string[];
|
|
1179
|
-
api: {
|
|
1180
|
-
GET?: boolean | undefined;
|
|
1181
|
-
UPDATE?: boolean | undefined;
|
|
1182
|
-
QUERY?: boolean | undefined;
|
|
1183
|
-
PUT?: boolean | undefined;
|
|
1184
|
-
PATCH?: boolean | undefined;
|
|
1185
|
-
DELETE?: boolean | undefined;
|
|
1186
|
-
} | null;
|
|
1187
|
-
id?: string | undefined;
|
|
1188
|
-
training?: {
|
|
1189
|
-
text: string;
|
|
1190
|
-
intent: string;
|
|
1191
|
-
}[] | undefined;
|
|
1192
|
-
tests?: {
|
|
1193
|
-
text: string;
|
|
1194
|
-
expected: {
|
|
1195
|
-
intent: string;
|
|
1196
|
-
context?: any;
|
|
1197
|
-
};
|
|
1198
|
-
}[] | undefined;
|
|
1199
|
-
definitions?: {
|
|
1200
|
-
value: string;
|
|
1201
|
-
text: string[];
|
|
1202
|
-
utterance?: string | undefined;
|
|
1203
|
-
}[] | undefined;
|
|
1204
|
-
}, {
|
|
1205
|
-
entity: string;
|
|
1206
|
-
entities: string[];
|
|
1207
|
-
api: {
|
|
1208
|
-
GET?: boolean | undefined;
|
|
1209
|
-
UPDATE?: boolean | undefined;
|
|
1210
|
-
QUERY?: boolean | undefined;
|
|
1211
|
-
PUT?: boolean | undefined;
|
|
1212
|
-
PATCH?: boolean | undefined;
|
|
1213
|
-
DELETE?: boolean | undefined;
|
|
1214
|
-
} | null;
|
|
1215
|
-
id?: string | undefined;
|
|
1216
|
-
training?: {
|
|
1217
|
-
text: string;
|
|
1218
|
-
intent: string;
|
|
1219
|
-
}[] | undefined;
|
|
1220
|
-
tests?: {
|
|
1221
|
-
text: string;
|
|
1222
|
-
expected: {
|
|
1223
|
-
intent: string;
|
|
1224
|
-
context?: any;
|
|
1225
|
-
};
|
|
1226
|
-
}[] | undefined;
|
|
1227
|
-
definitions?: {
|
|
1228
|
-
value: string;
|
|
1229
|
-
text: string[];
|
|
1230
|
-
utterance?: string | undefined;
|
|
1231
|
-
}[] | undefined;
|
|
1232
|
-
}>, {
|
|
1233
|
-
entity: string;
|
|
1234
|
-
entities: string[];
|
|
1235
|
-
api: {
|
|
1236
|
-
GET?: boolean | undefined;
|
|
1237
|
-
UPDATE?: boolean | undefined;
|
|
1238
|
-
QUERY?: boolean | undefined;
|
|
1239
|
-
PUT?: boolean | undefined;
|
|
1240
|
-
PATCH?: boolean | undefined;
|
|
1241
|
-
DELETE?: boolean | undefined;
|
|
1242
|
-
} | null;
|
|
1243
|
-
id?: string | undefined;
|
|
1244
|
-
training?: {
|
|
1245
|
-
text: string;
|
|
1246
|
-
intent: string;
|
|
1247
|
-
}[] | undefined;
|
|
1248
|
-
tests?: {
|
|
1249
|
-
text: string;
|
|
1250
|
-
expected: {
|
|
1251
|
-
intent: string;
|
|
1252
|
-
context?: any;
|
|
1253
|
-
};
|
|
1254
|
-
}[] | undefined;
|
|
1255
|
-
definitions?: {
|
|
1256
|
-
value: string;
|
|
1257
|
-
text: string[];
|
|
1258
|
-
utterance?: string | undefined;
|
|
1259
|
-
}[] | undefined;
|
|
1260
|
-
}, {
|
|
1261
|
-
entity: string;
|
|
1262
|
-
entities: string[];
|
|
1263
|
-
api: {
|
|
1264
|
-
GET?: boolean | undefined;
|
|
1265
|
-
UPDATE?: boolean | undefined;
|
|
1266
|
-
QUERY?: boolean | undefined;
|
|
1267
|
-
PUT?: boolean | undefined;
|
|
1268
|
-
PATCH?: boolean | undefined;
|
|
1269
|
-
DELETE?: boolean | undefined;
|
|
1270
|
-
} | null;
|
|
1271
|
-
id?: string | undefined;
|
|
1272
|
-
training?: {
|
|
1273
|
-
text: string;
|
|
1274
|
-
intent: string;
|
|
1275
|
-
}[] | undefined;
|
|
1276
|
-
tests?: {
|
|
1277
|
-
text: string;
|
|
1278
|
-
expected: {
|
|
1279
|
-
intent: string;
|
|
1280
|
-
context?: any;
|
|
1281
|
-
};
|
|
1282
|
-
}[] | undefined;
|
|
1283
|
-
definitions?: {
|
|
1284
|
-
value: string;
|
|
1285
|
-
text: string[];
|
|
1286
|
-
utterance?: string | undefined;
|
|
1287
|
-
}[] | undefined;
|
|
1288
|
-
}>, "many">;
|
|
1289
|
-
workflows: z.ZodArray<z.ZodObject<{
|
|
1290
|
-
entities: z.ZodArray<z.ZodString, "many">;
|
|
1291
|
-
entity: z.ZodString;
|
|
1292
|
-
}, "strip", z.ZodTypeAny, {
|
|
1293
|
-
entity: string;
|
|
1294
|
-
entities: string[];
|
|
1295
|
-
}, {
|
|
1296
|
-
entity: string;
|
|
1297
|
-
entities: string[];
|
|
1298
|
-
}>, "many">;
|
|
1299
|
-
llm: z.ZodUnion<[z.ZodObject<{
|
|
1300
|
-
engine: z.ZodLiteral<"openai">;
|
|
1301
|
-
model: z.ZodUnion<[z.ZodLiteral<"gpt-4-1106-preview">, z.ZodLiteral<"gpt-4-vision-preview">, z.ZodLiteral<"gpt-4">, z.ZodLiteral<"gpt-4-0314">, z.ZodLiteral<"gpt-4-0613">, z.ZodLiteral<"gpt-4-32k">, z.ZodLiteral<"gpt-4-32k-0314">, z.ZodLiteral<"gpt-4-32k-0613">, z.ZodLiteral<"gpt-3.5-turbo">, z.ZodLiteral<"gpt-3.5-turbo-16k">, z.ZodLiteral<"gpt-3.5-turbo-0301">, z.ZodLiteral<"gpt-3.5-turbo-0613">, z.ZodLiteral<"gpt-3.5-turbo-16k-0613">, z.ZodString]>;
|
|
1302
|
-
}, "strip", z.ZodTypeAny, {
|
|
1303
|
-
model: string;
|
|
1304
|
-
engine: "openai";
|
|
1175
|
+
model: string;
|
|
1176
|
+
engine: "openai";
|
|
1305
1177
|
}, {
|
|
1306
1178
|
model: string;
|
|
1307
1179
|
engine: "openai";
|
|
@@ -1324,6 +1196,9 @@ declare module '@scout9/app/types' {
|
|
|
1324
1196
|
model: string;
|
|
1325
1197
|
engine: "bard";
|
|
1326
1198
|
}>]>;
|
|
1199
|
+
/**
|
|
1200
|
+
* Configure personal model transformer (PMT) settings to align auto replies the agent's tone
|
|
1201
|
+
*/
|
|
1327
1202
|
pmt: z.ZodObject<{
|
|
1328
1203
|
engine: z.ZodLiteral<"scout9">;
|
|
1329
1204
|
model: z.ZodString;
|
|
@@ -1334,8 +1209,13 @@ declare module '@scout9/app/types' {
|
|
|
1334
1209
|
model: string;
|
|
1335
1210
|
engine: "scout9";
|
|
1336
1211
|
}>;
|
|
1212
|
+
/**
|
|
1213
|
+
* Determines the max auto replies without further conversation progression (defined by new context data gathered)
|
|
1214
|
+
* before the conversation is locked and requires manual intervention
|
|
1215
|
+
* @default 3
|
|
1216
|
+
*/
|
|
1217
|
+
maxLockAttempts: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
1337
1218
|
initialContext: z.ZodArray<z.ZodString, "many">;
|
|
1338
|
-
maxLockAttempts: z.ZodOptional<z.ZodNumber>;
|
|
1339
1219
|
organization: z.ZodOptional<z.ZodObject<{
|
|
1340
1220
|
name: z.ZodString;
|
|
1341
1221
|
description: z.ZodString;
|
|
@@ -1368,67 +1248,7 @@ declare module '@scout9/app/types' {
|
|
|
1368
1248
|
phone?: string | undefined;
|
|
1369
1249
|
}>>;
|
|
1370
1250
|
}, "strip", z.ZodTypeAny, {
|
|
1371
|
-
agents: {
|
|
1372
|
-
title: string;
|
|
1373
|
-
context: string;
|
|
1374
|
-
model: "openai" | "bard" | "Scout9";
|
|
1375
|
-
deployed?: {
|
|
1376
|
-
web?: string | undefined;
|
|
1377
|
-
phone?: string | undefined;
|
|
1378
|
-
email?: string | undefined;
|
|
1379
|
-
} | undefined;
|
|
1380
|
-
firstName?: string | undefined;
|
|
1381
|
-
lastName?: string | undefined;
|
|
1382
|
-
inactive?: boolean | undefined;
|
|
1383
|
-
programmablePhoneNumber?: string | undefined;
|
|
1384
|
-
programmablePhoneNumberSid?: string | undefined;
|
|
1385
|
-
programmableEmail?: string | undefined;
|
|
1386
|
-
forwardEmail?: string | undefined;
|
|
1387
|
-
forwardPhone?: string | undefined;
|
|
1388
|
-
includedLocations?: string[] | undefined;
|
|
1389
|
-
excludedLocations?: string[] | undefined;
|
|
1390
|
-
transcripts?: {
|
|
1391
|
-
time: string;
|
|
1392
|
-
content: string;
|
|
1393
|
-
role: "agent" | "customer" | "system";
|
|
1394
|
-
name?: string | undefined;
|
|
1395
|
-
}[][] | undefined;
|
|
1396
|
-
audios?: any[] | undefined;
|
|
1397
|
-
}[];
|
|
1398
|
-
entities: {
|
|
1399
|
-
entity: string;
|
|
1400
|
-
entities: string[];
|
|
1401
|
-
api: {
|
|
1402
|
-
GET?: boolean | undefined;
|
|
1403
|
-
UPDATE?: boolean | undefined;
|
|
1404
|
-
QUERY?: boolean | undefined;
|
|
1405
|
-
PUT?: boolean | undefined;
|
|
1406
|
-
PATCH?: boolean | undefined;
|
|
1407
|
-
DELETE?: boolean | undefined;
|
|
1408
|
-
} | null;
|
|
1409
|
-
id?: string | undefined;
|
|
1410
|
-
training?: {
|
|
1411
|
-
text: string;
|
|
1412
|
-
intent: string;
|
|
1413
|
-
}[] | undefined;
|
|
1414
|
-
tests?: {
|
|
1415
|
-
text: string;
|
|
1416
|
-
expected: {
|
|
1417
|
-
intent: string;
|
|
1418
|
-
context?: any;
|
|
1419
|
-
};
|
|
1420
|
-
}[] | undefined;
|
|
1421
|
-
definitions?: {
|
|
1422
|
-
value: string;
|
|
1423
|
-
text: string[];
|
|
1424
|
-
utterance?: string | undefined;
|
|
1425
|
-
}[] | undefined;
|
|
1426
|
-
}[];
|
|
1427
1251
|
initialContext: string[];
|
|
1428
|
-
workflows: {
|
|
1429
|
-
entity: string;
|
|
1430
|
-
entities: string[];
|
|
1431
|
-
}[];
|
|
1432
1252
|
llm: {
|
|
1433
1253
|
model: string;
|
|
1434
1254
|
engine: "openai";
|
|
@@ -1457,67 +1277,7 @@ declare module '@scout9/app/types' {
|
|
|
1457
1277
|
phone?: string | undefined;
|
|
1458
1278
|
} | undefined;
|
|
1459
1279
|
}, {
|
|
1460
|
-
agents: {
|
|
1461
|
-
deployed?: {
|
|
1462
|
-
web?: string | undefined;
|
|
1463
|
-
phone?: string | undefined;
|
|
1464
|
-
email?: string | undefined;
|
|
1465
|
-
} | undefined;
|
|
1466
|
-
firstName?: string | undefined;
|
|
1467
|
-
lastName?: string | undefined;
|
|
1468
|
-
inactive?: boolean | undefined;
|
|
1469
|
-
programmablePhoneNumber?: string | undefined;
|
|
1470
|
-
programmablePhoneNumberSid?: string | undefined;
|
|
1471
|
-
programmableEmail?: string | undefined;
|
|
1472
|
-
forwardEmail?: string | undefined;
|
|
1473
|
-
forwardPhone?: string | undefined;
|
|
1474
|
-
title?: string | undefined;
|
|
1475
|
-
context?: string | undefined;
|
|
1476
|
-
includedLocations?: string[] | undefined;
|
|
1477
|
-
excludedLocations?: string[] | undefined;
|
|
1478
|
-
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
1479
|
-
transcripts?: {
|
|
1480
|
-
time: string;
|
|
1481
|
-
content: string;
|
|
1482
|
-
role: "agent" | "customer" | "system";
|
|
1483
|
-
name?: string | undefined;
|
|
1484
|
-
}[][] | undefined;
|
|
1485
|
-
audios?: any[] | undefined;
|
|
1486
|
-
}[];
|
|
1487
|
-
entities: {
|
|
1488
|
-
entity: string;
|
|
1489
|
-
entities: string[];
|
|
1490
|
-
api: {
|
|
1491
|
-
GET?: boolean | undefined;
|
|
1492
|
-
UPDATE?: boolean | undefined;
|
|
1493
|
-
QUERY?: boolean | undefined;
|
|
1494
|
-
PUT?: boolean | undefined;
|
|
1495
|
-
PATCH?: boolean | undefined;
|
|
1496
|
-
DELETE?: boolean | undefined;
|
|
1497
|
-
} | null;
|
|
1498
|
-
id?: string | undefined;
|
|
1499
|
-
training?: {
|
|
1500
|
-
text: string;
|
|
1501
|
-
intent: string;
|
|
1502
|
-
}[] | undefined;
|
|
1503
|
-
tests?: {
|
|
1504
|
-
text: string;
|
|
1505
|
-
expected: {
|
|
1506
|
-
intent: string;
|
|
1507
|
-
context?: any;
|
|
1508
|
-
};
|
|
1509
|
-
}[] | undefined;
|
|
1510
|
-
definitions?: {
|
|
1511
|
-
value: string;
|
|
1512
|
-
text: string[];
|
|
1513
|
-
utterance?: string | undefined;
|
|
1514
|
-
}[] | undefined;
|
|
1515
|
-
}[];
|
|
1516
1280
|
initialContext: string[];
|
|
1517
|
-
workflows: {
|
|
1518
|
-
entity: string;
|
|
1519
|
-
entities: string[];
|
|
1520
|
-
}[];
|
|
1521
1281
|
llm: {
|
|
1522
1282
|
model: string;
|
|
1523
1283
|
engine: "openai";
|
|
@@ -1546,438 +1306,732 @@ declare module '@scout9/app/types' {
|
|
|
1546
1306
|
phone?: string | undefined;
|
|
1547
1307
|
} | undefined;
|
|
1548
1308
|
}>;
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
PATCH?: boolean | undefined;
|
|
1562
|
-
DELETE?: boolean | undefined;
|
|
1563
|
-
}, {
|
|
1564
|
-
GET?: boolean | undefined;
|
|
1565
|
-
UPDATE?: boolean | undefined;
|
|
1566
|
-
QUERY?: boolean | undefined;
|
|
1567
|
-
PUT?: boolean | undefined;
|
|
1568
|
-
PATCH?: boolean | undefined;
|
|
1569
|
-
DELETE?: boolean | undefined;
|
|
1570
|
-
}>;
|
|
1571
|
-
export const entityApiConfigurationSchema: z.ZodNullable<z.ZodObject<{
|
|
1572
|
-
GET: z.ZodOptional<z.ZodBoolean>;
|
|
1573
|
-
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
1574
|
-
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
1575
|
-
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
1576
|
-
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
1577
|
-
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
1578
|
-
}, "strip", z.ZodTypeAny, {
|
|
1579
|
-
GET?: boolean | undefined;
|
|
1580
|
-
UPDATE?: boolean | undefined;
|
|
1581
|
-
QUERY?: boolean | undefined;
|
|
1582
|
-
PUT?: boolean | undefined;
|
|
1583
|
-
PATCH?: boolean | undefined;
|
|
1584
|
-
DELETE?: boolean | undefined;
|
|
1585
|
-
}, {
|
|
1586
|
-
GET?: boolean | undefined;
|
|
1587
|
-
UPDATE?: boolean | undefined;
|
|
1588
|
-
QUERY?: boolean | undefined;
|
|
1589
|
-
PUT?: boolean | undefined;
|
|
1590
|
-
PATCH?: boolean | undefined;
|
|
1591
|
-
DELETE?: boolean | undefined;
|
|
1592
|
-
}>>;
|
|
1593
|
-
export const entityConfigurationSchema: z.ZodEffects<z.ZodObject<{
|
|
1594
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1595
|
-
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1596
|
-
utterance: z.ZodOptional<z.ZodString>;
|
|
1597
|
-
value: z.ZodString;
|
|
1598
|
-
text: z.ZodArray<z.ZodString, "many">;
|
|
1309
|
+
|
|
1310
|
+
export const Scout9ProjectBuildConfigSchema: z.ZodObject<{
|
|
1311
|
+
organization: z.ZodOptional<z.ZodObject<{
|
|
1312
|
+
name: z.ZodString;
|
|
1313
|
+
description: z.ZodString;
|
|
1314
|
+
dashboard: z.ZodOptional<z.ZodString>;
|
|
1315
|
+
logo: z.ZodOptional<z.ZodString>;
|
|
1316
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
1317
|
+
logos: z.ZodOptional<z.ZodString>;
|
|
1318
|
+
website: z.ZodOptional<z.ZodString>;
|
|
1319
|
+
email: z.ZodOptional<z.ZodString>;
|
|
1320
|
+
phone: z.ZodOptional<z.ZodString>;
|
|
1599
1321
|
}, "strip", z.ZodTypeAny, {
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1322
|
+
name: string;
|
|
1323
|
+
description: string;
|
|
1324
|
+
dashboard?: string | undefined;
|
|
1325
|
+
logo?: string | undefined;
|
|
1326
|
+
icon?: string | undefined;
|
|
1327
|
+
logos?: string | undefined;
|
|
1328
|
+
website?: string | undefined;
|
|
1329
|
+
email?: string | undefined;
|
|
1330
|
+
phone?: string | undefined;
|
|
1603
1331
|
}, {
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1332
|
+
name: string;
|
|
1333
|
+
description: string;
|
|
1334
|
+
dashboard?: string | undefined;
|
|
1335
|
+
logo?: string | undefined;
|
|
1336
|
+
icon?: string | undefined;
|
|
1337
|
+
logos?: string | undefined;
|
|
1338
|
+
website?: string | undefined;
|
|
1339
|
+
email?: string | undefined;
|
|
1340
|
+
phone?: string | undefined;
|
|
1341
|
+
}>>;
|
|
1342
|
+
initialContext: z.ZodArray<z.ZodString, "many">;
|
|
1343
|
+
tag: z.ZodOptional<z.ZodString>;
|
|
1344
|
+
llm: z.ZodUnion<[z.ZodObject<{
|
|
1345
|
+
engine: z.ZodLiteral<"openai">;
|
|
1346
|
+
model: z.ZodUnion<[z.ZodLiteral<"gpt-4-1106-preview">, z.ZodLiteral<"gpt-4-vision-preview">, z.ZodLiteral<"gpt-4">, z.ZodLiteral<"gpt-4-0314">, z.ZodLiteral<"gpt-4-0613">, z.ZodLiteral<"gpt-4-32k">, z.ZodLiteral<"gpt-4-32k-0314">, z.ZodLiteral<"gpt-4-32k-0613">, z.ZodLiteral<"gpt-3.5-turbo">, z.ZodLiteral<"gpt-3.5-turbo-16k">, z.ZodLiteral<"gpt-3.5-turbo-0301">, z.ZodLiteral<"gpt-3.5-turbo-0613">, z.ZodLiteral<"gpt-3.5-turbo-16k-0613">, z.ZodString]>;
|
|
1611
1347
|
}, "strip", z.ZodTypeAny, {
|
|
1612
|
-
|
|
1613
|
-
|
|
1348
|
+
model: string;
|
|
1349
|
+
engine: "openai";
|
|
1614
1350
|
}, {
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
}>,
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1351
|
+
model: string;
|
|
1352
|
+
engine: "openai";
|
|
1353
|
+
}>, z.ZodObject<{
|
|
1354
|
+
engine: z.ZodLiteral<"llama">;
|
|
1355
|
+
model: z.ZodString;
|
|
1356
|
+
}, "strip", z.ZodTypeAny, {
|
|
1357
|
+
model: string;
|
|
1358
|
+
engine: "llama";
|
|
1359
|
+
}, {
|
|
1360
|
+
model: string;
|
|
1361
|
+
engine: "llama";
|
|
1362
|
+
}>, z.ZodObject<{
|
|
1363
|
+
engine: z.ZodLiteral<"bard">;
|
|
1364
|
+
model: z.ZodString;
|
|
1365
|
+
}, "strip", z.ZodTypeAny, {
|
|
1366
|
+
model: string;
|
|
1367
|
+
engine: "bard";
|
|
1368
|
+
}, {
|
|
1369
|
+
model: string;
|
|
1370
|
+
engine: "bard";
|
|
1371
|
+
}>]>;
|
|
1372
|
+
pmt: z.ZodObject<{
|
|
1373
|
+
engine: z.ZodLiteral<"scout9">;
|
|
1374
|
+
model: z.ZodString;
|
|
1375
|
+
}, "strip", z.ZodTypeAny, {
|
|
1376
|
+
model: string;
|
|
1377
|
+
engine: "scout9";
|
|
1378
|
+
}, {
|
|
1379
|
+
model: string;
|
|
1380
|
+
engine: "scout9";
|
|
1381
|
+
}>;
|
|
1382
|
+
maxLockAttempts: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
|
|
1383
|
+
agents: z.ZodArray<z.ZodObject<{
|
|
1384
|
+
deployed: z.ZodOptional<z.ZodObject<{
|
|
1385
|
+
web: z.ZodOptional<z.ZodString>;
|
|
1386
|
+
phone: z.ZodOptional<z.ZodString>;
|
|
1387
|
+
email: z.ZodOptional<z.ZodString>;
|
|
1623
1388
|
}, "strip", z.ZodTypeAny, {
|
|
1624
|
-
|
|
1389
|
+
web?: string | undefined;
|
|
1390
|
+
phone?: string | undefined;
|
|
1391
|
+
email?: string | undefined;
|
|
1392
|
+
}, {
|
|
1393
|
+
web?: string | undefined;
|
|
1394
|
+
phone?: string | undefined;
|
|
1395
|
+
email?: string | undefined;
|
|
1396
|
+
}>>;
|
|
1397
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1398
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
1399
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
1400
|
+
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
1401
|
+
programmablePhoneNumber: z.ZodOptional<z.ZodString>;
|
|
1402
|
+
programmablePhoneNumberSid: z.ZodOptional<z.ZodString>;
|
|
1403
|
+
programmableEmail: z.ZodOptional<z.ZodString>;
|
|
1404
|
+
forwardEmail: z.ZodOptional<z.ZodString>;
|
|
1405
|
+
forwardPhone: z.ZodOptional<z.ZodString>;
|
|
1406
|
+
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1407
|
+
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1408
|
+
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1409
|
+
excludedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1410
|
+
model: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Scout9", "bard", "openai"]>>>;
|
|
1411
|
+
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
1412
|
+
id: z.ZodString;
|
|
1413
|
+
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
1414
|
+
content: z.ZodString;
|
|
1415
|
+
time: z.ZodString;
|
|
1416
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1417
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
1418
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
1419
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
1420
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1421
|
+
}, "strip", z.ZodTypeAny, {
|
|
1422
|
+
time: string;
|
|
1423
|
+
id: string;
|
|
1424
|
+
content: string;
|
|
1425
|
+
role: "agent" | "customer" | "system";
|
|
1426
|
+
name?: string | undefined;
|
|
1427
|
+
scheduled?: string | undefined;
|
|
1625
1428
|
context?: any;
|
|
1429
|
+
intent?: string | null | undefined;
|
|
1430
|
+
intentScore?: number | null | undefined;
|
|
1626
1431
|
}, {
|
|
1627
|
-
|
|
1432
|
+
time: string;
|
|
1433
|
+
id: string;
|
|
1434
|
+
content: string;
|
|
1435
|
+
role: "agent" | "customer" | "system";
|
|
1436
|
+
name?: string | undefined;
|
|
1437
|
+
scheduled?: string | undefined;
|
|
1628
1438
|
context?: any;
|
|
1629
|
-
|
|
1439
|
+
intent?: string | null | undefined;
|
|
1440
|
+
intentScore?: number | null | undefined;
|
|
1441
|
+
}>, "many">, "many">>;
|
|
1442
|
+
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
1630
1443
|
}, "strip", z.ZodTypeAny, {
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
intent: string;
|
|
1658
|
-
context?: any;
|
|
1659
|
-
};
|
|
1660
|
-
}[] | undefined;
|
|
1661
|
-
}, {
|
|
1662
|
-
id?: string | undefined;
|
|
1663
|
-
definitions?: {
|
|
1664
|
-
value: string;
|
|
1665
|
-
text: string[];
|
|
1666
|
-
utterance?: string | undefined;
|
|
1667
|
-
}[] | undefined;
|
|
1668
|
-
training?: {
|
|
1669
|
-
text: string;
|
|
1670
|
-
intent: string;
|
|
1671
|
-
}[] | undefined;
|
|
1672
|
-
tests?: {
|
|
1673
|
-
text: string;
|
|
1674
|
-
expected: {
|
|
1675
|
-
intent: string;
|
|
1676
|
-
context?: any;
|
|
1677
|
-
};
|
|
1678
|
-
}[] | undefined;
|
|
1679
|
-
}>, {
|
|
1680
|
-
id?: string | undefined;
|
|
1681
|
-
definitions?: {
|
|
1682
|
-
value: string;
|
|
1683
|
-
text: string[];
|
|
1684
|
-
utterance?: string | undefined;
|
|
1685
|
-
}[] | undefined;
|
|
1686
|
-
training?: {
|
|
1687
|
-
text: string;
|
|
1688
|
-
intent: string;
|
|
1689
|
-
}[] | undefined;
|
|
1690
|
-
tests?: {
|
|
1691
|
-
text: string;
|
|
1692
|
-
expected: {
|
|
1693
|
-
intent: string;
|
|
1694
|
-
context?: any;
|
|
1695
|
-
};
|
|
1696
|
-
}[] | undefined;
|
|
1697
|
-
}, {
|
|
1698
|
-
id?: string | undefined;
|
|
1699
|
-
definitions?: {
|
|
1700
|
-
value: string;
|
|
1701
|
-
text: string[];
|
|
1702
|
-
utterance?: string | undefined;
|
|
1703
|
-
}[] | undefined;
|
|
1704
|
-
training?: {
|
|
1705
|
-
text: string;
|
|
1706
|
-
intent: string;
|
|
1707
|
-
}[] | undefined;
|
|
1708
|
-
tests?: {
|
|
1709
|
-
text: string;
|
|
1710
|
-
expected: {
|
|
1711
|
-
intent: string;
|
|
1444
|
+
title: string;
|
|
1445
|
+
context: string;
|
|
1446
|
+
model: "openai" | "bard" | "Scout9";
|
|
1447
|
+
deployed?: {
|
|
1448
|
+
web?: string | undefined;
|
|
1449
|
+
phone?: string | undefined;
|
|
1450
|
+
email?: string | undefined;
|
|
1451
|
+
} | undefined;
|
|
1452
|
+
img?: string | null | undefined;
|
|
1453
|
+
firstName?: string | undefined;
|
|
1454
|
+
lastName?: string | undefined;
|
|
1455
|
+
inactive?: boolean | undefined;
|
|
1456
|
+
programmablePhoneNumber?: string | undefined;
|
|
1457
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
1458
|
+
programmableEmail?: string | undefined;
|
|
1459
|
+
forwardEmail?: string | undefined;
|
|
1460
|
+
forwardPhone?: string | undefined;
|
|
1461
|
+
includedLocations?: string[] | undefined;
|
|
1462
|
+
excludedLocations?: string[] | undefined;
|
|
1463
|
+
transcripts?: {
|
|
1464
|
+
time: string;
|
|
1465
|
+
id: string;
|
|
1466
|
+
content: string;
|
|
1467
|
+
role: "agent" | "customer" | "system";
|
|
1468
|
+
name?: string | undefined;
|
|
1469
|
+
scheduled?: string | undefined;
|
|
1712
1470
|
context?: any;
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1718
|
-
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1719
|
-
utterance: z.ZodOptional<z.ZodString>;
|
|
1720
|
-
value: z.ZodString;
|
|
1721
|
-
text: z.ZodArray<z.ZodString, "many">;
|
|
1722
|
-
}, "strip", z.ZodTypeAny, {
|
|
1723
|
-
value: string;
|
|
1724
|
-
text: string[];
|
|
1725
|
-
utterance?: string | undefined;
|
|
1726
|
-
}, {
|
|
1727
|
-
value: string;
|
|
1728
|
-
text: string[];
|
|
1729
|
-
utterance?: string | undefined;
|
|
1730
|
-
}>, "many">>;
|
|
1731
|
-
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1732
|
-
intent: z.ZodString;
|
|
1733
|
-
text: z.ZodString;
|
|
1734
|
-
}, "strip", z.ZodTypeAny, {
|
|
1735
|
-
text: string;
|
|
1736
|
-
intent: string;
|
|
1471
|
+
intent?: string | null | undefined;
|
|
1472
|
+
intentScore?: number | null | undefined;
|
|
1473
|
+
}[][] | undefined;
|
|
1474
|
+
audios?: any[] | undefined;
|
|
1737
1475
|
}, {
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1476
|
+
deployed?: {
|
|
1477
|
+
web?: string | undefined;
|
|
1478
|
+
phone?: string | undefined;
|
|
1479
|
+
email?: string | undefined;
|
|
1480
|
+
} | undefined;
|
|
1481
|
+
img?: string | null | undefined;
|
|
1482
|
+
firstName?: string | undefined;
|
|
1483
|
+
lastName?: string | undefined;
|
|
1484
|
+
inactive?: boolean | undefined;
|
|
1485
|
+
programmablePhoneNumber?: string | undefined;
|
|
1486
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
1487
|
+
programmableEmail?: string | undefined;
|
|
1488
|
+
forwardEmail?: string | undefined;
|
|
1489
|
+
forwardPhone?: string | undefined;
|
|
1490
|
+
title?: string | undefined;
|
|
1491
|
+
context?: string | undefined;
|
|
1492
|
+
includedLocations?: string[] | undefined;
|
|
1493
|
+
excludedLocations?: string[] | undefined;
|
|
1494
|
+
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
1495
|
+
transcripts?: {
|
|
1496
|
+
time: string;
|
|
1497
|
+
id: string;
|
|
1498
|
+
content: string;
|
|
1499
|
+
role: "agent" | "customer" | "system";
|
|
1500
|
+
name?: string | undefined;
|
|
1501
|
+
scheduled?: string | undefined;
|
|
1502
|
+
context?: any;
|
|
1503
|
+
intent?: string | null | undefined;
|
|
1504
|
+
intentScore?: number | null | undefined;
|
|
1505
|
+
}[][] | undefined;
|
|
1506
|
+
audios?: any[] | undefined;
|
|
1507
|
+
}>, "many">;
|
|
1508
|
+
entities: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
1509
|
+
id: z.ZodOptional<z.ZodString>;
|
|
1510
|
+
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1744
1511
|
intent: z.ZodString;
|
|
1745
|
-
|
|
1512
|
+
text: z.ZodString;
|
|
1746
1513
|
}, "strip", z.ZodTypeAny, {
|
|
1514
|
+
text: string;
|
|
1747
1515
|
intent: string;
|
|
1748
|
-
context?: any;
|
|
1749
1516
|
}, {
|
|
1517
|
+
text: string;
|
|
1750
1518
|
intent: string;
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1519
|
+
}>, "many">>;
|
|
1520
|
+
tests: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1521
|
+
text: z.ZodString;
|
|
1522
|
+
expected: z.ZodObject<{
|
|
1523
|
+
intent: z.ZodString;
|
|
1524
|
+
context: z.ZodAny;
|
|
1525
|
+
}, "strip", z.ZodTypeAny, {
|
|
1526
|
+
intent: string;
|
|
1527
|
+
context?: any;
|
|
1528
|
+
}, {
|
|
1529
|
+
intent: string;
|
|
1530
|
+
context?: any;
|
|
1531
|
+
}>;
|
|
1532
|
+
}, "strip", z.ZodTypeAny, {
|
|
1533
|
+
text: string;
|
|
1534
|
+
expected: {
|
|
1535
|
+
intent: string;
|
|
1536
|
+
context?: any;
|
|
1537
|
+
};
|
|
1538
|
+
}, {
|
|
1539
|
+
text: string;
|
|
1540
|
+
expected: {
|
|
1541
|
+
intent: string;
|
|
1542
|
+
context?: any;
|
|
1543
|
+
};
|
|
1544
|
+
}>, "many">>;
|
|
1545
|
+
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1546
|
+
utterance: z.ZodOptional<z.ZodString>;
|
|
1547
|
+
value: z.ZodString;
|
|
1548
|
+
text: z.ZodArray<z.ZodString, "many">;
|
|
1549
|
+
}, "strip", z.ZodTypeAny, {
|
|
1550
|
+
value: string;
|
|
1551
|
+
text: string[];
|
|
1552
|
+
utterance?: string | undefined;
|
|
1553
|
+
}, {
|
|
1554
|
+
value: string;
|
|
1555
|
+
text: string[];
|
|
1556
|
+
utterance?: string | undefined;
|
|
1557
|
+
}>, "many">>;
|
|
1558
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
1559
|
+
entity: z.ZodString;
|
|
1560
|
+
api: z.ZodNullable<z.ZodObject<{
|
|
1561
|
+
GET: z.ZodOptional<z.ZodBoolean>;
|
|
1562
|
+
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
1563
|
+
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
1564
|
+
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
1565
|
+
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
1566
|
+
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
1567
|
+
}, "strip", z.ZodTypeAny, {
|
|
1568
|
+
GET?: boolean | undefined;
|
|
1569
|
+
UPDATE?: boolean | undefined;
|
|
1570
|
+
QUERY?: boolean | undefined;
|
|
1571
|
+
PUT?: boolean | undefined;
|
|
1572
|
+
PATCH?: boolean | undefined;
|
|
1573
|
+
DELETE?: boolean | undefined;
|
|
1574
|
+
}, {
|
|
1575
|
+
GET?: boolean | undefined;
|
|
1576
|
+
UPDATE?: boolean | undefined;
|
|
1577
|
+
QUERY?: boolean | undefined;
|
|
1578
|
+
PUT?: boolean | undefined;
|
|
1579
|
+
PATCH?: boolean | undefined;
|
|
1580
|
+
DELETE?: boolean | undefined;
|
|
1581
|
+
}>>;
|
|
1582
|
+
}, "strict", z.ZodTypeAny, {
|
|
1583
|
+
entity: string;
|
|
1584
|
+
entities: string[];
|
|
1585
|
+
api: {
|
|
1586
|
+
GET?: boolean | undefined;
|
|
1587
|
+
UPDATE?: boolean | undefined;
|
|
1588
|
+
QUERY?: boolean | undefined;
|
|
1589
|
+
PUT?: boolean | undefined;
|
|
1590
|
+
PATCH?: boolean | undefined;
|
|
1591
|
+
DELETE?: boolean | undefined;
|
|
1592
|
+
} | null;
|
|
1593
|
+
id?: string | undefined;
|
|
1594
|
+
training?: {
|
|
1595
|
+
text: string;
|
|
1762
1596
|
intent: string;
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
}[] | undefined;
|
|
1777
|
-
tests?: {
|
|
1778
|
-
text: string;
|
|
1779
|
-
expected: {
|
|
1780
|
-
intent: string;
|
|
1781
|
-
context?: any;
|
|
1782
|
-
};
|
|
1783
|
-
}[] | undefined;
|
|
1784
|
-
}, {
|
|
1785
|
-
id?: string | undefined;
|
|
1786
|
-
definitions?: {
|
|
1787
|
-
value: string;
|
|
1788
|
-
text: string[];
|
|
1789
|
-
utterance?: string | undefined;
|
|
1790
|
-
}[] | undefined;
|
|
1791
|
-
training?: {
|
|
1792
|
-
text: string;
|
|
1793
|
-
intent: string;
|
|
1794
|
-
}[] | undefined;
|
|
1795
|
-
tests?: {
|
|
1796
|
-
text: string;
|
|
1797
|
-
expected: {
|
|
1798
|
-
intent: string;
|
|
1799
|
-
context?: any;
|
|
1800
|
-
};
|
|
1801
|
-
}[] | undefined;
|
|
1802
|
-
}>, {
|
|
1803
|
-
id?: string | undefined;
|
|
1804
|
-
definitions?: {
|
|
1805
|
-
value: string;
|
|
1806
|
-
text: string[];
|
|
1807
|
-
utterance?: string | undefined;
|
|
1808
|
-
}[] | undefined;
|
|
1809
|
-
training?: {
|
|
1810
|
-
text: string;
|
|
1811
|
-
intent: string;
|
|
1812
|
-
}[] | undefined;
|
|
1813
|
-
tests?: {
|
|
1814
|
-
text: string;
|
|
1815
|
-
expected: {
|
|
1816
|
-
intent: string;
|
|
1817
|
-
context?: any;
|
|
1818
|
-
};
|
|
1819
|
-
}[] | undefined;
|
|
1820
|
-
}, {
|
|
1821
|
-
id?: string | undefined;
|
|
1822
|
-
definitions?: {
|
|
1823
|
-
value: string;
|
|
1824
|
-
text: string[];
|
|
1825
|
-
utterance?: string | undefined;
|
|
1826
|
-
}[] | undefined;
|
|
1827
|
-
training?: {
|
|
1828
|
-
text: string;
|
|
1829
|
-
intent: string;
|
|
1830
|
-
}[] | undefined;
|
|
1831
|
-
tests?: {
|
|
1832
|
-
text: string;
|
|
1833
|
-
expected: {
|
|
1834
|
-
intent: string;
|
|
1835
|
-
context?: any;
|
|
1836
|
-
};
|
|
1837
|
-
}[] | undefined;
|
|
1838
|
-
}>, "many">;
|
|
1839
|
-
export const entityRootProjectConfigurationSchema: z.ZodEffects<z.ZodObject<{
|
|
1840
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1841
|
-
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1842
|
-
intent: z.ZodString;
|
|
1843
|
-
text: z.ZodString;
|
|
1844
|
-
}, "strip", z.ZodTypeAny, {
|
|
1845
|
-
text: string;
|
|
1846
|
-
intent: string;
|
|
1597
|
+
}[] | undefined;
|
|
1598
|
+
tests?: {
|
|
1599
|
+
text: string;
|
|
1600
|
+
expected: {
|
|
1601
|
+
intent: string;
|
|
1602
|
+
context?: any;
|
|
1603
|
+
};
|
|
1604
|
+
}[] | undefined;
|
|
1605
|
+
definitions?: {
|
|
1606
|
+
value: string;
|
|
1607
|
+
text: string[];
|
|
1608
|
+
utterance?: string | undefined;
|
|
1609
|
+
}[] | undefined;
|
|
1847
1610
|
}, {
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1611
|
+
entity: string;
|
|
1612
|
+
entities: string[];
|
|
1613
|
+
api: {
|
|
1614
|
+
GET?: boolean | undefined;
|
|
1615
|
+
UPDATE?: boolean | undefined;
|
|
1616
|
+
QUERY?: boolean | undefined;
|
|
1617
|
+
PUT?: boolean | undefined;
|
|
1618
|
+
PATCH?: boolean | undefined;
|
|
1619
|
+
DELETE?: boolean | undefined;
|
|
1620
|
+
} | null;
|
|
1621
|
+
id?: string | undefined;
|
|
1622
|
+
training?: {
|
|
1623
|
+
text: string;
|
|
1860
1624
|
intent: string;
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1625
|
+
}[] | undefined;
|
|
1626
|
+
tests?: {
|
|
1627
|
+
text: string;
|
|
1628
|
+
expected: {
|
|
1629
|
+
intent: string;
|
|
1630
|
+
context?: any;
|
|
1631
|
+
};
|
|
1632
|
+
}[] | undefined;
|
|
1633
|
+
definitions?: {
|
|
1634
|
+
value: string;
|
|
1635
|
+
text: string[];
|
|
1636
|
+
utterance?: string | undefined;
|
|
1637
|
+
}[] | undefined;
|
|
1638
|
+
}>, {
|
|
1639
|
+
entity: string;
|
|
1640
|
+
entities: string[];
|
|
1641
|
+
api: {
|
|
1642
|
+
GET?: boolean | undefined;
|
|
1643
|
+
UPDATE?: boolean | undefined;
|
|
1644
|
+
QUERY?: boolean | undefined;
|
|
1645
|
+
PUT?: boolean | undefined;
|
|
1646
|
+
PATCH?: boolean | undefined;
|
|
1647
|
+
DELETE?: boolean | undefined;
|
|
1648
|
+
} | null;
|
|
1649
|
+
id?: string | undefined;
|
|
1650
|
+
training?: {
|
|
1651
|
+
text: string;
|
|
1866
1652
|
intent: string;
|
|
1867
|
-
|
|
1868
|
-
|
|
1653
|
+
}[] | undefined;
|
|
1654
|
+
tests?: {
|
|
1655
|
+
text: string;
|
|
1656
|
+
expected: {
|
|
1657
|
+
intent: string;
|
|
1658
|
+
context?: any;
|
|
1659
|
+
};
|
|
1660
|
+
}[] | undefined;
|
|
1661
|
+
definitions?: {
|
|
1662
|
+
value: string;
|
|
1663
|
+
text: string[];
|
|
1664
|
+
utterance?: string | undefined;
|
|
1665
|
+
}[] | undefined;
|
|
1869
1666
|
}, {
|
|
1870
|
-
|
|
1871
|
-
|
|
1667
|
+
entity: string;
|
|
1668
|
+
entities: string[];
|
|
1669
|
+
api: {
|
|
1670
|
+
GET?: boolean | undefined;
|
|
1671
|
+
UPDATE?: boolean | undefined;
|
|
1672
|
+
QUERY?: boolean | undefined;
|
|
1673
|
+
PUT?: boolean | undefined;
|
|
1674
|
+
PATCH?: boolean | undefined;
|
|
1675
|
+
DELETE?: boolean | undefined;
|
|
1676
|
+
} | null;
|
|
1677
|
+
id?: string | undefined;
|
|
1678
|
+
training?: {
|
|
1679
|
+
text: string;
|
|
1872
1680
|
intent: string;
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
entity: z.ZodString;
|
|
1891
|
-
api: z.ZodNullable<z.ZodObject<{
|
|
1892
|
-
GET: z.ZodOptional<z.ZodBoolean>;
|
|
1893
|
-
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
1894
|
-
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
1895
|
-
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
1896
|
-
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
1897
|
-
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
1681
|
+
}[] | undefined;
|
|
1682
|
+
tests?: {
|
|
1683
|
+
text: string;
|
|
1684
|
+
expected: {
|
|
1685
|
+
intent: string;
|
|
1686
|
+
context?: any;
|
|
1687
|
+
};
|
|
1688
|
+
}[] | undefined;
|
|
1689
|
+
definitions?: {
|
|
1690
|
+
value: string;
|
|
1691
|
+
text: string[];
|
|
1692
|
+
utterance?: string | undefined;
|
|
1693
|
+
}[] | undefined;
|
|
1694
|
+
}>, "many">;
|
|
1695
|
+
workflows: z.ZodArray<z.ZodObject<{
|
|
1696
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
1697
|
+
entity: z.ZodString;
|
|
1898
1698
|
}, "strip", z.ZodTypeAny, {
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
QUERY?: boolean | undefined;
|
|
1902
|
-
PUT?: boolean | undefined;
|
|
1903
|
-
PATCH?: boolean | undefined;
|
|
1904
|
-
DELETE?: boolean | undefined;
|
|
1699
|
+
entity: string;
|
|
1700
|
+
entities: string[];
|
|
1905
1701
|
}, {
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1702
|
+
entity: string;
|
|
1703
|
+
entities: string[];
|
|
1704
|
+
}>, "many">;
|
|
1705
|
+
}, "strip", z.ZodTypeAny, {
|
|
1706
|
+
agents: {
|
|
1707
|
+
title: string;
|
|
1708
|
+
context: string;
|
|
1709
|
+
model: "openai" | "bard" | "Scout9";
|
|
1710
|
+
deployed?: {
|
|
1711
|
+
web?: string | undefined;
|
|
1712
|
+
phone?: string | undefined;
|
|
1713
|
+
email?: string | undefined;
|
|
1714
|
+
} | undefined;
|
|
1715
|
+
img?: string | null | undefined;
|
|
1716
|
+
firstName?: string | undefined;
|
|
1717
|
+
lastName?: string | undefined;
|
|
1718
|
+
inactive?: boolean | undefined;
|
|
1719
|
+
programmablePhoneNumber?: string | undefined;
|
|
1720
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
1721
|
+
programmableEmail?: string | undefined;
|
|
1722
|
+
forwardEmail?: string | undefined;
|
|
1723
|
+
forwardPhone?: string | undefined;
|
|
1724
|
+
includedLocations?: string[] | undefined;
|
|
1725
|
+
excludedLocations?: string[] | undefined;
|
|
1726
|
+
transcripts?: {
|
|
1727
|
+
time: string;
|
|
1728
|
+
id: string;
|
|
1729
|
+
content: string;
|
|
1730
|
+
role: "agent" | "customer" | "system";
|
|
1731
|
+
name?: string | undefined;
|
|
1732
|
+
scheduled?: string | undefined;
|
|
1733
|
+
context?: any;
|
|
1734
|
+
intent?: string | null | undefined;
|
|
1735
|
+
intentScore?: number | null | undefined;
|
|
1736
|
+
}[][] | undefined;
|
|
1737
|
+
audios?: any[] | undefined;
|
|
1738
|
+
}[];
|
|
1739
|
+
entities: {
|
|
1740
|
+
entity: string;
|
|
1741
|
+
entities: string[];
|
|
1742
|
+
api: {
|
|
1743
|
+
GET?: boolean | undefined;
|
|
1744
|
+
UPDATE?: boolean | undefined;
|
|
1745
|
+
QUERY?: boolean | undefined;
|
|
1746
|
+
PUT?: boolean | undefined;
|
|
1747
|
+
PATCH?: boolean | undefined;
|
|
1748
|
+
DELETE?: boolean | undefined;
|
|
1749
|
+
} | null;
|
|
1750
|
+
id?: string | undefined;
|
|
1751
|
+
training?: {
|
|
1752
|
+
text: string;
|
|
1932
1753
|
intent: string;
|
|
1754
|
+
}[] | undefined;
|
|
1755
|
+
tests?: {
|
|
1756
|
+
text: string;
|
|
1757
|
+
expected: {
|
|
1758
|
+
intent: string;
|
|
1759
|
+
context?: any;
|
|
1760
|
+
};
|
|
1761
|
+
}[] | undefined;
|
|
1762
|
+
definitions?: {
|
|
1763
|
+
value: string;
|
|
1764
|
+
text: string[];
|
|
1765
|
+
utterance?: string | undefined;
|
|
1766
|
+
}[] | undefined;
|
|
1767
|
+
}[];
|
|
1768
|
+
initialContext: string[];
|
|
1769
|
+
llm: {
|
|
1770
|
+
model: string;
|
|
1771
|
+
engine: "openai";
|
|
1772
|
+
} | {
|
|
1773
|
+
model: string;
|
|
1774
|
+
engine: "llama";
|
|
1775
|
+
} | {
|
|
1776
|
+
model: string;
|
|
1777
|
+
engine: "bard";
|
|
1778
|
+
};
|
|
1779
|
+
pmt: {
|
|
1780
|
+
model: string;
|
|
1781
|
+
engine: "scout9";
|
|
1782
|
+
};
|
|
1783
|
+
workflows: {
|
|
1784
|
+
entity: string;
|
|
1785
|
+
entities: string[];
|
|
1786
|
+
}[];
|
|
1787
|
+
organization?: {
|
|
1788
|
+
name: string;
|
|
1789
|
+
description: string;
|
|
1790
|
+
dashboard?: string | undefined;
|
|
1791
|
+
logo?: string | undefined;
|
|
1792
|
+
icon?: string | undefined;
|
|
1793
|
+
logos?: string | undefined;
|
|
1794
|
+
website?: string | undefined;
|
|
1795
|
+
email?: string | undefined;
|
|
1796
|
+
phone?: string | undefined;
|
|
1797
|
+
} | undefined;
|
|
1798
|
+
tag?: string | undefined;
|
|
1799
|
+
maxLockAttempts?: number | undefined;
|
|
1800
|
+
}, {
|
|
1801
|
+
agents: {
|
|
1802
|
+
deployed?: {
|
|
1803
|
+
web?: string | undefined;
|
|
1804
|
+
phone?: string | undefined;
|
|
1805
|
+
email?: string | undefined;
|
|
1806
|
+
} | undefined;
|
|
1807
|
+
img?: string | null | undefined;
|
|
1808
|
+
firstName?: string | undefined;
|
|
1809
|
+
lastName?: string | undefined;
|
|
1810
|
+
inactive?: boolean | undefined;
|
|
1811
|
+
programmablePhoneNumber?: string | undefined;
|
|
1812
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
1813
|
+
programmableEmail?: string | undefined;
|
|
1814
|
+
forwardEmail?: string | undefined;
|
|
1815
|
+
forwardPhone?: string | undefined;
|
|
1816
|
+
title?: string | undefined;
|
|
1817
|
+
context?: string | undefined;
|
|
1818
|
+
includedLocations?: string[] | undefined;
|
|
1819
|
+
excludedLocations?: string[] | undefined;
|
|
1820
|
+
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
1821
|
+
transcripts?: {
|
|
1822
|
+
time: string;
|
|
1823
|
+
id: string;
|
|
1824
|
+
content: string;
|
|
1825
|
+
role: "agent" | "customer" | "system";
|
|
1826
|
+
name?: string | undefined;
|
|
1827
|
+
scheduled?: string | undefined;
|
|
1933
1828
|
context?: any;
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1829
|
+
intent?: string | null | undefined;
|
|
1830
|
+
intentScore?: number | null | undefined;
|
|
1831
|
+
}[][] | undefined;
|
|
1832
|
+
audios?: any[] | undefined;
|
|
1833
|
+
}[];
|
|
1834
|
+
entities: {
|
|
1835
|
+
entity: string;
|
|
1836
|
+
entities: string[];
|
|
1837
|
+
api: {
|
|
1838
|
+
GET?: boolean | undefined;
|
|
1839
|
+
UPDATE?: boolean | undefined;
|
|
1840
|
+
QUERY?: boolean | undefined;
|
|
1841
|
+
PUT?: boolean | undefined;
|
|
1842
|
+
PATCH?: boolean | undefined;
|
|
1843
|
+
DELETE?: boolean | undefined;
|
|
1844
|
+
} | null;
|
|
1845
|
+
id?: string | undefined;
|
|
1846
|
+
training?: {
|
|
1847
|
+
text: string;
|
|
1848
|
+
intent: string;
|
|
1849
|
+
}[] | undefined;
|
|
1850
|
+
tests?: {
|
|
1851
|
+
text: string;
|
|
1852
|
+
expected: {
|
|
1853
|
+
intent: string;
|
|
1854
|
+
context?: any;
|
|
1855
|
+
};
|
|
1856
|
+
}[] | undefined;
|
|
1857
|
+
definitions?: {
|
|
1858
|
+
value: string;
|
|
1859
|
+
text: string[];
|
|
1860
|
+
utterance?: string | undefined;
|
|
1861
|
+
}[] | undefined;
|
|
1862
|
+
}[];
|
|
1863
|
+
initialContext: string[];
|
|
1864
|
+
llm: {
|
|
1865
|
+
model: string;
|
|
1866
|
+
engine: "openai";
|
|
1867
|
+
} | {
|
|
1868
|
+
model: string;
|
|
1869
|
+
engine: "llama";
|
|
1870
|
+
} | {
|
|
1871
|
+
model: string;
|
|
1872
|
+
engine: "bard";
|
|
1873
|
+
};
|
|
1874
|
+
pmt: {
|
|
1875
|
+
model: string;
|
|
1876
|
+
engine: "scout9";
|
|
1877
|
+
};
|
|
1878
|
+
workflows: {
|
|
1879
|
+
entity: string;
|
|
1880
|
+
entities: string[];
|
|
1881
|
+
}[];
|
|
1882
|
+
organization?: {
|
|
1883
|
+
name: string;
|
|
1884
|
+
description: string;
|
|
1885
|
+
dashboard?: string | undefined;
|
|
1886
|
+
logo?: string | undefined;
|
|
1887
|
+
icon?: string | undefined;
|
|
1888
|
+
logos?: string | undefined;
|
|
1889
|
+
website?: string | undefined;
|
|
1890
|
+
email?: string | undefined;
|
|
1891
|
+
phone?: string | undefined;
|
|
1892
|
+
} | undefined;
|
|
1893
|
+
tag?: string | undefined;
|
|
1894
|
+
maxLockAttempts?: number | undefined;
|
|
1895
|
+
}>;
|
|
1896
|
+
/**
|
|
1897
|
+
* Represents the configuration provided in src/index.{js | ts} in a project
|
|
1898
|
+
*/
|
|
1899
|
+
export type IScout9ProjectConfig = import('zod').infer<typeof Scout9ProjectConfigSchema>;
|
|
1900
|
+
export type IScout9ProjectBuildConfig = import('zod').infer<typeof Scout9ProjectBuildConfigSchema>;
|
|
1901
|
+
export const entityApiConfigurationSchema: z.ZodNullable<z.ZodObject<{
|
|
1902
|
+
GET: z.ZodOptional<z.ZodBoolean>;
|
|
1903
|
+
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
1904
|
+
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
1905
|
+
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
1906
|
+
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
1907
|
+
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
1908
|
+
}, "strip", z.ZodTypeAny, {
|
|
1909
|
+
GET?: boolean | undefined;
|
|
1910
|
+
UPDATE?: boolean | undefined;
|
|
1911
|
+
QUERY?: boolean | undefined;
|
|
1912
|
+
PUT?: boolean | undefined;
|
|
1913
|
+
PATCH?: boolean | undefined;
|
|
1914
|
+
DELETE?: boolean | undefined;
|
|
1915
|
+
}, {
|
|
1916
|
+
GET?: boolean | undefined;
|
|
1917
|
+
UPDATE?: boolean | undefined;
|
|
1918
|
+
QUERY?: boolean | undefined;
|
|
1919
|
+
PUT?: boolean | undefined;
|
|
1920
|
+
PATCH?: boolean | undefined;
|
|
1921
|
+
DELETE?: boolean | undefined;
|
|
1922
|
+
}>>;
|
|
1923
|
+
|
|
1924
|
+
export const entityConfigurationSchema: z.ZodEffects<z.ZodObject<{
|
|
1925
|
+
id: z.ZodOptional<z.ZodString>;
|
|
1926
|
+
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1927
|
+
utterance: z.ZodOptional<z.ZodString>;
|
|
1928
|
+
value: z.ZodString;
|
|
1929
|
+
text: z.ZodArray<z.ZodString, "many">;
|
|
1930
|
+
}, "strip", z.ZodTypeAny, {
|
|
1937
1931
|
value: string;
|
|
1938
1932
|
text: string[];
|
|
1939
1933
|
utterance?: string | undefined;
|
|
1940
|
-
}
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
PATCH?: boolean | undefined;
|
|
1950
|
-
DELETE?: boolean | undefined;
|
|
1951
|
-
} | null;
|
|
1952
|
-
id?: string | undefined;
|
|
1953
|
-
training?: {
|
|
1934
|
+
}, {
|
|
1935
|
+
value: string;
|
|
1936
|
+
text: string[];
|
|
1937
|
+
utterance?: string | undefined;
|
|
1938
|
+
}>, "many">>;
|
|
1939
|
+
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1940
|
+
intent: z.ZodString;
|
|
1941
|
+
text: z.ZodString;
|
|
1942
|
+
}, "strip", z.ZodTypeAny, {
|
|
1954
1943
|
text: string;
|
|
1955
1944
|
intent: string;
|
|
1956
|
-
}
|
|
1957
|
-
tests?: {
|
|
1945
|
+
}, {
|
|
1958
1946
|
text: string;
|
|
1959
|
-
|
|
1947
|
+
intent: string;
|
|
1948
|
+
}>, "many">>;
|
|
1949
|
+
tests: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1950
|
+
text: z.ZodString;
|
|
1951
|
+
expected: z.ZodObject<{
|
|
1952
|
+
intent: z.ZodString;
|
|
1953
|
+
context: z.ZodAny;
|
|
1954
|
+
}, "strip", z.ZodTypeAny, {
|
|
1955
|
+
intent: string;
|
|
1956
|
+
context?: any;
|
|
1957
|
+
}, {
|
|
1958
|
+
intent: string;
|
|
1959
|
+
context?: any;
|
|
1960
|
+
}>;
|
|
1961
|
+
}, "strip", z.ZodTypeAny, {
|
|
1962
|
+
text: string;
|
|
1963
|
+
expected: {
|
|
1964
|
+
intent: string;
|
|
1965
|
+
context?: any;
|
|
1966
|
+
};
|
|
1967
|
+
}, {
|
|
1968
|
+
text: string;
|
|
1969
|
+
expected: {
|
|
1970
|
+
intent: string;
|
|
1971
|
+
context?: any;
|
|
1972
|
+
};
|
|
1973
|
+
}>, "many">>;
|
|
1974
|
+
}, "strict", z.ZodTypeAny, {
|
|
1975
|
+
id?: string | undefined;
|
|
1976
|
+
definitions?: {
|
|
1977
|
+
value: string;
|
|
1978
|
+
text: string[];
|
|
1979
|
+
utterance?: string | undefined;
|
|
1980
|
+
}[] | undefined;
|
|
1981
|
+
training?: {
|
|
1982
|
+
text: string;
|
|
1983
|
+
intent: string;
|
|
1984
|
+
}[] | undefined;
|
|
1985
|
+
tests?: {
|
|
1986
|
+
text: string;
|
|
1987
|
+
expected: {
|
|
1960
1988
|
intent: string;
|
|
1961
1989
|
context?: any;
|
|
1962
1990
|
};
|
|
1963
1991
|
}[] | undefined;
|
|
1992
|
+
}, {
|
|
1993
|
+
id?: string | undefined;
|
|
1964
1994
|
definitions?: {
|
|
1965
1995
|
value: string;
|
|
1966
1996
|
text: string[];
|
|
1967
1997
|
utterance?: string | undefined;
|
|
1968
1998
|
}[] | undefined;
|
|
1999
|
+
training?: {
|
|
2000
|
+
text: string;
|
|
2001
|
+
intent: string;
|
|
2002
|
+
}[] | undefined;
|
|
2003
|
+
tests?: {
|
|
2004
|
+
text: string;
|
|
2005
|
+
expected: {
|
|
2006
|
+
intent: string;
|
|
2007
|
+
context?: any;
|
|
2008
|
+
};
|
|
2009
|
+
}[] | undefined;
|
|
1969
2010
|
}>, {
|
|
1970
|
-
entity: string;
|
|
1971
|
-
entities: string[];
|
|
1972
|
-
api: {
|
|
1973
|
-
GET?: boolean | undefined;
|
|
1974
|
-
UPDATE?: boolean | undefined;
|
|
1975
|
-
QUERY?: boolean | undefined;
|
|
1976
|
-
PUT?: boolean | undefined;
|
|
1977
|
-
PATCH?: boolean | undefined;
|
|
1978
|
-
DELETE?: boolean | undefined;
|
|
1979
|
-
} | null;
|
|
1980
2011
|
id?: string | undefined;
|
|
2012
|
+
definitions?: {
|
|
2013
|
+
value: string;
|
|
2014
|
+
text: string[];
|
|
2015
|
+
utterance?: string | undefined;
|
|
2016
|
+
}[] | undefined;
|
|
2017
|
+
training?: {
|
|
2018
|
+
text: string;
|
|
2019
|
+
intent: string;
|
|
2020
|
+
}[] | undefined;
|
|
2021
|
+
tests?: {
|
|
2022
|
+
text: string;
|
|
2023
|
+
expected: {
|
|
2024
|
+
intent: string;
|
|
2025
|
+
context?: any;
|
|
2026
|
+
};
|
|
2027
|
+
}[] | undefined;
|
|
2028
|
+
}, {
|
|
2029
|
+
id?: string | undefined;
|
|
2030
|
+
definitions?: {
|
|
2031
|
+
value: string;
|
|
2032
|
+
text: string[];
|
|
2033
|
+
utterance?: string | undefined;
|
|
2034
|
+
}[] | undefined;
|
|
1981
2035
|
training?: {
|
|
1982
2036
|
text: string;
|
|
1983
2037
|
intent: string;
|
|
@@ -1989,23 +2043,101 @@ declare module '@scout9/app/types' {
|
|
|
1989
2043
|
context?: any;
|
|
1990
2044
|
};
|
|
1991
2045
|
}[] | undefined;
|
|
2046
|
+
}>;
|
|
2047
|
+
|
|
2048
|
+
export const entitiesRootConfigurationSchema: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
2049
|
+
id: z.ZodOptional<z.ZodString>;
|
|
2050
|
+
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2051
|
+
utterance: z.ZodOptional<z.ZodString>;
|
|
2052
|
+
value: z.ZodString;
|
|
2053
|
+
text: z.ZodArray<z.ZodString, "many">;
|
|
2054
|
+
}, "strip", z.ZodTypeAny, {
|
|
2055
|
+
value: string;
|
|
2056
|
+
text: string[];
|
|
2057
|
+
utterance?: string | undefined;
|
|
2058
|
+
}, {
|
|
2059
|
+
value: string;
|
|
2060
|
+
text: string[];
|
|
2061
|
+
utterance?: string | undefined;
|
|
2062
|
+
}>, "many">>;
|
|
2063
|
+
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2064
|
+
intent: z.ZodString;
|
|
2065
|
+
text: z.ZodString;
|
|
2066
|
+
}, "strip", z.ZodTypeAny, {
|
|
2067
|
+
text: string;
|
|
2068
|
+
intent: string;
|
|
2069
|
+
}, {
|
|
2070
|
+
text: string;
|
|
2071
|
+
intent: string;
|
|
2072
|
+
}>, "many">>;
|
|
2073
|
+
tests: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2074
|
+
text: z.ZodString;
|
|
2075
|
+
expected: z.ZodObject<{
|
|
2076
|
+
intent: z.ZodString;
|
|
2077
|
+
context: z.ZodAny;
|
|
2078
|
+
}, "strip", z.ZodTypeAny, {
|
|
2079
|
+
intent: string;
|
|
2080
|
+
context?: any;
|
|
2081
|
+
}, {
|
|
2082
|
+
intent: string;
|
|
2083
|
+
context?: any;
|
|
2084
|
+
}>;
|
|
2085
|
+
}, "strip", z.ZodTypeAny, {
|
|
2086
|
+
text: string;
|
|
2087
|
+
expected: {
|
|
2088
|
+
intent: string;
|
|
2089
|
+
context?: any;
|
|
2090
|
+
};
|
|
2091
|
+
}, {
|
|
2092
|
+
text: string;
|
|
2093
|
+
expected: {
|
|
2094
|
+
intent: string;
|
|
2095
|
+
context?: any;
|
|
2096
|
+
};
|
|
2097
|
+
}>, "many">>;
|
|
2098
|
+
}, "strict", z.ZodTypeAny, {
|
|
2099
|
+
id?: string | undefined;
|
|
1992
2100
|
definitions?: {
|
|
1993
2101
|
value: string;
|
|
1994
2102
|
text: string[];
|
|
1995
2103
|
utterance?: string | undefined;
|
|
1996
2104
|
}[] | undefined;
|
|
2105
|
+
training?: {
|
|
2106
|
+
text: string;
|
|
2107
|
+
intent: string;
|
|
2108
|
+
}[] | undefined;
|
|
2109
|
+
tests?: {
|
|
2110
|
+
text: string;
|
|
2111
|
+
expected: {
|
|
2112
|
+
intent: string;
|
|
2113
|
+
context?: any;
|
|
2114
|
+
};
|
|
2115
|
+
}[] | undefined;
|
|
1997
2116
|
}, {
|
|
1998
|
-
entity: string;
|
|
1999
|
-
entities: string[];
|
|
2000
|
-
api: {
|
|
2001
|
-
GET?: boolean | undefined;
|
|
2002
|
-
UPDATE?: boolean | undefined;
|
|
2003
|
-
QUERY?: boolean | undefined;
|
|
2004
|
-
PUT?: boolean | undefined;
|
|
2005
|
-
PATCH?: boolean | undefined;
|
|
2006
|
-
DELETE?: boolean | undefined;
|
|
2007
|
-
} | null;
|
|
2008
2117
|
id?: string | undefined;
|
|
2118
|
+
definitions?: {
|
|
2119
|
+
value: string;
|
|
2120
|
+
text: string[];
|
|
2121
|
+
utterance?: string | undefined;
|
|
2122
|
+
}[] | undefined;
|
|
2123
|
+
training?: {
|
|
2124
|
+
text: string;
|
|
2125
|
+
intent: string;
|
|
2126
|
+
}[] | undefined;
|
|
2127
|
+
tests?: {
|
|
2128
|
+
text: string;
|
|
2129
|
+
expected: {
|
|
2130
|
+
intent: string;
|
|
2131
|
+
context?: any;
|
|
2132
|
+
};
|
|
2133
|
+
}[] | undefined;
|
|
2134
|
+
}>, {
|
|
2135
|
+
id?: string | undefined;
|
|
2136
|
+
definitions?: {
|
|
2137
|
+
value: string;
|
|
2138
|
+
text: string[];
|
|
2139
|
+
utterance?: string | undefined;
|
|
2140
|
+
}[] | undefined;
|
|
2009
2141
|
training?: {
|
|
2010
2142
|
text: string;
|
|
2011
2143
|
intent: string;
|
|
@@ -2017,13 +2149,30 @@ declare module '@scout9/app/types' {
|
|
|
2017
2149
|
context?: any;
|
|
2018
2150
|
};
|
|
2019
2151
|
}[] | undefined;
|
|
2152
|
+
}, {
|
|
2153
|
+
id?: string | undefined;
|
|
2020
2154
|
definitions?: {
|
|
2021
2155
|
value: string;
|
|
2022
2156
|
text: string[];
|
|
2023
2157
|
utterance?: string | undefined;
|
|
2024
2158
|
}[] | undefined;
|
|
2025
|
-
|
|
2026
|
-
|
|
2159
|
+
training?: {
|
|
2160
|
+
text: string;
|
|
2161
|
+
intent: string;
|
|
2162
|
+
}[] | undefined;
|
|
2163
|
+
tests?: {
|
|
2164
|
+
text: string;
|
|
2165
|
+
expected: {
|
|
2166
|
+
intent: string;
|
|
2167
|
+
context?: any;
|
|
2168
|
+
};
|
|
2169
|
+
}[] | undefined;
|
|
2170
|
+
}>, "many">;
|
|
2171
|
+
/**
|
|
2172
|
+
* @TODO why type extend not valid?
|
|
2173
|
+
*
|
|
2174
|
+
*/
|
|
2175
|
+
export const entityRootProjectConfigurationSchema: z.ZodEffects<z.ZodObject<{
|
|
2027
2176
|
id: z.ZodOptional<z.ZodString>;
|
|
2028
2177
|
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2029
2178
|
intent: z.ZodString;
|
|
@@ -2065,250 +2214,1326 @@ declare module '@scout9/app/types' {
|
|
|
2065
2214
|
value: z.ZodString;
|
|
2066
2215
|
text: z.ZodArray<z.ZodString, "many">;
|
|
2067
2216
|
}, "strip", z.ZodTypeAny, {
|
|
2068
|
-
value: string;
|
|
2069
|
-
text: string[];
|
|
2070
|
-
utterance?: string | undefined;
|
|
2217
|
+
value: string;
|
|
2218
|
+
text: string[];
|
|
2219
|
+
utterance?: string | undefined;
|
|
2220
|
+
}, {
|
|
2221
|
+
value: string;
|
|
2222
|
+
text: string[];
|
|
2223
|
+
utterance?: string | undefined;
|
|
2224
|
+
}>, "many">>;
|
|
2225
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
2226
|
+
entity: z.ZodString;
|
|
2227
|
+
api: z.ZodNullable<z.ZodObject<{
|
|
2228
|
+
GET: z.ZodOptional<z.ZodBoolean>;
|
|
2229
|
+
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
2230
|
+
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
2231
|
+
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
2232
|
+
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
2233
|
+
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
2234
|
+
}, "strip", z.ZodTypeAny, {
|
|
2235
|
+
GET?: boolean | undefined;
|
|
2236
|
+
UPDATE?: boolean | undefined;
|
|
2237
|
+
QUERY?: boolean | undefined;
|
|
2238
|
+
PUT?: boolean | undefined;
|
|
2239
|
+
PATCH?: boolean | undefined;
|
|
2240
|
+
DELETE?: boolean | undefined;
|
|
2241
|
+
}, {
|
|
2242
|
+
GET?: boolean | undefined;
|
|
2243
|
+
UPDATE?: boolean | undefined;
|
|
2244
|
+
QUERY?: boolean | undefined;
|
|
2245
|
+
PUT?: boolean | undefined;
|
|
2246
|
+
PATCH?: boolean | undefined;
|
|
2247
|
+
DELETE?: boolean | undefined;
|
|
2248
|
+
}>>;
|
|
2249
|
+
}, "strict", z.ZodTypeAny, {
|
|
2250
|
+
entity: string;
|
|
2251
|
+
entities: string[];
|
|
2252
|
+
api: {
|
|
2253
|
+
GET?: boolean | undefined;
|
|
2254
|
+
UPDATE?: boolean | undefined;
|
|
2255
|
+
QUERY?: boolean | undefined;
|
|
2256
|
+
PUT?: boolean | undefined;
|
|
2257
|
+
PATCH?: boolean | undefined;
|
|
2258
|
+
DELETE?: boolean | undefined;
|
|
2259
|
+
} | null;
|
|
2260
|
+
id?: string | undefined;
|
|
2261
|
+
training?: {
|
|
2262
|
+
text: string;
|
|
2263
|
+
intent: string;
|
|
2264
|
+
}[] | undefined;
|
|
2265
|
+
tests?: {
|
|
2266
|
+
text: string;
|
|
2267
|
+
expected: {
|
|
2268
|
+
intent: string;
|
|
2269
|
+
context?: any;
|
|
2270
|
+
};
|
|
2271
|
+
}[] | undefined;
|
|
2272
|
+
definitions?: {
|
|
2273
|
+
value: string;
|
|
2274
|
+
text: string[];
|
|
2275
|
+
utterance?: string | undefined;
|
|
2276
|
+
}[] | undefined;
|
|
2277
|
+
}, {
|
|
2278
|
+
entity: string;
|
|
2279
|
+
entities: string[];
|
|
2280
|
+
api: {
|
|
2281
|
+
GET?: boolean | undefined;
|
|
2282
|
+
UPDATE?: boolean | undefined;
|
|
2283
|
+
QUERY?: boolean | undefined;
|
|
2284
|
+
PUT?: boolean | undefined;
|
|
2285
|
+
PATCH?: boolean | undefined;
|
|
2286
|
+
DELETE?: boolean | undefined;
|
|
2287
|
+
} | null;
|
|
2288
|
+
id?: string | undefined;
|
|
2289
|
+
training?: {
|
|
2290
|
+
text: string;
|
|
2291
|
+
intent: string;
|
|
2292
|
+
}[] | undefined;
|
|
2293
|
+
tests?: {
|
|
2294
|
+
text: string;
|
|
2295
|
+
expected: {
|
|
2296
|
+
intent: string;
|
|
2297
|
+
context?: any;
|
|
2298
|
+
};
|
|
2299
|
+
}[] | undefined;
|
|
2300
|
+
definitions?: {
|
|
2301
|
+
value: string;
|
|
2302
|
+
text: string[];
|
|
2303
|
+
utterance?: string | undefined;
|
|
2304
|
+
}[] | undefined;
|
|
2305
|
+
}>, {
|
|
2306
|
+
entity: string;
|
|
2307
|
+
entities: string[];
|
|
2308
|
+
api: {
|
|
2309
|
+
GET?: boolean | undefined;
|
|
2310
|
+
UPDATE?: boolean | undefined;
|
|
2311
|
+
QUERY?: boolean | undefined;
|
|
2312
|
+
PUT?: boolean | undefined;
|
|
2313
|
+
PATCH?: boolean | undefined;
|
|
2314
|
+
DELETE?: boolean | undefined;
|
|
2315
|
+
} | null;
|
|
2316
|
+
id?: string | undefined;
|
|
2317
|
+
training?: {
|
|
2318
|
+
text: string;
|
|
2319
|
+
intent: string;
|
|
2320
|
+
}[] | undefined;
|
|
2321
|
+
tests?: {
|
|
2322
|
+
text: string;
|
|
2323
|
+
expected: {
|
|
2324
|
+
intent: string;
|
|
2325
|
+
context?: any;
|
|
2326
|
+
};
|
|
2327
|
+
}[] | undefined;
|
|
2328
|
+
definitions?: {
|
|
2329
|
+
value: string;
|
|
2330
|
+
text: string[];
|
|
2331
|
+
utterance?: string | undefined;
|
|
2332
|
+
}[] | undefined;
|
|
2333
|
+
}, {
|
|
2334
|
+
entity: string;
|
|
2335
|
+
entities: string[];
|
|
2336
|
+
api: {
|
|
2337
|
+
GET?: boolean | undefined;
|
|
2338
|
+
UPDATE?: boolean | undefined;
|
|
2339
|
+
QUERY?: boolean | undefined;
|
|
2340
|
+
PUT?: boolean | undefined;
|
|
2341
|
+
PATCH?: boolean | undefined;
|
|
2342
|
+
DELETE?: boolean | undefined;
|
|
2343
|
+
} | null;
|
|
2344
|
+
id?: string | undefined;
|
|
2345
|
+
training?: {
|
|
2346
|
+
text: string;
|
|
2347
|
+
intent: string;
|
|
2348
|
+
}[] | undefined;
|
|
2349
|
+
tests?: {
|
|
2350
|
+
text: string;
|
|
2351
|
+
expected: {
|
|
2352
|
+
intent: string;
|
|
2353
|
+
context?: any;
|
|
2354
|
+
};
|
|
2355
|
+
}[] | undefined;
|
|
2356
|
+
definitions?: {
|
|
2357
|
+
value: string;
|
|
2358
|
+
text: string[];
|
|
2359
|
+
utterance?: string | undefined;
|
|
2360
|
+
}[] | undefined;
|
|
2361
|
+
}>;
|
|
2362
|
+
|
|
2363
|
+
export const entitiesRootProjectConfigurationSchema: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
2364
|
+
id: z.ZodOptional<z.ZodString>;
|
|
2365
|
+
training: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2366
|
+
intent: z.ZodString;
|
|
2367
|
+
text: z.ZodString;
|
|
2368
|
+
}, "strip", z.ZodTypeAny, {
|
|
2369
|
+
text: string;
|
|
2370
|
+
intent: string;
|
|
2371
|
+
}, {
|
|
2372
|
+
text: string;
|
|
2373
|
+
intent: string;
|
|
2374
|
+
}>, "many">>;
|
|
2375
|
+
tests: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2376
|
+
text: z.ZodString;
|
|
2377
|
+
expected: z.ZodObject<{
|
|
2378
|
+
intent: z.ZodString;
|
|
2379
|
+
context: z.ZodAny;
|
|
2380
|
+
}, "strip", z.ZodTypeAny, {
|
|
2381
|
+
intent: string;
|
|
2382
|
+
context?: any;
|
|
2383
|
+
}, {
|
|
2384
|
+
intent: string;
|
|
2385
|
+
context?: any;
|
|
2386
|
+
}>;
|
|
2387
|
+
}, "strip", z.ZodTypeAny, {
|
|
2388
|
+
text: string;
|
|
2389
|
+
expected: {
|
|
2390
|
+
intent: string;
|
|
2391
|
+
context?: any;
|
|
2392
|
+
};
|
|
2393
|
+
}, {
|
|
2394
|
+
text: string;
|
|
2395
|
+
expected: {
|
|
2396
|
+
intent: string;
|
|
2397
|
+
context?: any;
|
|
2398
|
+
};
|
|
2399
|
+
}>, "many">>;
|
|
2400
|
+
definitions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2401
|
+
utterance: z.ZodOptional<z.ZodString>;
|
|
2402
|
+
value: z.ZodString;
|
|
2403
|
+
text: z.ZodArray<z.ZodString, "many">;
|
|
2404
|
+
}, "strip", z.ZodTypeAny, {
|
|
2405
|
+
value: string;
|
|
2406
|
+
text: string[];
|
|
2407
|
+
utterance?: string | undefined;
|
|
2408
|
+
}, {
|
|
2409
|
+
value: string;
|
|
2410
|
+
text: string[];
|
|
2411
|
+
utterance?: string | undefined;
|
|
2412
|
+
}>, "many">>;
|
|
2413
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
2414
|
+
entity: z.ZodString;
|
|
2415
|
+
api: z.ZodNullable<z.ZodObject<{
|
|
2416
|
+
GET: z.ZodOptional<z.ZodBoolean>;
|
|
2417
|
+
UPDATE: z.ZodOptional<z.ZodBoolean>;
|
|
2418
|
+
QUERY: z.ZodOptional<z.ZodBoolean>;
|
|
2419
|
+
PUT: z.ZodOptional<z.ZodBoolean>;
|
|
2420
|
+
PATCH: z.ZodOptional<z.ZodBoolean>;
|
|
2421
|
+
DELETE: z.ZodOptional<z.ZodBoolean>;
|
|
2422
|
+
}, "strip", z.ZodTypeAny, {
|
|
2423
|
+
GET?: boolean | undefined;
|
|
2424
|
+
UPDATE?: boolean | undefined;
|
|
2425
|
+
QUERY?: boolean | undefined;
|
|
2426
|
+
PUT?: boolean | undefined;
|
|
2427
|
+
PATCH?: boolean | undefined;
|
|
2428
|
+
DELETE?: boolean | undefined;
|
|
2429
|
+
}, {
|
|
2430
|
+
GET?: boolean | undefined;
|
|
2431
|
+
UPDATE?: boolean | undefined;
|
|
2432
|
+
QUERY?: boolean | undefined;
|
|
2433
|
+
PUT?: boolean | undefined;
|
|
2434
|
+
PATCH?: boolean | undefined;
|
|
2435
|
+
DELETE?: boolean | undefined;
|
|
2436
|
+
}>>;
|
|
2437
|
+
}, "strict", z.ZodTypeAny, {
|
|
2438
|
+
entity: string;
|
|
2439
|
+
entities: string[];
|
|
2440
|
+
api: {
|
|
2441
|
+
GET?: boolean | undefined;
|
|
2442
|
+
UPDATE?: boolean | undefined;
|
|
2443
|
+
QUERY?: boolean | undefined;
|
|
2444
|
+
PUT?: boolean | undefined;
|
|
2445
|
+
PATCH?: boolean | undefined;
|
|
2446
|
+
DELETE?: boolean | undefined;
|
|
2447
|
+
} | null;
|
|
2448
|
+
id?: string | undefined;
|
|
2449
|
+
training?: {
|
|
2450
|
+
text: string;
|
|
2451
|
+
intent: string;
|
|
2452
|
+
}[] | undefined;
|
|
2453
|
+
tests?: {
|
|
2454
|
+
text: string;
|
|
2455
|
+
expected: {
|
|
2456
|
+
intent: string;
|
|
2457
|
+
context?: any;
|
|
2458
|
+
};
|
|
2459
|
+
}[] | undefined;
|
|
2460
|
+
definitions?: {
|
|
2461
|
+
value: string;
|
|
2462
|
+
text: string[];
|
|
2463
|
+
utterance?: string | undefined;
|
|
2464
|
+
}[] | undefined;
|
|
2465
|
+
}, {
|
|
2466
|
+
entity: string;
|
|
2467
|
+
entities: string[];
|
|
2468
|
+
api: {
|
|
2469
|
+
GET?: boolean | undefined;
|
|
2470
|
+
UPDATE?: boolean | undefined;
|
|
2471
|
+
QUERY?: boolean | undefined;
|
|
2472
|
+
PUT?: boolean | undefined;
|
|
2473
|
+
PATCH?: boolean | undefined;
|
|
2474
|
+
DELETE?: boolean | undefined;
|
|
2475
|
+
} | null;
|
|
2476
|
+
id?: string | undefined;
|
|
2477
|
+
training?: {
|
|
2478
|
+
text: string;
|
|
2479
|
+
intent: string;
|
|
2480
|
+
}[] | undefined;
|
|
2481
|
+
tests?: {
|
|
2482
|
+
text: string;
|
|
2483
|
+
expected: {
|
|
2484
|
+
intent: string;
|
|
2485
|
+
context?: any;
|
|
2486
|
+
};
|
|
2487
|
+
}[] | undefined;
|
|
2488
|
+
definitions?: {
|
|
2489
|
+
value: string;
|
|
2490
|
+
text: string[];
|
|
2491
|
+
utterance?: string | undefined;
|
|
2492
|
+
}[] | undefined;
|
|
2493
|
+
}>, {
|
|
2494
|
+
entity: string;
|
|
2495
|
+
entities: string[];
|
|
2496
|
+
api: {
|
|
2497
|
+
GET?: boolean | undefined;
|
|
2498
|
+
UPDATE?: boolean | undefined;
|
|
2499
|
+
QUERY?: boolean | undefined;
|
|
2500
|
+
PUT?: boolean | undefined;
|
|
2501
|
+
PATCH?: boolean | undefined;
|
|
2502
|
+
DELETE?: boolean | undefined;
|
|
2503
|
+
} | null;
|
|
2504
|
+
id?: string | undefined;
|
|
2505
|
+
training?: {
|
|
2506
|
+
text: string;
|
|
2507
|
+
intent: string;
|
|
2508
|
+
}[] | undefined;
|
|
2509
|
+
tests?: {
|
|
2510
|
+
text: string;
|
|
2511
|
+
expected: {
|
|
2512
|
+
intent: string;
|
|
2513
|
+
context?: any;
|
|
2514
|
+
};
|
|
2515
|
+
}[] | undefined;
|
|
2516
|
+
definitions?: {
|
|
2517
|
+
value: string;
|
|
2518
|
+
text: string[];
|
|
2519
|
+
utterance?: string | undefined;
|
|
2520
|
+
}[] | undefined;
|
|
2521
|
+
}, {
|
|
2522
|
+
entity: string;
|
|
2523
|
+
entities: string[];
|
|
2524
|
+
api: {
|
|
2525
|
+
GET?: boolean | undefined;
|
|
2526
|
+
UPDATE?: boolean | undefined;
|
|
2527
|
+
QUERY?: boolean | undefined;
|
|
2528
|
+
PUT?: boolean | undefined;
|
|
2529
|
+
PATCH?: boolean | undefined;
|
|
2530
|
+
DELETE?: boolean | undefined;
|
|
2531
|
+
} | null;
|
|
2532
|
+
id?: string | undefined;
|
|
2533
|
+
training?: {
|
|
2534
|
+
text: string;
|
|
2535
|
+
intent: string;
|
|
2536
|
+
}[] | undefined;
|
|
2537
|
+
tests?: {
|
|
2538
|
+
text: string;
|
|
2539
|
+
expected: {
|
|
2540
|
+
intent: string;
|
|
2541
|
+
context?: any;
|
|
2542
|
+
};
|
|
2543
|
+
}[] | undefined;
|
|
2544
|
+
definitions?: {
|
|
2545
|
+
value: string;
|
|
2546
|
+
text: string[];
|
|
2547
|
+
utterance?: string | undefined;
|
|
2548
|
+
}[] | undefined;
|
|
2549
|
+
}>, "many">;
|
|
2550
|
+
export type IEntityApiConfiguration = import('zod').infer<typeof entityApiConfigurationSchema>;
|
|
2551
|
+
export type IEntityConfiguration = import('zod').infer<typeof entityConfigurationSchema>;
|
|
2552
|
+
export type IEntitiesRootConfiguration = import('zod').infer<typeof entitiesRootConfigurationSchema>;
|
|
2553
|
+
export type IEntityRootProjectConfiguration = import('zod').infer<typeof entityRootProjectConfigurationSchema>;
|
|
2554
|
+
export type IEntitiesRootProjectConfiguration = import('zod').infer<typeof entitiesRootProjectConfigurationSchema>;
|
|
2555
|
+
export const MessageSchema: z.ZodObject<{
|
|
2556
|
+
id: z.ZodString;
|
|
2557
|
+
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
2558
|
+
content: z.ZodString;
|
|
2559
|
+
time: z.ZodString;
|
|
2560
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2561
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
2562
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
2563
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2564
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2565
|
+
}, "strip", z.ZodTypeAny, {
|
|
2566
|
+
time: string;
|
|
2567
|
+
id: string;
|
|
2568
|
+
content: string;
|
|
2569
|
+
role: "agent" | "customer" | "system";
|
|
2570
|
+
name?: string | undefined;
|
|
2571
|
+
scheduled?: string | undefined;
|
|
2572
|
+
context?: any;
|
|
2573
|
+
intent?: string | null | undefined;
|
|
2574
|
+
intentScore?: number | null | undefined;
|
|
2575
|
+
}, {
|
|
2576
|
+
time: string;
|
|
2577
|
+
id: string;
|
|
2578
|
+
content: string;
|
|
2579
|
+
role: "agent" | "customer" | "system";
|
|
2580
|
+
name?: string | undefined;
|
|
2581
|
+
scheduled?: string | undefined;
|
|
2582
|
+
context?: any;
|
|
2583
|
+
intent?: string | null | undefined;
|
|
2584
|
+
intentScore?: number | null | undefined;
|
|
2585
|
+
}>;
|
|
2586
|
+
export type IMessage = import('zod').infer<typeof MessageSchema>;
|
|
2587
|
+
export const WorkflowConfigurationSchema: z.ZodObject<{
|
|
2588
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
2589
|
+
entity: z.ZodString;
|
|
2590
|
+
}, "strip", z.ZodTypeAny, {
|
|
2591
|
+
entity: string;
|
|
2592
|
+
entities: string[];
|
|
2593
|
+
}, {
|
|
2594
|
+
entity: string;
|
|
2595
|
+
entities: string[];
|
|
2596
|
+
}>;
|
|
2597
|
+
|
|
2598
|
+
export const WorkflowsConfigurationSchema: z.ZodArray<z.ZodObject<{
|
|
2599
|
+
entities: z.ZodArray<z.ZodString, "many">;
|
|
2600
|
+
entity: z.ZodString;
|
|
2601
|
+
}, "strip", z.ZodTypeAny, {
|
|
2602
|
+
entity: string;
|
|
2603
|
+
entities: string[];
|
|
2604
|
+
}, {
|
|
2605
|
+
entity: string;
|
|
2606
|
+
entities: string[];
|
|
2607
|
+
}>, "many">;
|
|
2608
|
+
|
|
2609
|
+
export const ConversationSchema: z.ZodObject<{
|
|
2610
|
+
$agent: z.ZodString;
|
|
2611
|
+
$customer: z.ZodString;
|
|
2612
|
+
initialContexts: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2613
|
+
environment: z.ZodEnum<["phone", "email", "web"]>;
|
|
2614
|
+
environmentProps: z.ZodOptional<z.ZodObject<{
|
|
2615
|
+
subject: z.ZodOptional<z.ZodString>;
|
|
2616
|
+
platformEmailThreadId: z.ZodOptional<z.ZodString>;
|
|
2617
|
+
}, "strip", z.ZodTypeAny, {
|
|
2618
|
+
subject?: string | undefined;
|
|
2619
|
+
platformEmailThreadId?: string | undefined;
|
|
2620
|
+
}, {
|
|
2621
|
+
subject?: string | undefined;
|
|
2622
|
+
platformEmailThreadId?: string | undefined;
|
|
2623
|
+
}>>;
|
|
2624
|
+
locked: z.ZodNullable<z.ZodOptional<z.ZodBoolean>>;
|
|
2625
|
+
lockedReason: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2626
|
+
lockAttempts: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
2627
|
+
forwardedTo: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2628
|
+
forwarded: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2629
|
+
forwardNote: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2630
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2631
|
+
intentScore: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
2632
|
+
}, "strip", z.ZodTypeAny, {
|
|
2633
|
+
environment: "email" | "phone" | "web";
|
|
2634
|
+
$agent: string;
|
|
2635
|
+
$customer: string;
|
|
2636
|
+
initialContexts?: string[] | undefined;
|
|
2637
|
+
environmentProps?: {
|
|
2638
|
+
subject?: string | undefined;
|
|
2639
|
+
platformEmailThreadId?: string | undefined;
|
|
2640
|
+
} | undefined;
|
|
2641
|
+
locked?: boolean | null | undefined;
|
|
2642
|
+
lockedReason?: string | null | undefined;
|
|
2643
|
+
lockAttempts?: number | null | undefined;
|
|
2644
|
+
forwardedTo?: string | null | undefined;
|
|
2645
|
+
forwarded?: string | null | undefined;
|
|
2646
|
+
forwardNote?: string | null | undefined;
|
|
2647
|
+
intent?: string | null | undefined;
|
|
2648
|
+
intentScore?: number | null | undefined;
|
|
2649
|
+
}, {
|
|
2650
|
+
environment: "email" | "phone" | "web";
|
|
2651
|
+
$agent: string;
|
|
2652
|
+
$customer: string;
|
|
2653
|
+
initialContexts?: string[] | undefined;
|
|
2654
|
+
environmentProps?: {
|
|
2655
|
+
subject?: string | undefined;
|
|
2656
|
+
platformEmailThreadId?: string | undefined;
|
|
2657
|
+
} | undefined;
|
|
2658
|
+
locked?: boolean | null | undefined;
|
|
2659
|
+
lockedReason?: string | null | undefined;
|
|
2660
|
+
lockAttempts?: number | null | undefined;
|
|
2661
|
+
forwardedTo?: string | null | undefined;
|
|
2662
|
+
forwarded?: string | null | undefined;
|
|
2663
|
+
forwardNote?: string | null | undefined;
|
|
2664
|
+
intent?: string | null | undefined;
|
|
2665
|
+
intentScore?: number | null | undefined;
|
|
2666
|
+
}>;
|
|
2667
|
+
|
|
2668
|
+
export const IntentWorkflowEventSchema: z.ZodObject<{
|
|
2669
|
+
current: z.ZodNullable<z.ZodString>;
|
|
2670
|
+
flow: z.ZodArray<z.ZodString, "many">;
|
|
2671
|
+
initial: z.ZodNullable<z.ZodString>;
|
|
2672
|
+
}, "strip", z.ZodTypeAny, {
|
|
2673
|
+
current: string | null;
|
|
2674
|
+
flow: string[];
|
|
2675
|
+
initial: string | null;
|
|
2676
|
+
}, {
|
|
2677
|
+
current: string | null;
|
|
2678
|
+
flow: string[];
|
|
2679
|
+
initial: string | null;
|
|
2680
|
+
}>;
|
|
2681
|
+
|
|
2682
|
+
export const WorkflowEventSchema: z.ZodObject<{
|
|
2683
|
+
messages: z.ZodArray<z.ZodObject<{
|
|
2684
|
+
id: z.ZodString;
|
|
2685
|
+
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
2686
|
+
content: z.ZodString;
|
|
2687
|
+
time: z.ZodString;
|
|
2688
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2689
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
2690
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
2691
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2692
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2693
|
+
}, "strip", z.ZodTypeAny, {
|
|
2694
|
+
time: string;
|
|
2695
|
+
id: string;
|
|
2696
|
+
content: string;
|
|
2697
|
+
role: "agent" | "customer" | "system";
|
|
2698
|
+
name?: string | undefined;
|
|
2699
|
+
scheduled?: string | undefined;
|
|
2700
|
+
context?: any;
|
|
2701
|
+
intent?: string | null | undefined;
|
|
2702
|
+
intentScore?: number | null | undefined;
|
|
2703
|
+
}, {
|
|
2704
|
+
time: string;
|
|
2705
|
+
id: string;
|
|
2706
|
+
content: string;
|
|
2707
|
+
role: "agent" | "customer" | "system";
|
|
2708
|
+
name?: string | undefined;
|
|
2709
|
+
scheduled?: string | undefined;
|
|
2710
|
+
context?: any;
|
|
2711
|
+
intent?: string | null | undefined;
|
|
2712
|
+
intentScore?: number | null | undefined;
|
|
2713
|
+
}>, "many">;
|
|
2714
|
+
conversation: z.ZodObject<{
|
|
2715
|
+
$agent: z.ZodString;
|
|
2716
|
+
$customer: z.ZodString;
|
|
2717
|
+
initialContexts: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2718
|
+
environment: z.ZodEnum<["phone", "email", "web"]>;
|
|
2719
|
+
environmentProps: z.ZodOptional<z.ZodObject<{
|
|
2720
|
+
subject: z.ZodOptional<z.ZodString>;
|
|
2721
|
+
platformEmailThreadId: z.ZodOptional<z.ZodString>;
|
|
2722
|
+
}, "strip", z.ZodTypeAny, {
|
|
2723
|
+
subject?: string | undefined;
|
|
2724
|
+
platformEmailThreadId?: string | undefined;
|
|
2725
|
+
}, {
|
|
2726
|
+
subject?: string | undefined;
|
|
2727
|
+
platformEmailThreadId?: string | undefined;
|
|
2728
|
+
}>>;
|
|
2729
|
+
locked: z.ZodNullable<z.ZodOptional<z.ZodBoolean>>;
|
|
2730
|
+
lockedReason: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2731
|
+
lockAttempts: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
2732
|
+
forwardedTo: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2733
|
+
forwarded: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2734
|
+
forwardNote: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2735
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2736
|
+
intentScore: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
2737
|
+
}, "strip", z.ZodTypeAny, {
|
|
2738
|
+
environment: "email" | "phone" | "web";
|
|
2739
|
+
$agent: string;
|
|
2740
|
+
$customer: string;
|
|
2741
|
+
initialContexts?: string[] | undefined;
|
|
2742
|
+
environmentProps?: {
|
|
2743
|
+
subject?: string | undefined;
|
|
2744
|
+
platformEmailThreadId?: string | undefined;
|
|
2745
|
+
} | undefined;
|
|
2746
|
+
locked?: boolean | null | undefined;
|
|
2747
|
+
lockedReason?: string | null | undefined;
|
|
2748
|
+
lockAttempts?: number | null | undefined;
|
|
2749
|
+
forwardedTo?: string | null | undefined;
|
|
2750
|
+
forwarded?: string | null | undefined;
|
|
2751
|
+
forwardNote?: string | null | undefined;
|
|
2752
|
+
intent?: string | null | undefined;
|
|
2753
|
+
intentScore?: number | null | undefined;
|
|
2754
|
+
}, {
|
|
2755
|
+
environment: "email" | "phone" | "web";
|
|
2756
|
+
$agent: string;
|
|
2757
|
+
$customer: string;
|
|
2758
|
+
initialContexts?: string[] | undefined;
|
|
2759
|
+
environmentProps?: {
|
|
2760
|
+
subject?: string | undefined;
|
|
2761
|
+
platformEmailThreadId?: string | undefined;
|
|
2762
|
+
} | undefined;
|
|
2763
|
+
locked?: boolean | null | undefined;
|
|
2764
|
+
lockedReason?: string | null | undefined;
|
|
2765
|
+
lockAttempts?: number | null | undefined;
|
|
2766
|
+
forwardedTo?: string | null | undefined;
|
|
2767
|
+
forwarded?: string | null | undefined;
|
|
2768
|
+
forwardNote?: string | null | undefined;
|
|
2769
|
+
intent?: string | null | undefined;
|
|
2770
|
+
intentScore?: number | null | undefined;
|
|
2771
|
+
}>;
|
|
2772
|
+
context: z.ZodAny;
|
|
2773
|
+
message: z.ZodObject<{
|
|
2774
|
+
id: z.ZodString;
|
|
2775
|
+
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
2776
|
+
content: z.ZodString;
|
|
2777
|
+
time: z.ZodString;
|
|
2778
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2779
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
2780
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
2781
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2782
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2783
|
+
}, "strip", z.ZodTypeAny, {
|
|
2784
|
+
time: string;
|
|
2785
|
+
id: string;
|
|
2786
|
+
content: string;
|
|
2787
|
+
role: "agent" | "customer" | "system";
|
|
2788
|
+
name?: string | undefined;
|
|
2789
|
+
scheduled?: string | undefined;
|
|
2790
|
+
context?: any;
|
|
2791
|
+
intent?: string | null | undefined;
|
|
2792
|
+
intentScore?: number | null | undefined;
|
|
2793
|
+
}, {
|
|
2794
|
+
time: string;
|
|
2795
|
+
id: string;
|
|
2796
|
+
content: string;
|
|
2797
|
+
role: "agent" | "customer" | "system";
|
|
2798
|
+
name?: string | undefined;
|
|
2799
|
+
scheduled?: string | undefined;
|
|
2800
|
+
context?: any;
|
|
2801
|
+
intent?: string | null | undefined;
|
|
2802
|
+
intentScore?: number | null | undefined;
|
|
2803
|
+
}>;
|
|
2804
|
+
agent: z.ZodObject<Omit<{
|
|
2805
|
+
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
2806
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2807
|
+
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
2808
|
+
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
2809
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
2810
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
2811
|
+
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
2812
|
+
id: z.ZodString;
|
|
2813
|
+
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
2814
|
+
content: z.ZodString;
|
|
2815
|
+
time: z.ZodString;
|
|
2816
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2817
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
2818
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
2819
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
2820
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2821
|
+
}, "strip", z.ZodTypeAny, {
|
|
2822
|
+
time: string;
|
|
2823
|
+
id: string;
|
|
2824
|
+
content: string;
|
|
2825
|
+
role: "agent" | "customer" | "system";
|
|
2826
|
+
name?: string | undefined;
|
|
2827
|
+
scheduled?: string | undefined;
|
|
2828
|
+
context?: any;
|
|
2829
|
+
intent?: string | null | undefined;
|
|
2830
|
+
intentScore?: number | null | undefined;
|
|
2831
|
+
}, {
|
|
2832
|
+
time: string;
|
|
2833
|
+
id: string;
|
|
2834
|
+
content: string;
|
|
2835
|
+
role: "agent" | "customer" | "system";
|
|
2836
|
+
name?: string | undefined;
|
|
2837
|
+
scheduled?: string | undefined;
|
|
2838
|
+
context?: any;
|
|
2839
|
+
intent?: string | null | undefined;
|
|
2840
|
+
intentScore?: number | null | undefined;
|
|
2841
|
+
}>, "many">, "many">>;
|
|
2842
|
+
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
2843
|
+
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2844
|
+
excludedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2845
|
+
model: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Scout9", "bard", "openai"]>>>;
|
|
2846
|
+
deployed: z.ZodOptional<z.ZodObject<{
|
|
2847
|
+
web: z.ZodOptional<z.ZodString>;
|
|
2848
|
+
phone: z.ZodOptional<z.ZodString>;
|
|
2849
|
+
email: z.ZodOptional<z.ZodString>;
|
|
2850
|
+
}, "strip", z.ZodTypeAny, {
|
|
2851
|
+
web?: string | undefined;
|
|
2852
|
+
phone?: string | undefined;
|
|
2853
|
+
email?: string | undefined;
|
|
2854
|
+
}, {
|
|
2855
|
+
web?: string | undefined;
|
|
2856
|
+
phone?: string | undefined;
|
|
2857
|
+
email?: string | undefined;
|
|
2858
|
+
}>>;
|
|
2859
|
+
programmablePhoneNumber: z.ZodOptional<z.ZodString>;
|
|
2860
|
+
programmablePhoneNumberSid: z.ZodOptional<z.ZodString>;
|
|
2861
|
+
programmableEmail: z.ZodOptional<z.ZodString>;
|
|
2862
|
+
forwardEmail: z.ZodOptional<z.ZodString>;
|
|
2863
|
+
forwardPhone: z.ZodOptional<z.ZodString>;
|
|
2864
|
+
id: z.ZodString;
|
|
2865
|
+
}, "context" | "transcripts" | "audios" | "includedLocations" | "excludedLocations" | "model">, "strip", z.ZodTypeAny, {
|
|
2866
|
+
id: string;
|
|
2867
|
+
title: string;
|
|
2868
|
+
inactive?: boolean | undefined;
|
|
2869
|
+
img?: string | null | undefined;
|
|
2870
|
+
firstName?: string | undefined;
|
|
2871
|
+
lastName?: string | undefined;
|
|
2872
|
+
deployed?: {
|
|
2873
|
+
web?: string | undefined;
|
|
2874
|
+
phone?: string | undefined;
|
|
2875
|
+
email?: string | undefined;
|
|
2876
|
+
} | undefined;
|
|
2877
|
+
programmablePhoneNumber?: string | undefined;
|
|
2878
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
2879
|
+
programmableEmail?: string | undefined;
|
|
2880
|
+
forwardEmail?: string | undefined;
|
|
2881
|
+
forwardPhone?: string | undefined;
|
|
2882
|
+
}, {
|
|
2883
|
+
id: string;
|
|
2884
|
+
inactive?: boolean | undefined;
|
|
2885
|
+
img?: string | null | undefined;
|
|
2886
|
+
title?: string | undefined;
|
|
2887
|
+
firstName?: string | undefined;
|
|
2888
|
+
lastName?: string | undefined;
|
|
2889
|
+
deployed?: {
|
|
2890
|
+
web?: string | undefined;
|
|
2891
|
+
phone?: string | undefined;
|
|
2892
|
+
email?: string | undefined;
|
|
2893
|
+
} | undefined;
|
|
2894
|
+
programmablePhoneNumber?: string | undefined;
|
|
2895
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
2896
|
+
programmableEmail?: string | undefined;
|
|
2897
|
+
forwardEmail?: string | undefined;
|
|
2898
|
+
forwardPhone?: string | undefined;
|
|
2899
|
+
}>;
|
|
2900
|
+
customer: z.ZodObject<{
|
|
2901
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
2902
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
2903
|
+
name: z.ZodString;
|
|
2904
|
+
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2905
|
+
phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2906
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2907
|
+
neighborhood: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2908
|
+
city: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2909
|
+
country: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2910
|
+
line1: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2911
|
+
line2: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2912
|
+
postal_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2913
|
+
state: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2914
|
+
town: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2915
|
+
joined: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2916
|
+
stripe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2917
|
+
stripeDev: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2918
|
+
}, "strip", z.ZodUnion<[z.ZodBoolean, z.ZodNumber, z.ZodString]>, z.objectOutputType<{
|
|
2919
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
2920
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
2921
|
+
name: z.ZodString;
|
|
2922
|
+
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2923
|
+
phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2924
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2925
|
+
neighborhood: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2926
|
+
city: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2927
|
+
country: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2928
|
+
line1: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2929
|
+
line2: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2930
|
+
postal_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2931
|
+
state: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2932
|
+
town: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2933
|
+
joined: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2934
|
+
stripe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2935
|
+
stripeDev: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2936
|
+
}, z.ZodUnion<[z.ZodBoolean, z.ZodNumber, z.ZodString]>, "strip">, z.objectInputType<{
|
|
2937
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
2938
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
2939
|
+
name: z.ZodString;
|
|
2940
|
+
email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2941
|
+
phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2942
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2943
|
+
neighborhood: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2944
|
+
city: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2945
|
+
country: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2946
|
+
line1: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2947
|
+
line2: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2948
|
+
postal_code: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2949
|
+
state: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2950
|
+
town: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2951
|
+
joined: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2952
|
+
stripe: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2953
|
+
stripeDev: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2954
|
+
}, z.ZodUnion<[z.ZodBoolean, z.ZodNumber, z.ZodString]>, "strip">>;
|
|
2955
|
+
intent: z.ZodObject<{
|
|
2956
|
+
current: z.ZodNullable<z.ZodString>;
|
|
2957
|
+
flow: z.ZodArray<z.ZodString, "many">;
|
|
2958
|
+
initial: z.ZodNullable<z.ZodString>;
|
|
2959
|
+
}, "strip", z.ZodTypeAny, {
|
|
2960
|
+
current: string | null;
|
|
2961
|
+
flow: string[];
|
|
2962
|
+
initial: string | null;
|
|
2963
|
+
}, {
|
|
2964
|
+
current: string | null;
|
|
2965
|
+
flow: string[];
|
|
2966
|
+
initial: string | null;
|
|
2967
|
+
}>;
|
|
2968
|
+
stagnationCount: z.ZodNumber;
|
|
2969
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2970
|
+
}, "strip", z.ZodTypeAny, {
|
|
2971
|
+
message: {
|
|
2972
|
+
time: string;
|
|
2973
|
+
id: string;
|
|
2974
|
+
content: string;
|
|
2975
|
+
role: "agent" | "customer" | "system";
|
|
2976
|
+
name?: string | undefined;
|
|
2977
|
+
scheduled?: string | undefined;
|
|
2978
|
+
context?: any;
|
|
2979
|
+
intent?: string | null | undefined;
|
|
2980
|
+
intentScore?: number | null | undefined;
|
|
2981
|
+
};
|
|
2982
|
+
agent: {
|
|
2983
|
+
id: string;
|
|
2984
|
+
title: string;
|
|
2985
|
+
inactive?: boolean | undefined;
|
|
2986
|
+
img?: string | null | undefined;
|
|
2987
|
+
firstName?: string | undefined;
|
|
2988
|
+
lastName?: string | undefined;
|
|
2989
|
+
deployed?: {
|
|
2990
|
+
web?: string | undefined;
|
|
2991
|
+
phone?: string | undefined;
|
|
2992
|
+
email?: string | undefined;
|
|
2993
|
+
} | undefined;
|
|
2994
|
+
programmablePhoneNumber?: string | undefined;
|
|
2995
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
2996
|
+
programmableEmail?: string | undefined;
|
|
2997
|
+
forwardEmail?: string | undefined;
|
|
2998
|
+
forwardPhone?: string | undefined;
|
|
2999
|
+
};
|
|
3000
|
+
customer: {
|
|
3001
|
+
name: string;
|
|
3002
|
+
firstName?: string | undefined;
|
|
3003
|
+
lastName?: string | undefined;
|
|
3004
|
+
email?: string | null | undefined;
|
|
3005
|
+
phone?: string | null | undefined;
|
|
3006
|
+
img?: string | null | undefined;
|
|
3007
|
+
neighborhood?: string | null | undefined;
|
|
3008
|
+
city?: string | null | undefined;
|
|
3009
|
+
country?: string | null | undefined;
|
|
3010
|
+
line1?: string | null | undefined;
|
|
3011
|
+
line2?: string | null | undefined;
|
|
3012
|
+
postal_code?: string | null | undefined;
|
|
3013
|
+
state?: string | null | undefined;
|
|
3014
|
+
town?: string | null | undefined;
|
|
3015
|
+
joined?: string | null | undefined;
|
|
3016
|
+
stripe?: string | null | undefined;
|
|
3017
|
+
stripeDev?: string | null | undefined;
|
|
3018
|
+
} & {
|
|
3019
|
+
[k: string]: string | number | boolean;
|
|
3020
|
+
};
|
|
3021
|
+
intent: {
|
|
3022
|
+
current: string | null;
|
|
3023
|
+
flow: string[];
|
|
3024
|
+
initial: string | null;
|
|
3025
|
+
};
|
|
3026
|
+
conversation: {
|
|
3027
|
+
environment: "email" | "phone" | "web";
|
|
3028
|
+
$agent: string;
|
|
3029
|
+
$customer: string;
|
|
3030
|
+
initialContexts?: string[] | undefined;
|
|
3031
|
+
environmentProps?: {
|
|
3032
|
+
subject?: string | undefined;
|
|
3033
|
+
platformEmailThreadId?: string | undefined;
|
|
3034
|
+
} | undefined;
|
|
3035
|
+
locked?: boolean | null | undefined;
|
|
3036
|
+
lockedReason?: string | null | undefined;
|
|
3037
|
+
lockAttempts?: number | null | undefined;
|
|
3038
|
+
forwardedTo?: string | null | undefined;
|
|
3039
|
+
forwarded?: string | null | undefined;
|
|
3040
|
+
forwardNote?: string | null | undefined;
|
|
3041
|
+
intent?: string | null | undefined;
|
|
3042
|
+
intentScore?: number | null | undefined;
|
|
3043
|
+
};
|
|
3044
|
+
messages: {
|
|
3045
|
+
time: string;
|
|
3046
|
+
id: string;
|
|
3047
|
+
content: string;
|
|
3048
|
+
role: "agent" | "customer" | "system";
|
|
3049
|
+
name?: string | undefined;
|
|
3050
|
+
scheduled?: string | undefined;
|
|
3051
|
+
context?: any;
|
|
3052
|
+
intent?: string | null | undefined;
|
|
3053
|
+
intentScore?: number | null | undefined;
|
|
3054
|
+
}[];
|
|
3055
|
+
stagnationCount: number;
|
|
3056
|
+
context?: any;
|
|
3057
|
+
note?: string | undefined;
|
|
3058
|
+
}, {
|
|
3059
|
+
message: {
|
|
3060
|
+
time: string;
|
|
3061
|
+
id: string;
|
|
3062
|
+
content: string;
|
|
3063
|
+
role: "agent" | "customer" | "system";
|
|
3064
|
+
name?: string | undefined;
|
|
3065
|
+
scheduled?: string | undefined;
|
|
3066
|
+
context?: any;
|
|
3067
|
+
intent?: string | null | undefined;
|
|
3068
|
+
intentScore?: number | null | undefined;
|
|
3069
|
+
};
|
|
3070
|
+
agent: {
|
|
3071
|
+
id: string;
|
|
3072
|
+
inactive?: boolean | undefined;
|
|
3073
|
+
img?: string | null | undefined;
|
|
3074
|
+
title?: string | undefined;
|
|
3075
|
+
firstName?: string | undefined;
|
|
3076
|
+
lastName?: string | undefined;
|
|
3077
|
+
deployed?: {
|
|
3078
|
+
web?: string | undefined;
|
|
3079
|
+
phone?: string | undefined;
|
|
3080
|
+
email?: string | undefined;
|
|
3081
|
+
} | undefined;
|
|
3082
|
+
programmablePhoneNumber?: string | undefined;
|
|
3083
|
+
programmablePhoneNumberSid?: string | undefined;
|
|
3084
|
+
programmableEmail?: string | undefined;
|
|
3085
|
+
forwardEmail?: string | undefined;
|
|
3086
|
+
forwardPhone?: string | undefined;
|
|
3087
|
+
};
|
|
3088
|
+
customer: {
|
|
3089
|
+
name: string;
|
|
3090
|
+
firstName?: string | undefined;
|
|
3091
|
+
lastName?: string | undefined;
|
|
3092
|
+
email?: string | null | undefined;
|
|
3093
|
+
phone?: string | null | undefined;
|
|
3094
|
+
img?: string | null | undefined;
|
|
3095
|
+
neighborhood?: string | null | undefined;
|
|
3096
|
+
city?: string | null | undefined;
|
|
3097
|
+
country?: string | null | undefined;
|
|
3098
|
+
line1?: string | null | undefined;
|
|
3099
|
+
line2?: string | null | undefined;
|
|
3100
|
+
postal_code?: string | null | undefined;
|
|
3101
|
+
state?: string | null | undefined;
|
|
3102
|
+
town?: string | null | undefined;
|
|
3103
|
+
joined?: string | null | undefined;
|
|
3104
|
+
stripe?: string | null | undefined;
|
|
3105
|
+
stripeDev?: string | null | undefined;
|
|
3106
|
+
} & {
|
|
3107
|
+
[k: string]: string | number | boolean;
|
|
3108
|
+
};
|
|
3109
|
+
intent: {
|
|
3110
|
+
current: string | null;
|
|
3111
|
+
flow: string[];
|
|
3112
|
+
initial: string | null;
|
|
3113
|
+
};
|
|
3114
|
+
conversation: {
|
|
3115
|
+
environment: "email" | "phone" | "web";
|
|
3116
|
+
$agent: string;
|
|
3117
|
+
$customer: string;
|
|
3118
|
+
initialContexts?: string[] | undefined;
|
|
3119
|
+
environmentProps?: {
|
|
3120
|
+
subject?: string | undefined;
|
|
3121
|
+
platformEmailThreadId?: string | undefined;
|
|
3122
|
+
} | undefined;
|
|
3123
|
+
locked?: boolean | null | undefined;
|
|
3124
|
+
lockedReason?: string | null | undefined;
|
|
3125
|
+
lockAttempts?: number | null | undefined;
|
|
3126
|
+
forwardedTo?: string | null | undefined;
|
|
3127
|
+
forwarded?: string | null | undefined;
|
|
3128
|
+
forwardNote?: string | null | undefined;
|
|
3129
|
+
intent?: string | null | undefined;
|
|
3130
|
+
intentScore?: number | null | undefined;
|
|
3131
|
+
};
|
|
3132
|
+
messages: {
|
|
3133
|
+
time: string;
|
|
3134
|
+
id: string;
|
|
3135
|
+
content: string;
|
|
3136
|
+
role: "agent" | "customer" | "system";
|
|
3137
|
+
name?: string | undefined;
|
|
3138
|
+
scheduled?: string | undefined;
|
|
3139
|
+
context?: any;
|
|
3140
|
+
intent?: string | null | undefined;
|
|
3141
|
+
intentScore?: number | null | undefined;
|
|
3142
|
+
}[];
|
|
3143
|
+
stagnationCount: number;
|
|
3144
|
+
context?: any;
|
|
3145
|
+
note?: string | undefined;
|
|
3146
|
+
}>;
|
|
3147
|
+
/**
|
|
3148
|
+
* Lazy is used to handle recursive types.
|
|
3149
|
+
*
|
|
3150
|
+
*/
|
|
3151
|
+
export const ConversationContext: any;
|
|
3152
|
+
/**
|
|
3153
|
+
* Forward input information of a conversation
|
|
3154
|
+
*
|
|
3155
|
+
*/
|
|
3156
|
+
export const ForwardSchema: z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
3157
|
+
to: z.ZodOptional<z.ZodString>;
|
|
3158
|
+
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
3159
|
+
note: z.ZodOptional<z.ZodString>;
|
|
3160
|
+
}, "strip", z.ZodTypeAny, {
|
|
3161
|
+
to?: string | undefined;
|
|
3162
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3163
|
+
note?: string | undefined;
|
|
3164
|
+
}, {
|
|
3165
|
+
to?: string | undefined;
|
|
3166
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3167
|
+
note?: string | undefined;
|
|
3168
|
+
}>]>;
|
|
3169
|
+
/**
|
|
3170
|
+
* Instruction object schema used to send context to guide conversations
|
|
3171
|
+
*
|
|
3172
|
+
*/
|
|
3173
|
+
export const InstructionSchema: z.ZodObject<{
|
|
3174
|
+
id: z.ZodString;
|
|
3175
|
+
content: z.ZodString;
|
|
3176
|
+
}, "strip", z.ZodTypeAny, {
|
|
3177
|
+
id: string;
|
|
3178
|
+
content: string;
|
|
3179
|
+
}, {
|
|
3180
|
+
id: string;
|
|
3181
|
+
content: string;
|
|
3182
|
+
}>;
|
|
3183
|
+
/**
|
|
3184
|
+
* If its a string, it will be sent as a static string.
|
|
3185
|
+
* If it's a object or WorkflowResponseMessageAPI - it will use
|
|
3186
|
+
*
|
|
3187
|
+
*/
|
|
3188
|
+
export const WorkflowResponseMessage: z.ZodUnion<readonly [z.ZodTypeAny, z.ZodTypeAny, ...z.ZodTypeAny[]]>;
|
|
3189
|
+
|
|
3190
|
+
export const WorkflowResponseMessageApiRequest: z.ZodObject<{
|
|
3191
|
+
uri: z.ZodString;
|
|
3192
|
+
data: z.ZodOptional<z.ZodAny>;
|
|
3193
|
+
headers: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
3194
|
+
method: z.ZodOptional<z.ZodEnum<["GET", "POST", "PUT"]>>;
|
|
3195
|
+
}, "strip", z.ZodTypeAny, {
|
|
3196
|
+
uri: string;
|
|
3197
|
+
data?: any;
|
|
3198
|
+
headers?: {} | undefined;
|
|
3199
|
+
method?: "GET" | "POST" | "PUT" | undefined;
|
|
3200
|
+
}, {
|
|
3201
|
+
uri: string;
|
|
3202
|
+
data?: any;
|
|
3203
|
+
headers?: {} | undefined;
|
|
3204
|
+
method?: "GET" | "POST" | "PUT" | undefined;
|
|
3205
|
+
}>;
|
|
3206
|
+
/**
|
|
3207
|
+
* The intended response provided by the WorkflowResponseMessageApiRequest
|
|
3208
|
+
*
|
|
3209
|
+
*/
|
|
3210
|
+
export const WorkflowResponseMessageApiResponse: z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
3211
|
+
message: z.ZodString;
|
|
3212
|
+
}, "strip", z.ZodTypeAny, {
|
|
3213
|
+
message: string;
|
|
3214
|
+
}, {
|
|
3215
|
+
message: string;
|
|
3216
|
+
}>, z.ZodObject<{
|
|
3217
|
+
text: z.ZodString;
|
|
3218
|
+
}, "strip", z.ZodTypeAny, {
|
|
3219
|
+
text: string;
|
|
3220
|
+
}, {
|
|
3221
|
+
text: string;
|
|
3222
|
+
}>, z.ZodObject<{
|
|
3223
|
+
data: z.ZodObject<{
|
|
3224
|
+
message: z.ZodString;
|
|
3225
|
+
}, "strip", z.ZodTypeAny, {
|
|
3226
|
+
message: string;
|
|
2071
3227
|
}, {
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
3228
|
+
message: string;
|
|
3229
|
+
}>;
|
|
3230
|
+
}, "strip", z.ZodTypeAny, {
|
|
3231
|
+
data: {
|
|
3232
|
+
message: string;
|
|
3233
|
+
};
|
|
3234
|
+
}, {
|
|
3235
|
+
data: {
|
|
3236
|
+
message: string;
|
|
3237
|
+
};
|
|
3238
|
+
}>, z.ZodObject<{
|
|
3239
|
+
data: z.ZodObject<{
|
|
3240
|
+
text: z.ZodString;
|
|
2085
3241
|
}, "strip", z.ZodTypeAny, {
|
|
2086
|
-
|
|
2087
|
-
UPDATE?: boolean | undefined;
|
|
2088
|
-
QUERY?: boolean | undefined;
|
|
2089
|
-
PUT?: boolean | undefined;
|
|
2090
|
-
PATCH?: boolean | undefined;
|
|
2091
|
-
DELETE?: boolean | undefined;
|
|
3242
|
+
text: string;
|
|
2092
3243
|
}, {
|
|
2093
|
-
GET?: boolean | undefined;
|
|
2094
|
-
UPDATE?: boolean | undefined;
|
|
2095
|
-
QUERY?: boolean | undefined;
|
|
2096
|
-
PUT?: boolean | undefined;
|
|
2097
|
-
PATCH?: boolean | undefined;
|
|
2098
|
-
DELETE?: boolean | undefined;
|
|
2099
|
-
}>>;
|
|
2100
|
-
}, "strict", z.ZodTypeAny, {
|
|
2101
|
-
entity: string;
|
|
2102
|
-
entities: string[];
|
|
2103
|
-
api: {
|
|
2104
|
-
GET?: boolean | undefined;
|
|
2105
|
-
UPDATE?: boolean | undefined;
|
|
2106
|
-
QUERY?: boolean | undefined;
|
|
2107
|
-
PUT?: boolean | undefined;
|
|
2108
|
-
PATCH?: boolean | undefined;
|
|
2109
|
-
DELETE?: boolean | undefined;
|
|
2110
|
-
} | null;
|
|
2111
|
-
id?: string | undefined;
|
|
2112
|
-
training?: {
|
|
2113
3244
|
text: string;
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
3245
|
+
}>;
|
|
3246
|
+
}, "strip", z.ZodTypeAny, {
|
|
3247
|
+
data: {
|
|
2117
3248
|
text: string;
|
|
2118
|
-
|
|
2119
|
-
intent: string;
|
|
2120
|
-
context?: any;
|
|
2121
|
-
};
|
|
2122
|
-
}[] | undefined;
|
|
2123
|
-
definitions?: {
|
|
2124
|
-
value: string;
|
|
2125
|
-
text: string[];
|
|
2126
|
-
utterance?: string | undefined;
|
|
2127
|
-
}[] | undefined;
|
|
3249
|
+
};
|
|
2128
3250
|
}, {
|
|
2129
|
-
|
|
2130
|
-
entities: string[];
|
|
2131
|
-
api: {
|
|
2132
|
-
GET?: boolean | undefined;
|
|
2133
|
-
UPDATE?: boolean | undefined;
|
|
2134
|
-
QUERY?: boolean | undefined;
|
|
2135
|
-
PUT?: boolean | undefined;
|
|
2136
|
-
PATCH?: boolean | undefined;
|
|
2137
|
-
DELETE?: boolean | undefined;
|
|
2138
|
-
} | null;
|
|
2139
|
-
id?: string | undefined;
|
|
2140
|
-
training?: {
|
|
2141
|
-
text: string;
|
|
2142
|
-
intent: string;
|
|
2143
|
-
}[] | undefined;
|
|
2144
|
-
tests?: {
|
|
2145
|
-
text: string;
|
|
2146
|
-
expected: {
|
|
2147
|
-
intent: string;
|
|
2148
|
-
context?: any;
|
|
2149
|
-
};
|
|
2150
|
-
}[] | undefined;
|
|
2151
|
-
definitions?: {
|
|
2152
|
-
value: string;
|
|
2153
|
-
text: string[];
|
|
2154
|
-
utterance?: string | undefined;
|
|
2155
|
-
}[] | undefined;
|
|
2156
|
-
}>, {
|
|
2157
|
-
entity: string;
|
|
2158
|
-
entities: string[];
|
|
2159
|
-
api: {
|
|
2160
|
-
GET?: boolean | undefined;
|
|
2161
|
-
UPDATE?: boolean | undefined;
|
|
2162
|
-
QUERY?: boolean | undefined;
|
|
2163
|
-
PUT?: boolean | undefined;
|
|
2164
|
-
PATCH?: boolean | undefined;
|
|
2165
|
-
DELETE?: boolean | undefined;
|
|
2166
|
-
} | null;
|
|
2167
|
-
id?: string | undefined;
|
|
2168
|
-
training?: {
|
|
2169
|
-
text: string;
|
|
2170
|
-
intent: string;
|
|
2171
|
-
}[] | undefined;
|
|
2172
|
-
tests?: {
|
|
3251
|
+
data: {
|
|
2173
3252
|
text: string;
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
3253
|
+
};
|
|
3254
|
+
}>]>;
|
|
3255
|
+
/**
|
|
3256
|
+
* The workflow response object slot
|
|
3257
|
+
*
|
|
3258
|
+
*/
|
|
3259
|
+
export const WorkflowResponseSlotSchema: z.ZodObject<{
|
|
3260
|
+
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
3261
|
+
to: z.ZodOptional<z.ZodString>;
|
|
3262
|
+
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
3263
|
+
note: z.ZodOptional<z.ZodString>;
|
|
3264
|
+
}, "strip", z.ZodTypeAny, {
|
|
3265
|
+
to?: string | undefined;
|
|
3266
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3267
|
+
note?: string | undefined;
|
|
3268
|
+
}, {
|
|
3269
|
+
to?: string | undefined;
|
|
3270
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3271
|
+
note?: string | undefined;
|
|
3272
|
+
}>]>>;
|
|
3273
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
3274
|
+
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
3275
|
+
id: z.ZodString;
|
|
3276
|
+
content: z.ZodString;
|
|
3277
|
+
}, "strip", z.ZodTypeAny, {
|
|
3278
|
+
id: string;
|
|
3279
|
+
content: string;
|
|
3280
|
+
}, {
|
|
3281
|
+
id: string;
|
|
3282
|
+
content: string;
|
|
3283
|
+
}>, z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
3284
|
+
id: z.ZodString;
|
|
3285
|
+
content: z.ZodString;
|
|
3286
|
+
}, "strip", z.ZodTypeAny, {
|
|
3287
|
+
id: string;
|
|
3288
|
+
content: string;
|
|
3289
|
+
}, {
|
|
3290
|
+
id: string;
|
|
3291
|
+
content: string;
|
|
3292
|
+
}>, "many">]>>;
|
|
3293
|
+
removeInstructions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
3294
|
+
message: z.ZodOptional<z.ZodString>;
|
|
3295
|
+
secondsDelay: z.ZodOptional<z.ZodNumber>;
|
|
3296
|
+
scheduled: z.ZodOptional<z.ZodNumber>;
|
|
3297
|
+
contextUpsert: any;
|
|
3298
|
+
resetIntent: z.ZodOptional<z.ZodBoolean>;
|
|
3299
|
+
}, "strip", z.ZodTypeAny, {
|
|
3300
|
+
forward?: string | boolean | {
|
|
3301
|
+
to?: string | undefined;
|
|
3302
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3303
|
+
note?: string | undefined;
|
|
3304
|
+
} | undefined;
|
|
3305
|
+
forwardNote?: string | undefined;
|
|
3306
|
+
instructions?: string | string[] | {
|
|
3307
|
+
id: string;
|
|
3308
|
+
content: string;
|
|
3309
|
+
} | {
|
|
3310
|
+
id: string;
|
|
3311
|
+
content: string;
|
|
2183
3312
|
}[] | undefined;
|
|
3313
|
+
removeInstructions?: string[] | undefined;
|
|
3314
|
+
message?: string | undefined;
|
|
3315
|
+
secondsDelay?: number | undefined;
|
|
3316
|
+
scheduled?: number | undefined;
|
|
3317
|
+
contextUpsert?: any;
|
|
3318
|
+
resetIntent?: boolean | undefined;
|
|
2184
3319
|
}, {
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
} |
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
text: string;
|
|
2198
|
-
intent: string;
|
|
2199
|
-
}[] | undefined;
|
|
2200
|
-
tests?: {
|
|
2201
|
-
text: string;
|
|
2202
|
-
expected: {
|
|
2203
|
-
intent: string;
|
|
2204
|
-
context?: any;
|
|
2205
|
-
};
|
|
2206
|
-
}[] | undefined;
|
|
2207
|
-
definitions?: {
|
|
2208
|
-
value: string;
|
|
2209
|
-
text: string[];
|
|
2210
|
-
utterance?: string | undefined;
|
|
3320
|
+
forward?: string | boolean | {
|
|
3321
|
+
to?: string | undefined;
|
|
3322
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3323
|
+
note?: string | undefined;
|
|
3324
|
+
} | undefined;
|
|
3325
|
+
forwardNote?: string | undefined;
|
|
3326
|
+
instructions?: string | string[] | {
|
|
3327
|
+
id: string;
|
|
3328
|
+
content: string;
|
|
3329
|
+
} | {
|
|
3330
|
+
id: string;
|
|
3331
|
+
content: string;
|
|
2211
3332
|
}[] | undefined;
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
}, "strip", z.ZodTypeAny, {
|
|
2219
|
-
time: string;
|
|
2220
|
-
content: string;
|
|
2221
|
-
role: "agent" | "customer" | "system";
|
|
2222
|
-
name?: string | undefined;
|
|
2223
|
-
}, {
|
|
2224
|
-
time: string;
|
|
2225
|
-
content: string;
|
|
2226
|
-
role: "agent" | "customer" | "system";
|
|
2227
|
-
name?: string | undefined;
|
|
2228
|
-
}>;
|
|
2229
|
-
export const WorkflowConfigurationSchema: z.ZodObject<{
|
|
2230
|
-
entities: z.ZodArray<z.ZodString, "many">;
|
|
2231
|
-
entity: z.ZodString;
|
|
2232
|
-
}, "strip", z.ZodTypeAny, {
|
|
2233
|
-
entity: string;
|
|
2234
|
-
entities: string[];
|
|
2235
|
-
}, {
|
|
2236
|
-
entity: string;
|
|
2237
|
-
entities: string[];
|
|
3333
|
+
removeInstructions?: string[] | undefined;
|
|
3334
|
+
message?: string | undefined;
|
|
3335
|
+
secondsDelay?: number | undefined;
|
|
3336
|
+
scheduled?: number | undefined;
|
|
3337
|
+
contextUpsert?: any;
|
|
3338
|
+
resetIntent?: boolean | undefined;
|
|
2238
3339
|
}>;
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
|
|
2248
|
-
}>, "many">;
|
|
2249
|
-
export const ConversationSchema: z.ZodObject<{
|
|
2250
|
-
$agent: z.ZodString;
|
|
2251
|
-
$customer: z.ZodString;
|
|
2252
|
-
initialContexts: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2253
|
-
environment: z.ZodEnum<["phone", "email", "web"]>;
|
|
2254
|
-
environmentProps: z.ZodOptional<z.ZodObject<{
|
|
2255
|
-
subject: z.ZodOptional<z.ZodString>;
|
|
2256
|
-
platformEmailThreadId: z.ZodOptional<z.ZodString>;
|
|
3340
|
+
/**
|
|
3341
|
+
* The workflow response to send in any given workflow
|
|
3342
|
+
*
|
|
3343
|
+
*/
|
|
3344
|
+
export const WorkflowResponseSchema: z.ZodUnion<[z.ZodObject<{
|
|
3345
|
+
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
3346
|
+
to: z.ZodOptional<z.ZodString>;
|
|
3347
|
+
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
3348
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2257
3349
|
}, "strip", z.ZodTypeAny, {
|
|
2258
|
-
|
|
2259
|
-
|
|
3350
|
+
to?: string | undefined;
|
|
3351
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3352
|
+
note?: string | undefined;
|
|
2260
3353
|
}, {
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
3354
|
+
to?: string | undefined;
|
|
3355
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3356
|
+
note?: string | undefined;
|
|
3357
|
+
}>]>>;
|
|
3358
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
3359
|
+
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
3360
|
+
id: z.ZodString;
|
|
3361
|
+
content: z.ZodString;
|
|
3362
|
+
}, "strip", z.ZodTypeAny, {
|
|
3363
|
+
id: string;
|
|
3364
|
+
content: string;
|
|
3365
|
+
}, {
|
|
3366
|
+
id: string;
|
|
3367
|
+
content: string;
|
|
3368
|
+
}>, z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
3369
|
+
id: z.ZodString;
|
|
3370
|
+
content: z.ZodString;
|
|
3371
|
+
}, "strip", z.ZodTypeAny, {
|
|
3372
|
+
id: string;
|
|
3373
|
+
content: string;
|
|
3374
|
+
}, {
|
|
3375
|
+
id: string;
|
|
3376
|
+
content: string;
|
|
3377
|
+
}>, "many">]>>;
|
|
3378
|
+
removeInstructions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
3379
|
+
message: z.ZodOptional<z.ZodString>;
|
|
3380
|
+
secondsDelay: z.ZodOptional<z.ZodNumber>;
|
|
3381
|
+
scheduled: z.ZodOptional<z.ZodNumber>;
|
|
3382
|
+
contextUpsert: any;
|
|
3383
|
+
resetIntent: z.ZodOptional<z.ZodBoolean>;
|
|
2264
3384
|
}, "strip", z.ZodTypeAny, {
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
environmentProps?: {
|
|
2270
|
-
subject?: string | undefined;
|
|
2271
|
-
platformEmailThreadId?: string | undefined;
|
|
3385
|
+
forward?: string | boolean | {
|
|
3386
|
+
to?: string | undefined;
|
|
3387
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3388
|
+
note?: string | undefined;
|
|
2272
3389
|
} | undefined;
|
|
3390
|
+
forwardNote?: string | undefined;
|
|
3391
|
+
instructions?: string | string[] | {
|
|
3392
|
+
id: string;
|
|
3393
|
+
content: string;
|
|
3394
|
+
} | {
|
|
3395
|
+
id: string;
|
|
3396
|
+
content: string;
|
|
3397
|
+
}[] | undefined;
|
|
3398
|
+
removeInstructions?: string[] | undefined;
|
|
3399
|
+
message?: string | undefined;
|
|
3400
|
+
secondsDelay?: number | undefined;
|
|
3401
|
+
scheduled?: number | undefined;
|
|
3402
|
+
contextUpsert?: any;
|
|
3403
|
+
resetIntent?: boolean | undefined;
|
|
2273
3404
|
}, {
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
environmentProps?: {
|
|
2279
|
-
subject?: string | undefined;
|
|
2280
|
-
platformEmailThreadId?: string | undefined;
|
|
3405
|
+
forward?: string | boolean | {
|
|
3406
|
+
to?: string | undefined;
|
|
3407
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3408
|
+
note?: string | undefined;
|
|
2281
3409
|
} | undefined;
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
3410
|
+
forwardNote?: string | undefined;
|
|
3411
|
+
instructions?: string | string[] | {
|
|
3412
|
+
id: string;
|
|
3413
|
+
content: string;
|
|
3414
|
+
} | {
|
|
3415
|
+
id: string;
|
|
3416
|
+
content: string;
|
|
3417
|
+
}[] | undefined;
|
|
3418
|
+
removeInstructions?: string[] | undefined;
|
|
3419
|
+
message?: string | undefined;
|
|
3420
|
+
secondsDelay?: number | undefined;
|
|
3421
|
+
scheduled?: number | undefined;
|
|
3422
|
+
contextUpsert?: any;
|
|
3423
|
+
resetIntent?: boolean | undefined;
|
|
3424
|
+
}>, z.ZodArray<z.ZodObject<{
|
|
3425
|
+
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
3426
|
+
to: z.ZodOptional<z.ZodString>;
|
|
3427
|
+
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
3428
|
+
note: z.ZodOptional<z.ZodString>;
|
|
3429
|
+
}, "strip", z.ZodTypeAny, {
|
|
3430
|
+
to?: string | undefined;
|
|
3431
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3432
|
+
note?: string | undefined;
|
|
3433
|
+
}, {
|
|
3434
|
+
to?: string | undefined;
|
|
3435
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3436
|
+
note?: string | undefined;
|
|
3437
|
+
}>]>>;
|
|
3438
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
3439
|
+
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
3440
|
+
id: z.ZodString;
|
|
3441
|
+
content: z.ZodString;
|
|
3442
|
+
}, "strip", z.ZodTypeAny, {
|
|
3443
|
+
id: string;
|
|
3444
|
+
content: string;
|
|
3445
|
+
}, {
|
|
3446
|
+
id: string;
|
|
3447
|
+
content: string;
|
|
3448
|
+
}>, z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
3449
|
+
id: z.ZodString;
|
|
3450
|
+
content: z.ZodString;
|
|
3451
|
+
}, "strip", z.ZodTypeAny, {
|
|
3452
|
+
id: string;
|
|
3453
|
+
content: string;
|
|
3454
|
+
}, {
|
|
3455
|
+
id: string;
|
|
3456
|
+
content: string;
|
|
3457
|
+
}>, "many">]>>;
|
|
3458
|
+
removeInstructions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
3459
|
+
message: z.ZodOptional<z.ZodString>;
|
|
3460
|
+
secondsDelay: z.ZodOptional<z.ZodNumber>;
|
|
3461
|
+
scheduled: z.ZodOptional<z.ZodNumber>;
|
|
3462
|
+
contextUpsert: any;
|
|
3463
|
+
resetIntent: z.ZodOptional<z.ZodBoolean>;
|
|
2287
3464
|
}, "strip", z.ZodTypeAny, {
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
3465
|
+
forward?: string | boolean | {
|
|
3466
|
+
to?: string | undefined;
|
|
3467
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3468
|
+
note?: string | undefined;
|
|
3469
|
+
} | undefined;
|
|
3470
|
+
forwardNote?: string | undefined;
|
|
3471
|
+
instructions?: string | string[] | {
|
|
3472
|
+
id: string;
|
|
3473
|
+
content: string;
|
|
3474
|
+
} | {
|
|
3475
|
+
id: string;
|
|
3476
|
+
content: string;
|
|
3477
|
+
}[] | undefined;
|
|
3478
|
+
removeInstructions?: string[] | undefined;
|
|
3479
|
+
message?: string | undefined;
|
|
3480
|
+
secondsDelay?: number | undefined;
|
|
3481
|
+
scheduled?: number | undefined;
|
|
3482
|
+
contextUpsert?: any;
|
|
3483
|
+
resetIntent?: boolean | undefined;
|
|
2291
3484
|
}, {
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
3485
|
+
forward?: string | boolean | {
|
|
3486
|
+
to?: string | undefined;
|
|
3487
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3488
|
+
note?: string | undefined;
|
|
3489
|
+
} | undefined;
|
|
3490
|
+
forwardNote?: string | undefined;
|
|
3491
|
+
instructions?: string | string[] | {
|
|
3492
|
+
id: string;
|
|
3493
|
+
content: string;
|
|
3494
|
+
} | {
|
|
3495
|
+
id: string;
|
|
3496
|
+
content: string;
|
|
3497
|
+
}[] | undefined;
|
|
3498
|
+
removeInstructions?: string[] | undefined;
|
|
3499
|
+
message?: string | undefined;
|
|
3500
|
+
secondsDelay?: number | undefined;
|
|
3501
|
+
scheduled?: number | undefined;
|
|
3502
|
+
contextUpsert?: any;
|
|
3503
|
+
resetIntent?: boolean | undefined;
|
|
3504
|
+
}>, "many">]>;
|
|
3505
|
+
|
|
3506
|
+
export const WorkflowFunctionSchema: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
2297
3507
|
messages: z.ZodArray<z.ZodObject<{
|
|
2298
|
-
|
|
3508
|
+
id: z.ZodString;
|
|
2299
3509
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
3510
|
+
content: z.ZodString;
|
|
2300
3511
|
time: z.ZodString;
|
|
2301
3512
|
name: z.ZodOptional<z.ZodString>;
|
|
3513
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
3514
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
3515
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3516
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2302
3517
|
}, "strip", z.ZodTypeAny, {
|
|
2303
3518
|
time: string;
|
|
3519
|
+
id: string;
|
|
2304
3520
|
content: string;
|
|
2305
3521
|
role: "agent" | "customer" | "system";
|
|
2306
3522
|
name?: string | undefined;
|
|
3523
|
+
scheduled?: string | undefined;
|
|
3524
|
+
context?: any;
|
|
3525
|
+
intent?: string | null | undefined;
|
|
3526
|
+
intentScore?: number | null | undefined;
|
|
2307
3527
|
}, {
|
|
2308
3528
|
time: string;
|
|
3529
|
+
id: string;
|
|
2309
3530
|
content: string;
|
|
2310
3531
|
role: "agent" | "customer" | "system";
|
|
2311
3532
|
name?: string | undefined;
|
|
3533
|
+
scheduled?: string | undefined;
|
|
3534
|
+
context?: any;
|
|
3535
|
+
intent?: string | null | undefined;
|
|
3536
|
+
intentScore?: number | null | undefined;
|
|
2312
3537
|
}>, "many">;
|
|
2313
3538
|
conversation: z.ZodObject<{
|
|
2314
3539
|
$agent: z.ZodString;
|
|
@@ -2325,6 +3550,14 @@ declare module '@scout9/app/types' {
|
|
|
2325
3550
|
subject?: string | undefined;
|
|
2326
3551
|
platformEmailThreadId?: string | undefined;
|
|
2327
3552
|
}>>;
|
|
3553
|
+
locked: z.ZodNullable<z.ZodOptional<z.ZodBoolean>>;
|
|
3554
|
+
lockedReason: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3555
|
+
lockAttempts: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
3556
|
+
forwardedTo: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3557
|
+
forwarded: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3558
|
+
forwardNote: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3559
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3560
|
+
intentScore: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
2328
3561
|
}, "strip", z.ZodTypeAny, {
|
|
2329
3562
|
environment: "email" | "phone" | "web";
|
|
2330
3563
|
$agent: string;
|
|
@@ -2334,6 +3567,14 @@ declare module '@scout9/app/types' {
|
|
|
2334
3567
|
subject?: string | undefined;
|
|
2335
3568
|
platformEmailThreadId?: string | undefined;
|
|
2336
3569
|
} | undefined;
|
|
3570
|
+
locked?: boolean | null | undefined;
|
|
3571
|
+
lockedReason?: string | null | undefined;
|
|
3572
|
+
lockAttempts?: number | null | undefined;
|
|
3573
|
+
forwardedTo?: string | null | undefined;
|
|
3574
|
+
forwarded?: string | null | undefined;
|
|
3575
|
+
forwardNote?: string | null | undefined;
|
|
3576
|
+
intent?: string | null | undefined;
|
|
3577
|
+
intentScore?: number | null | undefined;
|
|
2337
3578
|
}, {
|
|
2338
3579
|
environment: "email" | "phone" | "web";
|
|
2339
3580
|
$agent: string;
|
|
@@ -2343,45 +3584,84 @@ declare module '@scout9/app/types' {
|
|
|
2343
3584
|
subject?: string | undefined;
|
|
2344
3585
|
platformEmailThreadId?: string | undefined;
|
|
2345
3586
|
} | undefined;
|
|
3587
|
+
locked?: boolean | null | undefined;
|
|
3588
|
+
lockedReason?: string | null | undefined;
|
|
3589
|
+
lockAttempts?: number | null | undefined;
|
|
3590
|
+
forwardedTo?: string | null | undefined;
|
|
3591
|
+
forwarded?: string | null | undefined;
|
|
3592
|
+
forwardNote?: string | null | undefined;
|
|
3593
|
+
intent?: string | null | undefined;
|
|
3594
|
+
intentScore?: number | null | undefined;
|
|
2346
3595
|
}>;
|
|
2347
3596
|
context: z.ZodAny;
|
|
2348
3597
|
message: z.ZodObject<{
|
|
2349
|
-
|
|
3598
|
+
id: z.ZodString;
|
|
2350
3599
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
3600
|
+
content: z.ZodString;
|
|
2351
3601
|
time: z.ZodString;
|
|
2352
3602
|
name: z.ZodOptional<z.ZodString>;
|
|
3603
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
3604
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
3605
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3606
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2353
3607
|
}, "strip", z.ZodTypeAny, {
|
|
2354
3608
|
time: string;
|
|
3609
|
+
id: string;
|
|
2355
3610
|
content: string;
|
|
2356
3611
|
role: "agent" | "customer" | "system";
|
|
2357
3612
|
name?: string | undefined;
|
|
3613
|
+
scheduled?: string | undefined;
|
|
3614
|
+
context?: any;
|
|
3615
|
+
intent?: string | null | undefined;
|
|
3616
|
+
intentScore?: number | null | undefined;
|
|
2358
3617
|
}, {
|
|
2359
3618
|
time: string;
|
|
3619
|
+
id: string;
|
|
2360
3620
|
content: string;
|
|
2361
3621
|
role: "agent" | "customer" | "system";
|
|
2362
3622
|
name?: string | undefined;
|
|
3623
|
+
scheduled?: string | undefined;
|
|
3624
|
+
context?: any;
|
|
3625
|
+
intent?: string | null | undefined;
|
|
3626
|
+
intentScore?: number | null | undefined;
|
|
2363
3627
|
}>;
|
|
2364
|
-
agent: z.ZodObject<{
|
|
3628
|
+
agent: z.ZodObject<Omit<{
|
|
2365
3629
|
inactive: z.ZodOptional<z.ZodBoolean>;
|
|
3630
|
+
img: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2366
3631
|
title: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
2367
3632
|
context: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
2368
3633
|
firstName: z.ZodOptional<z.ZodString>;
|
|
2369
3634
|
lastName: z.ZodOptional<z.ZodString>;
|
|
2370
3635
|
transcripts: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
2371
|
-
|
|
3636
|
+
id: z.ZodString;
|
|
2372
3637
|
role: z.ZodEnum<["agent", "customer", "system"]>;
|
|
3638
|
+
content: z.ZodString;
|
|
2373
3639
|
time: z.ZodString;
|
|
2374
3640
|
name: z.ZodOptional<z.ZodString>;
|
|
3641
|
+
scheduled: z.ZodOptional<z.ZodString>;
|
|
3642
|
+
context: z.ZodOptional<z.ZodAny>;
|
|
3643
|
+
intent: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
3644
|
+
intentScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2375
3645
|
}, "strip", z.ZodTypeAny, {
|
|
2376
3646
|
time: string;
|
|
3647
|
+
id: string;
|
|
2377
3648
|
content: string;
|
|
2378
3649
|
role: "agent" | "customer" | "system";
|
|
2379
3650
|
name?: string | undefined;
|
|
3651
|
+
scheduled?: string | undefined;
|
|
3652
|
+
context?: any;
|
|
3653
|
+
intent?: string | null | undefined;
|
|
3654
|
+
intentScore?: number | null | undefined;
|
|
2380
3655
|
}, {
|
|
2381
3656
|
time: string;
|
|
3657
|
+
id: string;
|
|
2382
3658
|
content: string;
|
|
2383
3659
|
role: "agent" | "customer" | "system";
|
|
2384
3660
|
name?: string | undefined;
|
|
3661
|
+
scheduled?: string | undefined;
|
|
3662
|
+
context?: any;
|
|
3663
|
+
intent?: string | null | undefined;
|
|
3664
|
+
intentScore?: number | null | undefined;
|
|
2385
3665
|
}>, "many">, "many">>;
|
|
2386
3666
|
audios: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>;
|
|
2387
3667
|
includedLocations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
@@ -2406,23 +3686,13 @@ declare module '@scout9/app/types' {
|
|
|
2406
3686
|
forwardEmail: z.ZodOptional<z.ZodString>;
|
|
2407
3687
|
forwardPhone: z.ZodOptional<z.ZodString>;
|
|
2408
3688
|
id: z.ZodString;
|
|
2409
|
-
}, "strip", z.ZodTypeAny, {
|
|
3689
|
+
}, "context" | "transcripts" | "audios" | "includedLocations" | "excludedLocations" | "model">, "strip", z.ZodTypeAny, {
|
|
2410
3690
|
id: string;
|
|
2411
3691
|
title: string;
|
|
2412
|
-
context: string;
|
|
2413
|
-
model: "openai" | "bard" | "Scout9";
|
|
2414
3692
|
inactive?: boolean | undefined;
|
|
3693
|
+
img?: string | null | undefined;
|
|
2415
3694
|
firstName?: string | undefined;
|
|
2416
3695
|
lastName?: string | undefined;
|
|
2417
|
-
transcripts?: {
|
|
2418
|
-
time: string;
|
|
2419
|
-
content: string;
|
|
2420
|
-
role: "agent" | "customer" | "system";
|
|
2421
|
-
name?: string | undefined;
|
|
2422
|
-
}[][] | undefined;
|
|
2423
|
-
audios?: any[] | undefined;
|
|
2424
|
-
includedLocations?: string[] | undefined;
|
|
2425
|
-
excludedLocations?: string[] | undefined;
|
|
2426
3696
|
deployed?: {
|
|
2427
3697
|
web?: string | undefined;
|
|
2428
3698
|
phone?: string | undefined;
|
|
@@ -2436,20 +3706,10 @@ declare module '@scout9/app/types' {
|
|
|
2436
3706
|
}, {
|
|
2437
3707
|
id: string;
|
|
2438
3708
|
inactive?: boolean | undefined;
|
|
3709
|
+
img?: string | null | undefined;
|
|
2439
3710
|
title?: string | undefined;
|
|
2440
|
-
context?: string | undefined;
|
|
2441
3711
|
firstName?: string | undefined;
|
|
2442
3712
|
lastName?: string | undefined;
|
|
2443
|
-
transcripts?: {
|
|
2444
|
-
time: string;
|
|
2445
|
-
content: string;
|
|
2446
|
-
role: "agent" | "customer" | "system";
|
|
2447
|
-
name?: string | undefined;
|
|
2448
|
-
}[][] | undefined;
|
|
2449
|
-
audios?: any[] | undefined;
|
|
2450
|
-
includedLocations?: string[] | undefined;
|
|
2451
|
-
excludedLocations?: string[] | undefined;
|
|
2452
|
-
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
2453
3713
|
deployed?: {
|
|
2454
3714
|
web?: string | undefined;
|
|
2455
3715
|
phone?: string | undefined;
|
|
@@ -2534,27 +3794,22 @@ declare module '@scout9/app/types' {
|
|
|
2534
3794
|
}, "strip", z.ZodTypeAny, {
|
|
2535
3795
|
message: {
|
|
2536
3796
|
time: string;
|
|
3797
|
+
id: string;
|
|
2537
3798
|
content: string;
|
|
2538
3799
|
role: "agent" | "customer" | "system";
|
|
2539
3800
|
name?: string | undefined;
|
|
3801
|
+
scheduled?: string | undefined;
|
|
3802
|
+
context?: any;
|
|
3803
|
+
intent?: string | null | undefined;
|
|
3804
|
+
intentScore?: number | null | undefined;
|
|
2540
3805
|
};
|
|
2541
3806
|
agent: {
|
|
2542
3807
|
id: string;
|
|
2543
3808
|
title: string;
|
|
2544
|
-
context: string;
|
|
2545
|
-
model: "openai" | "bard" | "Scout9";
|
|
2546
3809
|
inactive?: boolean | undefined;
|
|
3810
|
+
img?: string | null | undefined;
|
|
2547
3811
|
firstName?: string | undefined;
|
|
2548
3812
|
lastName?: string | undefined;
|
|
2549
|
-
transcripts?: {
|
|
2550
|
-
time: string;
|
|
2551
|
-
content: string;
|
|
2552
|
-
role: "agent" | "customer" | "system";
|
|
2553
|
-
name?: string | undefined;
|
|
2554
|
-
}[][] | undefined;
|
|
2555
|
-
audios?: any[] | undefined;
|
|
2556
|
-
includedLocations?: string[] | undefined;
|
|
2557
|
-
excludedLocations?: string[] | undefined;
|
|
2558
3813
|
deployed?: {
|
|
2559
3814
|
web?: string | undefined;
|
|
2560
3815
|
phone?: string | undefined;
|
|
@@ -2601,12 +3856,25 @@ declare module '@scout9/app/types' {
|
|
|
2601
3856
|
subject?: string | undefined;
|
|
2602
3857
|
platformEmailThreadId?: string | undefined;
|
|
2603
3858
|
} | undefined;
|
|
3859
|
+
locked?: boolean | null | undefined;
|
|
3860
|
+
lockedReason?: string | null | undefined;
|
|
3861
|
+
lockAttempts?: number | null | undefined;
|
|
3862
|
+
forwardedTo?: string | null | undefined;
|
|
3863
|
+
forwarded?: string | null | undefined;
|
|
3864
|
+
forwardNote?: string | null | undefined;
|
|
3865
|
+
intent?: string | null | undefined;
|
|
3866
|
+
intentScore?: number | null | undefined;
|
|
2604
3867
|
};
|
|
2605
3868
|
messages: {
|
|
2606
3869
|
time: string;
|
|
3870
|
+
id: string;
|
|
2607
3871
|
content: string;
|
|
2608
3872
|
role: "agent" | "customer" | "system";
|
|
2609
3873
|
name?: string | undefined;
|
|
3874
|
+
scheduled?: string | undefined;
|
|
3875
|
+
context?: any;
|
|
3876
|
+
intent?: string | null | undefined;
|
|
3877
|
+
intentScore?: number | null | undefined;
|
|
2610
3878
|
}[];
|
|
2611
3879
|
stagnationCount: number;
|
|
2612
3880
|
context?: any;
|
|
@@ -2614,27 +3882,22 @@ declare module '@scout9/app/types' {
|
|
|
2614
3882
|
}, {
|
|
2615
3883
|
message: {
|
|
2616
3884
|
time: string;
|
|
3885
|
+
id: string;
|
|
2617
3886
|
content: string;
|
|
2618
3887
|
role: "agent" | "customer" | "system";
|
|
2619
3888
|
name?: string | undefined;
|
|
3889
|
+
scheduled?: string | undefined;
|
|
3890
|
+
context?: any;
|
|
3891
|
+
intent?: string | null | undefined;
|
|
3892
|
+
intentScore?: number | null | undefined;
|
|
2620
3893
|
};
|
|
2621
3894
|
agent: {
|
|
2622
3895
|
id: string;
|
|
2623
3896
|
inactive?: boolean | undefined;
|
|
3897
|
+
img?: string | null | undefined;
|
|
2624
3898
|
title?: string | undefined;
|
|
2625
|
-
context?: string | undefined;
|
|
2626
3899
|
firstName?: string | undefined;
|
|
2627
3900
|
lastName?: string | undefined;
|
|
2628
|
-
transcripts?: {
|
|
2629
|
-
time: string;
|
|
2630
|
-
content: string;
|
|
2631
|
-
role: "agent" | "customer" | "system";
|
|
2632
|
-
name?: string | undefined;
|
|
2633
|
-
}[][] | undefined;
|
|
2634
|
-
audios?: any[] | undefined;
|
|
2635
|
-
includedLocations?: string[] | undefined;
|
|
2636
|
-
excludedLocations?: string[] | undefined;
|
|
2637
|
-
model?: "openai" | "bard" | "Scout9" | undefined;
|
|
2638
3901
|
deployed?: {
|
|
2639
3902
|
web?: string | undefined;
|
|
2640
3903
|
phone?: string | undefined;
|
|
@@ -2681,118 +3944,124 @@ declare module '@scout9/app/types' {
|
|
|
2681
3944
|
subject?: string | undefined;
|
|
2682
3945
|
platformEmailThreadId?: string | undefined;
|
|
2683
3946
|
} | undefined;
|
|
3947
|
+
locked?: boolean | null | undefined;
|
|
3948
|
+
lockedReason?: string | null | undefined;
|
|
3949
|
+
lockAttempts?: number | null | undefined;
|
|
3950
|
+
forwardedTo?: string | null | undefined;
|
|
3951
|
+
forwarded?: string | null | undefined;
|
|
3952
|
+
forwardNote?: string | null | undefined;
|
|
3953
|
+
intent?: string | null | undefined;
|
|
3954
|
+
intentScore?: number | null | undefined;
|
|
2684
3955
|
};
|
|
2685
3956
|
messages: {
|
|
2686
3957
|
time: string;
|
|
3958
|
+
id: string;
|
|
2687
3959
|
content: string;
|
|
2688
3960
|
role: "agent" | "customer" | "system";
|
|
2689
3961
|
name?: string | undefined;
|
|
3962
|
+
scheduled?: string | undefined;
|
|
3963
|
+
context?: any;
|
|
3964
|
+
intent?: string | null | undefined;
|
|
3965
|
+
intentScore?: number | null | undefined;
|
|
2690
3966
|
}[];
|
|
2691
3967
|
stagnationCount: number;
|
|
2692
3968
|
context?: any;
|
|
2693
3969
|
note?: string | undefined;
|
|
2694
|
-
}
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
}, "strip", z.ZodTypeAny, {
|
|
2700
|
-
to?: string | undefined;
|
|
2701
|
-
mode?: "after-reply" | "immediately" | undefined;
|
|
2702
|
-
}, {
|
|
2703
|
-
to?: string | undefined;
|
|
2704
|
-
mode?: "after-reply" | "immediately" | undefined;
|
|
2705
|
-
}>]>;
|
|
2706
|
-
export const InstructionSchema: z.ZodObject<{
|
|
2707
|
-
id: z.ZodString;
|
|
2708
|
-
content: z.ZodString;
|
|
2709
|
-
}, "strip", z.ZodTypeAny, {
|
|
2710
|
-
id: string;
|
|
2711
|
-
content: string;
|
|
2712
|
-
}, {
|
|
2713
|
-
id: string;
|
|
2714
|
-
content: string;
|
|
2715
|
-
}>;
|
|
2716
|
-
/**
|
|
2717
|
-
* If its a string, it will be sent as a static string.
|
|
2718
|
-
* If it's a object or WorkflowResponseMessageAPI - it will use
|
|
2719
|
-
*/
|
|
2720
|
-
export const WorkflowResponseMessage: z.ZodUnion<readonly [z.ZodTypeAny, z.ZodTypeAny, ...z.ZodTypeAny[]]>;
|
|
2721
|
-
export const WorkflowResponseMessageApiRequest: z.ZodObject<{
|
|
2722
|
-
uri: z.ZodString;
|
|
2723
|
-
data: z.ZodOptional<z.ZodAny>;
|
|
2724
|
-
headers: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
2725
|
-
method: z.ZodOptional<z.ZodEnum<["GET", "POST", "PUT"]>>;
|
|
2726
|
-
}, "strip", z.ZodTypeAny, {
|
|
2727
|
-
uri: string;
|
|
2728
|
-
data?: any;
|
|
2729
|
-
headers?: {} | undefined;
|
|
2730
|
-
method?: "GET" | "POST" | "PUT" | undefined;
|
|
2731
|
-
}, {
|
|
2732
|
-
uri: string;
|
|
2733
|
-
data?: any;
|
|
2734
|
-
headers?: {} | undefined;
|
|
2735
|
-
method?: "GET" | "POST" | "PUT" | undefined;
|
|
2736
|
-
}>;
|
|
2737
|
-
/**
|
|
2738
|
-
* The intended response provided by the WorkflowResponseMessageApiRequest
|
|
2739
|
-
*/
|
|
2740
|
-
export const WorkflowResponseMessageApiResponse: z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
2741
|
-
message: z.ZodString;
|
|
2742
|
-
}, "strip", z.ZodTypeAny, {
|
|
2743
|
-
message: string;
|
|
2744
|
-
}, {
|
|
2745
|
-
message: string;
|
|
2746
|
-
}>, z.ZodObject<{
|
|
2747
|
-
text: z.ZodString;
|
|
2748
|
-
}, "strip", z.ZodTypeAny, {
|
|
2749
|
-
text: string;
|
|
2750
|
-
}, {
|
|
2751
|
-
text: string;
|
|
2752
|
-
}>, z.ZodObject<{
|
|
2753
|
-
data: z.ZodObject<{
|
|
2754
|
-
message: z.ZodString;
|
|
3970
|
+
}>], z.ZodUnknown>, z.ZodUnion<[z.ZodPromise<z.ZodUnion<[z.ZodObject<{
|
|
3971
|
+
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
3972
|
+
to: z.ZodOptional<z.ZodString>;
|
|
3973
|
+
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
3974
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2755
3975
|
}, "strip", z.ZodTypeAny, {
|
|
2756
|
-
|
|
3976
|
+
to?: string | undefined;
|
|
3977
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3978
|
+
note?: string | undefined;
|
|
2757
3979
|
}, {
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
message: string;
|
|
2767
|
-
};
|
|
2768
|
-
}>, z.ZodObject<{
|
|
2769
|
-
data: z.ZodObject<{
|
|
2770
|
-
text: z.ZodString;
|
|
3980
|
+
to?: string | undefined;
|
|
3981
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
3982
|
+
note?: string | undefined;
|
|
3983
|
+
}>]>>;
|
|
3984
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
3985
|
+
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
3986
|
+
id: z.ZodString;
|
|
3987
|
+
content: z.ZodString;
|
|
2771
3988
|
}, "strip", z.ZodTypeAny, {
|
|
2772
|
-
|
|
3989
|
+
id: string;
|
|
3990
|
+
content: string;
|
|
2773
3991
|
}, {
|
|
2774
|
-
|
|
2775
|
-
|
|
3992
|
+
id: string;
|
|
3993
|
+
content: string;
|
|
3994
|
+
}>, z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
3995
|
+
id: z.ZodString;
|
|
3996
|
+
content: z.ZodString;
|
|
3997
|
+
}, "strip", z.ZodTypeAny, {
|
|
3998
|
+
id: string;
|
|
3999
|
+
content: string;
|
|
4000
|
+
}, {
|
|
4001
|
+
id: string;
|
|
4002
|
+
content: string;
|
|
4003
|
+
}>, "many">]>>;
|
|
4004
|
+
removeInstructions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
4005
|
+
message: z.ZodOptional<z.ZodString>;
|
|
4006
|
+
secondsDelay: z.ZodOptional<z.ZodNumber>;
|
|
4007
|
+
scheduled: z.ZodOptional<z.ZodNumber>;
|
|
4008
|
+
contextUpsert: any;
|
|
4009
|
+
resetIntent: z.ZodOptional<z.ZodBoolean>;
|
|
2776
4010
|
}, "strip", z.ZodTypeAny, {
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
4011
|
+
forward?: string | boolean | {
|
|
4012
|
+
to?: string | undefined;
|
|
4013
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
4014
|
+
note?: string | undefined;
|
|
4015
|
+
} | undefined;
|
|
4016
|
+
forwardNote?: string | undefined;
|
|
4017
|
+
instructions?: string | string[] | {
|
|
4018
|
+
id: string;
|
|
4019
|
+
content: string;
|
|
4020
|
+
} | {
|
|
4021
|
+
id: string;
|
|
4022
|
+
content: string;
|
|
4023
|
+
}[] | undefined;
|
|
4024
|
+
removeInstructions?: string[] | undefined;
|
|
4025
|
+
message?: string | undefined;
|
|
4026
|
+
secondsDelay?: number | undefined;
|
|
4027
|
+
scheduled?: number | undefined;
|
|
4028
|
+
contextUpsert?: any;
|
|
4029
|
+
resetIntent?: boolean | undefined;
|
|
2780
4030
|
}, {
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
4031
|
+
forward?: string | boolean | {
|
|
4032
|
+
to?: string | undefined;
|
|
4033
|
+
mode?: "after-reply" | "immediately" | undefined;
|
|
4034
|
+
note?: string | undefined;
|
|
4035
|
+
} | undefined;
|
|
4036
|
+
forwardNote?: string | undefined;
|
|
4037
|
+
instructions?: string | string[] | {
|
|
4038
|
+
id: string;
|
|
4039
|
+
content: string;
|
|
4040
|
+
} | {
|
|
4041
|
+
id: string;
|
|
4042
|
+
content: string;
|
|
4043
|
+
}[] | undefined;
|
|
4044
|
+
removeInstructions?: string[] | undefined;
|
|
4045
|
+
message?: string | undefined;
|
|
4046
|
+
secondsDelay?: number | undefined;
|
|
4047
|
+
scheduled?: number | undefined;
|
|
4048
|
+
contextUpsert?: any;
|
|
4049
|
+
resetIntent?: boolean | undefined;
|
|
4050
|
+
}>, z.ZodArray<z.ZodObject<{
|
|
2786
4051
|
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
2787
4052
|
to: z.ZodOptional<z.ZodString>;
|
|
2788
4053
|
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
4054
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2789
4055
|
}, "strip", z.ZodTypeAny, {
|
|
2790
4056
|
to?: string | undefined;
|
|
2791
4057
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4058
|
+
note?: string | undefined;
|
|
2792
4059
|
}, {
|
|
2793
4060
|
to?: string | undefined;
|
|
2794
4061
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4062
|
+
note?: string | undefined;
|
|
2795
4063
|
}>]>>;
|
|
4064
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
2796
4065
|
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
2797
4066
|
id: z.ZodString;
|
|
2798
4067
|
content: z.ZodString;
|
|
@@ -2822,7 +4091,9 @@ declare module '@scout9/app/types' {
|
|
|
2822
4091
|
forward?: string | boolean | {
|
|
2823
4092
|
to?: string | undefined;
|
|
2824
4093
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4094
|
+
note?: string | undefined;
|
|
2825
4095
|
} | undefined;
|
|
4096
|
+
forwardNote?: string | undefined;
|
|
2826
4097
|
instructions?: string | string[] | {
|
|
2827
4098
|
id: string;
|
|
2828
4099
|
content: string;
|
|
@@ -2840,7 +4111,9 @@ declare module '@scout9/app/types' {
|
|
|
2840
4111
|
forward?: string | boolean | {
|
|
2841
4112
|
to?: string | undefined;
|
|
2842
4113
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4114
|
+
note?: string | undefined;
|
|
2843
4115
|
} | undefined;
|
|
4116
|
+
forwardNote?: string | undefined;
|
|
2844
4117
|
instructions?: string | string[] | {
|
|
2845
4118
|
id: string;
|
|
2846
4119
|
content: string;
|
|
@@ -2854,18 +4127,21 @@ declare module '@scout9/app/types' {
|
|
|
2854
4127
|
scheduled?: number | undefined;
|
|
2855
4128
|
contextUpsert?: any;
|
|
2856
4129
|
resetIntent?: boolean | undefined;
|
|
2857
|
-
}
|
|
2858
|
-
export const WorkflowResponseSchema: z.ZodUnion<[z.ZodObject<{
|
|
4130
|
+
}>, "many">]>>, z.ZodUnion<[z.ZodObject<{
|
|
2859
4131
|
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
2860
4132
|
to: z.ZodOptional<z.ZodString>;
|
|
2861
4133
|
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
4134
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2862
4135
|
}, "strip", z.ZodTypeAny, {
|
|
2863
4136
|
to?: string | undefined;
|
|
2864
4137
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4138
|
+
note?: string | undefined;
|
|
2865
4139
|
}, {
|
|
2866
4140
|
to?: string | undefined;
|
|
2867
4141
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4142
|
+
note?: string | undefined;
|
|
2868
4143
|
}>]>>;
|
|
4144
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
2869
4145
|
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
2870
4146
|
id: z.ZodString;
|
|
2871
4147
|
content: z.ZodString;
|
|
@@ -2895,7 +4171,9 @@ declare module '@scout9/app/types' {
|
|
|
2895
4171
|
forward?: string | boolean | {
|
|
2896
4172
|
to?: string | undefined;
|
|
2897
4173
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4174
|
+
note?: string | undefined;
|
|
2898
4175
|
} | undefined;
|
|
4176
|
+
forwardNote?: string | undefined;
|
|
2899
4177
|
instructions?: string | string[] | {
|
|
2900
4178
|
id: string;
|
|
2901
4179
|
content: string;
|
|
@@ -2913,7 +4191,9 @@ declare module '@scout9/app/types' {
|
|
|
2913
4191
|
forward?: string | boolean | {
|
|
2914
4192
|
to?: string | undefined;
|
|
2915
4193
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4194
|
+
note?: string | undefined;
|
|
2916
4195
|
} | undefined;
|
|
4196
|
+
forwardNote?: string | undefined;
|
|
2917
4197
|
instructions?: string | string[] | {
|
|
2918
4198
|
id: string;
|
|
2919
4199
|
content: string;
|
|
@@ -2931,13 +4211,17 @@ declare module '@scout9/app/types' {
|
|
|
2931
4211
|
forward: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodString, z.ZodObject<{
|
|
2932
4212
|
to: z.ZodOptional<z.ZodString>;
|
|
2933
4213
|
mode: z.ZodOptional<z.ZodEnum<["after-reply", "immediately"]>>;
|
|
4214
|
+
note: z.ZodOptional<z.ZodString>;
|
|
2934
4215
|
}, "strip", z.ZodTypeAny, {
|
|
2935
4216
|
to?: string | undefined;
|
|
2936
4217
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4218
|
+
note?: string | undefined;
|
|
2937
4219
|
}, {
|
|
2938
4220
|
to?: string | undefined;
|
|
2939
4221
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4222
|
+
note?: string | undefined;
|
|
2940
4223
|
}>]>>;
|
|
4224
|
+
forwardNote: z.ZodOptional<z.ZodString>;
|
|
2941
4225
|
instructions: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
2942
4226
|
id: z.ZodString;
|
|
2943
4227
|
content: z.ZodString;
|
|
@@ -2967,7 +4251,9 @@ declare module '@scout9/app/types' {
|
|
|
2967
4251
|
forward?: string | boolean | {
|
|
2968
4252
|
to?: string | undefined;
|
|
2969
4253
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4254
|
+
note?: string | undefined;
|
|
2970
4255
|
} | undefined;
|
|
4256
|
+
forwardNote?: string | undefined;
|
|
2971
4257
|
instructions?: string | string[] | {
|
|
2972
4258
|
id: string;
|
|
2973
4259
|
content: string;
|
|
@@ -2985,7 +4271,9 @@ declare module '@scout9/app/types' {
|
|
|
2985
4271
|
forward?: string | boolean | {
|
|
2986
4272
|
to?: string | undefined;
|
|
2987
4273
|
mode?: "after-reply" | "immediately" | undefined;
|
|
4274
|
+
note?: string | undefined;
|
|
2988
4275
|
} | undefined;
|
|
4276
|
+
forwardNote?: string | undefined;
|
|
2989
4277
|
instructions?: string | string[] | {
|
|
2990
4278
|
id: string;
|
|
2991
4279
|
content: string;
|
|
@@ -2999,7 +4287,381 @@ declare module '@scout9/app/types' {
|
|
|
2999
4287
|
scheduled?: number | undefined;
|
|
3000
4288
|
contextUpsert?: any;
|
|
3001
4289
|
resetIntent?: boolean | undefined;
|
|
3002
|
-
}>, "many">]
|
|
4290
|
+
}>, "many">]>]>>;
|
|
4291
|
+
export type IWorkflowConfiguration = import('zod').infer<typeof WorkflowConfigurationSchema>;
|
|
4292
|
+
export type IWorkflowsConfiguration = import('zod').infer<typeof WorkflowsConfigurationSchema>;
|
|
4293
|
+
export type IConversation = import('zod').infer<typeof ConversationSchema>;
|
|
4294
|
+
export type IIntentWorkflowEvent = import('zod').infer<typeof IntentWorkflowEventSchema>;
|
|
4295
|
+
export type IWorkflowEvent = import('zod').infer<typeof WorkflowEventSchema>;
|
|
4296
|
+
/**
|
|
4297
|
+
* Forward input information of a conversation
|
|
4298
|
+
*/
|
|
4299
|
+
export type IForward = import('zod').infer<typeof ForwardSchema>;
|
|
4300
|
+
/**
|
|
4301
|
+
* Instruction object schema used to send context to guide conversations
|
|
4302
|
+
*/
|
|
4303
|
+
export type IInstruction = import('zod').infer<typeof InstructionSchema>;
|
|
4304
|
+
/**
|
|
4305
|
+
* If its a string, it will be sent as a static string.
|
|
4306
|
+
* If it's a object or WorkflowResponseMessageAPI - it will use
|
|
4307
|
+
*/
|
|
4308
|
+
export type IWorkflowResponseMessage = import('zod').infer<typeof WorkflowResponseMessage>;
|
|
4309
|
+
export type IWorkflowResponseMessageApiRequest = import('zod').infer<typeof WorkflowResponseMessageApiRequest>;
|
|
4310
|
+
/**
|
|
4311
|
+
* The intended response provided by the WorkflowResponseMessageApiRequest
|
|
4312
|
+
*/
|
|
4313
|
+
export type IWorkflowResponseMessageApiResponse = import('zod').infer<typeof WorkflowResponseMessageApiResponse>;
|
|
4314
|
+
/**
|
|
4315
|
+
* The workflow response object slot
|
|
4316
|
+
*/
|
|
4317
|
+
export type IWorkflowResponseSlot = import('zod').infer<typeof WorkflowResponseSlotSchema>;
|
|
4318
|
+
/**
|
|
4319
|
+
* The workflow response to send in any given workflow
|
|
4320
|
+
*/
|
|
4321
|
+
export type IWorkflowResponse = import('zod').infer<typeof WorkflowResponseSchema>;
|
|
4322
|
+
export type IWorkflowFunction = import('zod').infer<typeof WorkflowFunctionSchema>;
|
|
4323
|
+
export const apiFunctionSchema: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4324
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4325
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4326
|
+
}, "strip", z.ZodTypeAny, {
|
|
4327
|
+
params: Record<string, string>;
|
|
4328
|
+
searchParams: Record<string, string | string[]>;
|
|
4329
|
+
}, {
|
|
4330
|
+
params: Record<string, string>;
|
|
4331
|
+
searchParams: Record<string, string | string[]>;
|
|
4332
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4333
|
+
body: z.ZodAny;
|
|
4334
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4335
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4336
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4337
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4338
|
+
}, "strip", z.ZodTypeAny, {
|
|
4339
|
+
status?: number | undefined;
|
|
4340
|
+
statusText?: string | undefined;
|
|
4341
|
+
headers?: any;
|
|
4342
|
+
}, {
|
|
4343
|
+
status?: number | undefined;
|
|
4344
|
+
statusText?: string | undefined;
|
|
4345
|
+
headers?: any;
|
|
4346
|
+
}>>; /**
|
|
4347
|
+
* @template Params
|
|
4348
|
+
* @template RequestBody
|
|
4349
|
+
* @template Response
|
|
4350
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4351
|
+
*/
|
|
4352
|
+
}, "strip", z.ZodTypeAny, {
|
|
4353
|
+
body?: any;
|
|
4354
|
+
init?: {
|
|
4355
|
+
status?: number | undefined;
|
|
4356
|
+
statusText?: string | undefined;
|
|
4357
|
+
headers?: any;
|
|
4358
|
+
} | undefined;
|
|
4359
|
+
}, {
|
|
4360
|
+
body?: any;
|
|
4361
|
+
init?: {
|
|
4362
|
+
status?: number | undefined;
|
|
4363
|
+
statusText?: string | undefined;
|
|
4364
|
+
headers?: any;
|
|
4365
|
+
} | undefined;
|
|
4366
|
+
}>>>;
|
|
4367
|
+
|
|
4368
|
+
export const queryApiFunctionSchema: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4369
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4370
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4371
|
+
}, "strip", z.ZodTypeAny, {
|
|
4372
|
+
params: Record<string, string>;
|
|
4373
|
+
searchParams: Record<string, string | string[]>;
|
|
4374
|
+
}, {
|
|
4375
|
+
params: Record<string, string>;
|
|
4376
|
+
searchParams: Record<string, string | string[]>;
|
|
4377
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4378
|
+
body: z.ZodAny;
|
|
4379
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4380
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4381
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4382
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4383
|
+
}, "strip", z.ZodTypeAny, {
|
|
4384
|
+
status?: number | undefined;
|
|
4385
|
+
statusText?: string | undefined;
|
|
4386
|
+
headers?: any;
|
|
4387
|
+
}, {
|
|
4388
|
+
status?: number | undefined;
|
|
4389
|
+
statusText?: string | undefined;
|
|
4390
|
+
headers?: any;
|
|
4391
|
+
}>>; /**
|
|
4392
|
+
* @template Params
|
|
4393
|
+
* @template RequestBody
|
|
4394
|
+
* @template Response
|
|
4395
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4396
|
+
*/
|
|
4397
|
+
}, "strip", z.ZodTypeAny, {
|
|
4398
|
+
body?: any;
|
|
4399
|
+
init?: {
|
|
4400
|
+
status?: number | undefined;
|
|
4401
|
+
statusText?: string | undefined;
|
|
4402
|
+
headers?: any;
|
|
4403
|
+
} | undefined;
|
|
4404
|
+
}, {
|
|
4405
|
+
body?: any;
|
|
4406
|
+
init?: {
|
|
4407
|
+
status?: number | undefined;
|
|
4408
|
+
statusText?: string | undefined;
|
|
4409
|
+
headers?: any;
|
|
4410
|
+
} | undefined;
|
|
4411
|
+
}>>>;
|
|
4412
|
+
|
|
4413
|
+
export const getApiFunctionSchema: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4414
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4415
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4416
|
+
}, "strip", z.ZodTypeAny, {
|
|
4417
|
+
params: Record<string, string>;
|
|
4418
|
+
searchParams: Record<string, string | string[]>;
|
|
4419
|
+
}, {
|
|
4420
|
+
params: Record<string, string>;
|
|
4421
|
+
searchParams: Record<string, string | string[]>;
|
|
4422
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4423
|
+
body: z.ZodAny;
|
|
4424
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4425
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4426
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4427
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4428
|
+
}, "strip", z.ZodTypeAny, {
|
|
4429
|
+
status?: number | undefined;
|
|
4430
|
+
statusText?: string | undefined;
|
|
4431
|
+
headers?: any;
|
|
4432
|
+
}, {
|
|
4433
|
+
status?: number | undefined;
|
|
4434
|
+
statusText?: string | undefined;
|
|
4435
|
+
headers?: any;
|
|
4436
|
+
}>>; /**
|
|
4437
|
+
* @template Params
|
|
4438
|
+
* @template RequestBody
|
|
4439
|
+
* @template Response
|
|
4440
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4441
|
+
*/
|
|
4442
|
+
}, "strip", z.ZodTypeAny, {
|
|
4443
|
+
body?: any;
|
|
4444
|
+
init?: {
|
|
4445
|
+
status?: number | undefined;
|
|
4446
|
+
statusText?: string | undefined;
|
|
4447
|
+
headers?: any;
|
|
4448
|
+
} | undefined;
|
|
4449
|
+
}, {
|
|
4450
|
+
body?: any;
|
|
4451
|
+
init?: {
|
|
4452
|
+
status?: number | undefined;
|
|
4453
|
+
statusText?: string | undefined;
|
|
4454
|
+
headers?: any;
|
|
4455
|
+
} | undefined;
|
|
4456
|
+
}>>>;
|
|
4457
|
+
export function postApiFunctionSchema(requestBodySchema: any): z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4458
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4459
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4460
|
+
body: any;
|
|
4461
|
+
}, "strip", z.ZodTypeAny, {
|
|
4462
|
+
params: Record<string, string>;
|
|
4463
|
+
searchParams: Record<string, string | string[]>;
|
|
4464
|
+
body?: any;
|
|
4465
|
+
}, {
|
|
4466
|
+
params: Record<string, string>;
|
|
4467
|
+
searchParams: Record<string, string | string[]>;
|
|
4468
|
+
body?: any;
|
|
4469
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4470
|
+
body: z.ZodAny;
|
|
4471
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4472
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4473
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4474
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4475
|
+
}, "strip", z.ZodTypeAny, {
|
|
4476
|
+
status?: number | undefined;
|
|
4477
|
+
statusText?: string | undefined;
|
|
4478
|
+
headers?: any;
|
|
4479
|
+
}, {
|
|
4480
|
+
status?: number | undefined;
|
|
4481
|
+
statusText?: string | undefined;
|
|
4482
|
+
headers?: any;
|
|
4483
|
+
}>>; /**
|
|
4484
|
+
* @template Params
|
|
4485
|
+
* @template RequestBody
|
|
4486
|
+
* @template Response
|
|
4487
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4488
|
+
*/
|
|
4489
|
+
}, "strip", z.ZodTypeAny, {
|
|
4490
|
+
body?: any;
|
|
4491
|
+
init?: {
|
|
4492
|
+
status?: number | undefined;
|
|
4493
|
+
statusText?: string | undefined;
|
|
4494
|
+
headers?: any;
|
|
4495
|
+
} | undefined;
|
|
4496
|
+
}, {
|
|
4497
|
+
body?: any;
|
|
4498
|
+
init?: {
|
|
4499
|
+
status?: number | undefined;
|
|
4500
|
+
statusText?: string | undefined;
|
|
4501
|
+
headers?: any;
|
|
4502
|
+
} | undefined;
|
|
4503
|
+
}>>>;
|
|
4504
|
+
export function putApiFunctionSchema(requestBodySchema: any): z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4505
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4506
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4507
|
+
body: any;
|
|
4508
|
+
}, "strip", z.ZodTypeAny, {
|
|
4509
|
+
params: Record<string, string>;
|
|
4510
|
+
searchParams: Record<string, string | string[]>;
|
|
4511
|
+
body?: any;
|
|
4512
|
+
}, {
|
|
4513
|
+
params: Record<string, string>;
|
|
4514
|
+
searchParams: Record<string, string | string[]>;
|
|
4515
|
+
body?: any;
|
|
4516
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4517
|
+
body: z.ZodAny;
|
|
4518
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4519
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4520
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4521
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4522
|
+
}, "strip", z.ZodTypeAny, {
|
|
4523
|
+
status?: number | undefined;
|
|
4524
|
+
statusText?: string | undefined;
|
|
4525
|
+
headers?: any;
|
|
4526
|
+
}, {
|
|
4527
|
+
status?: number | undefined;
|
|
4528
|
+
statusText?: string | undefined;
|
|
4529
|
+
headers?: any;
|
|
4530
|
+
}>>; /**
|
|
4531
|
+
* @template Params
|
|
4532
|
+
* @template RequestBody
|
|
4533
|
+
* @template Response
|
|
4534
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4535
|
+
*/
|
|
4536
|
+
}, "strip", z.ZodTypeAny, {
|
|
4537
|
+
body?: any;
|
|
4538
|
+
init?: {
|
|
4539
|
+
status?: number | undefined;
|
|
4540
|
+
statusText?: string | undefined;
|
|
4541
|
+
headers?: any;
|
|
4542
|
+
} | undefined;
|
|
4543
|
+
}, {
|
|
4544
|
+
body?: any;
|
|
4545
|
+
init?: {
|
|
4546
|
+
status?: number | undefined;
|
|
4547
|
+
statusText?: string | undefined;
|
|
4548
|
+
headers?: any;
|
|
4549
|
+
} | undefined;
|
|
4550
|
+
}>>>;
|
|
4551
|
+
export function patchApiFunctionSchema(requestBodySchema: any): z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4552
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4553
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4554
|
+
body: any;
|
|
4555
|
+
}, "strip", z.ZodTypeAny, {
|
|
4556
|
+
params: Record<string, string>;
|
|
4557
|
+
searchParams: Record<string, string | string[]>;
|
|
4558
|
+
body?: any;
|
|
4559
|
+
}, {
|
|
4560
|
+
params: Record<string, string>;
|
|
4561
|
+
searchParams: Record<string, string | string[]>;
|
|
4562
|
+
body?: any;
|
|
4563
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4564
|
+
body: z.ZodAny;
|
|
4565
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4566
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4567
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4568
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4569
|
+
}, "strip", z.ZodTypeAny, {
|
|
4570
|
+
status?: number | undefined;
|
|
4571
|
+
statusText?: string | undefined;
|
|
4572
|
+
headers?: any;
|
|
4573
|
+
}, {
|
|
4574
|
+
status?: number | undefined;
|
|
4575
|
+
statusText?: string | undefined;
|
|
4576
|
+
headers?: any;
|
|
4577
|
+
}>>; /**
|
|
4578
|
+
* @template Params
|
|
4579
|
+
* @template RequestBody
|
|
4580
|
+
* @template Response
|
|
4581
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4582
|
+
*/
|
|
4583
|
+
}, "strip", z.ZodTypeAny, {
|
|
4584
|
+
body?: any;
|
|
4585
|
+
init?: {
|
|
4586
|
+
status?: number | undefined;
|
|
4587
|
+
statusText?: string | undefined;
|
|
4588
|
+
headers?: any;
|
|
4589
|
+
} | undefined;
|
|
4590
|
+
}, {
|
|
4591
|
+
body?: any;
|
|
4592
|
+
init?: {
|
|
4593
|
+
status?: number | undefined;
|
|
4594
|
+
statusText?: string | undefined;
|
|
4595
|
+
headers?: any;
|
|
4596
|
+
} | undefined;
|
|
4597
|
+
}>>>;
|
|
4598
|
+
|
|
4599
|
+
export const deleteApiFunctionSchema: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
|
|
4600
|
+
searchParams: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>;
|
|
4601
|
+
params: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
4602
|
+
}, "strip", z.ZodTypeAny, {
|
|
4603
|
+
params: Record<string, string>;
|
|
4604
|
+
searchParams: Record<string, string | string[]>;
|
|
4605
|
+
}, {
|
|
4606
|
+
params: Record<string, string>;
|
|
4607
|
+
searchParams: Record<string, string | string[]>;
|
|
4608
|
+
}>], z.ZodUnknown>, z.ZodPromise<z.ZodObject<{
|
|
4609
|
+
body: z.ZodAny;
|
|
4610
|
+
init: z.ZodOptional<z.ZodObject<{
|
|
4611
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
4612
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
4613
|
+
headers: z.ZodOptional<z.ZodAny>;
|
|
4614
|
+
}, "strip", z.ZodTypeAny, {
|
|
4615
|
+
status?: number | undefined;
|
|
4616
|
+
statusText?: string | undefined;
|
|
4617
|
+
headers?: any;
|
|
4618
|
+
}, {
|
|
4619
|
+
status?: number | undefined;
|
|
4620
|
+
statusText?: string | undefined;
|
|
4621
|
+
headers?: any;
|
|
4622
|
+
}>>; /**
|
|
4623
|
+
* @template Params
|
|
4624
|
+
* @template RequestBody
|
|
4625
|
+
* @template Response
|
|
4626
|
+
* @typedef {function(IApiFunctionParams & {body: Partial<RequestBody>}): Promise<EventResponse<Response>>} IPatchApiFunction
|
|
4627
|
+
*/
|
|
4628
|
+
}, "strip", z.ZodTypeAny, {
|
|
4629
|
+
body?: any;
|
|
4630
|
+
init?: {
|
|
4631
|
+
status?: number | undefined;
|
|
4632
|
+
statusText?: string | undefined;
|
|
4633
|
+
headers?: any;
|
|
4634
|
+
} | undefined;
|
|
4635
|
+
}, {
|
|
4636
|
+
body?: any;
|
|
4637
|
+
init?: {
|
|
4638
|
+
status?: number | undefined;
|
|
4639
|
+
statusText?: string | undefined;
|
|
4640
|
+
headers?: any;
|
|
4641
|
+
} | undefined;
|
|
4642
|
+
}>>>;
|
|
4643
|
+
export type IApiFunctionParams = {
|
|
4644
|
+
searchParams: {
|
|
4645
|
+
[x: string]: string | string[];
|
|
4646
|
+
};
|
|
4647
|
+
params: Record<string, string>;
|
|
4648
|
+
};
|
|
4649
|
+
export type IApiEntityFunctionParams = IApiFunctionParams & {
|
|
4650
|
+
id: string;
|
|
4651
|
+
};
|
|
4652
|
+
export type IApiFunction<Params, Response_1> = (arg0: IApiFunctionParams) => Promise<EventResponse<any>>;
|
|
4653
|
+
export type IQueryApiFunction<Params, Response_1> = IApiFunction<Params, Response>;
|
|
4654
|
+
export type GetApiFunction<Params, Response_1> = IApiFunction<Params, Response>;
|
|
4655
|
+
export type IPostApiFunction<Params, RequestBody, Response_1> = (arg0: IApiFunctionParams & {
|
|
4656
|
+
body: Partial<RequestBody>;
|
|
4657
|
+
}) => Promise<EventResponse<Response>>;
|
|
4658
|
+
export type IPutApiFunction<Params, RequestBody, Response_1> = (arg0: IApiFunctionParams & {
|
|
4659
|
+
body: Partial<RequestBody>;
|
|
4660
|
+
}) => Promise<EventResponse<Response>>;
|
|
4661
|
+
export type IPatchApiFunction<Params, RequestBody, Response_1> = (arg0: IApiFunctionParams & {
|
|
4662
|
+
body: Partial<RequestBody>;
|
|
4663
|
+
}) => Promise<EventResponse<Response>>;
|
|
4664
|
+
export type IDeleteApiFunction<Params, Response_1> = IApiFunction<Params, Response>;
|
|
3003
4665
|
}
|
|
3004
4666
|
|
|
3005
4667
|
declare module '@scout9/app/spirits' {
|