@kl1/contracts 1.2.84-uat → 1.2.86-uat
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/api-contracts/src/contract.d.ts +1670 -84
- package/dist/api-contracts/src/contract.d.ts.map +1 -1
- package/dist/api-contracts/src/dashboard/index.d.ts +56 -9
- package/dist/api-contracts/src/dashboard/index.d.ts.map +1 -1
- package/dist/api-contracts/src/dashboard/validation.d.ts +13 -0
- package/dist/api-contracts/src/dashboard/validation.d.ts.map +1 -1
- package/dist/api-contracts/src/widget/index.d.ts +813 -39
- package/dist/api-contracts/src/widget/index.d.ts.map +1 -1
- package/dist/api-contracts/src/widget/schema.d.ts +98 -4
- package/dist/api-contracts/src/widget/schema.d.ts.map +1 -1
- package/dist/api-contracts/src/widget/validation.d.ts +171 -12
- package/dist/api-contracts/src/widget/validation.d.ts.map +1 -1
- package/dist/index.js +60 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +60 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/widget/index.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAQpB,OAAO,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/widget/index.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAC;AAQpB,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,YAAY,EACZ,gBAAgB,EACjB,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,kBAAkB,EAClB,2BAA2B,EAC3B,kBAAkB,EACnB,MAAM,cAAc,CAAC;AAGtB,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AACrE,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AACrE,MAAM,MAAM,wB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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwJ1B,CAAC"}
|
@@ -1,5 +1,17 @@
|
|
1
1
|
import z from 'zod';
|
2
|
-
export declare const WidgetPositionSchema: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">]>;
|
2
|
+
export declare const WidgetPositionSchema: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">, z.ZodLiteral<"contact_profile">, z.ZodLiteral<"inbox_detail">]>;
|
3
|
+
export declare const WidgetTypeSchema: z.ZodUnion<[z.ZodLiteral<"iframe">, z.ZodLiteral<"custom">]>;
|
4
|
+
export declare const WidgetHeaderSchema: z.ZodObject<{
|
5
|
+
key: z.ZodString;
|
6
|
+
value: z.ZodString;
|
7
|
+
}, "strip", z.ZodTypeAny, {
|
8
|
+
key: string;
|
9
|
+
value: string;
|
10
|
+
}, {
|
11
|
+
key: string;
|
12
|
+
value: string;
|
13
|
+
}>;
|
14
|
+
export declare const WidgetMethodSchema: z.ZodUnion<[z.ZodLiteral<"get">, z.ZodLiteral<"post">]>;
|
3
15
|
export declare const WidgetSchema: z.ZodObject<{
|
4
16
|
id: z.ZodString;
|
5
17
|
createdAt: z.ZodDate;
|
@@ -7,7 +19,7 @@ export declare const WidgetSchema: z.ZodObject<{
|
|
7
19
|
deletedAt: z.ZodNullable<z.ZodDate>;
|
8
20
|
name: z.ZodString;
|
9
21
|
description: z.ZodNullable<z.ZodString>;
|
10
|
-
position: z.
|
22
|
+
position: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">, z.ZodLiteral<"contact_profile">, z.ZodLiteral<"inbox_detail">]>;
|
11
23
|
fields: z.ZodObject<{
|
12
24
|
data: z.ZodArray<z.ZodString, "many">;
|
13
25
|
}, "strip", z.ZodTypeAny, {
|
@@ -16,27 +28,109 @@ export declare const WidgetSchema: z.ZodObject<{
|
|
16
28
|
data: string[];
|
17
29
|
}>;
|
18
30
|
url: z.ZodString;
|
31
|
+
upload: z.ZodNullable<z.ZodObject<{
|
32
|
+
id: z.ZodString;
|
33
|
+
createdAt: z.ZodDate;
|
34
|
+
updatedAt: z.ZodDate;
|
35
|
+
deletedAt: z.ZodNullable<z.ZodDate>;
|
36
|
+
bucketName: z.ZodString;
|
37
|
+
fileName: z.ZodString;
|
38
|
+
fileSize: z.ZodNumber;
|
39
|
+
fileKey: z.ZodString;
|
40
|
+
fileUrl: z.ZodNullable<z.ZodString>;
|
41
|
+
status: z.ZodNullable<z.ZodString>;
|
42
|
+
}, "strip", z.ZodTypeAny, {
|
43
|
+
id: string;
|
44
|
+
status: string | null;
|
45
|
+
createdAt: Date;
|
46
|
+
updatedAt: Date;
|
47
|
+
deletedAt: Date | null;
|
48
|
+
fileName: string;
|
49
|
+
fileKey: string;
|
50
|
+
bucketName: string;
|
51
|
+
fileSize: number;
|
52
|
+
fileUrl: string | null;
|
53
|
+
}, {
|
54
|
+
id: string;
|
55
|
+
status: string | null;
|
56
|
+
createdAt: Date;
|
57
|
+
updatedAt: Date;
|
58
|
+
deletedAt: Date | null;
|
59
|
+
fileName: string;
|
60
|
+
fileKey: string;
|
61
|
+
bucketName: string;
|
62
|
+
fileSize: number;
|
63
|
+
fileUrl: string | null;
|
64
|
+
}>>;
|
65
|
+
type: z.ZodNullable<z.ZodUnion<[z.ZodLiteral<"iframe">, z.ZodLiteral<"custom">]>>;
|
66
|
+
headers: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
67
|
+
key: z.ZodString;
|
68
|
+
value: z.ZodString;
|
69
|
+
}, "strip", z.ZodTypeAny, {
|
70
|
+
key: string;
|
71
|
+
value: string;
|
72
|
+
}, {
|
73
|
+
key: string;
|
74
|
+
value: string;
|
75
|
+
}>, "many">>;
|
76
|
+
method: z.ZodNullable<z.ZodUnion<[z.ZodLiteral<"get">, z.ZodLiteral<"post">]>>;
|
19
77
|
}, "strip", z.ZodTypeAny, {
|
20
78
|
name: string;
|
79
|
+
type: "custom" | "iframe" | null;
|
21
80
|
id: string;
|
22
81
|
url: string;
|
23
|
-
position: "menu" | "ticket_detail" | "contact_detail" |
|
82
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
83
|
+
method: "get" | "post" | null;
|
24
84
|
description: string | null;
|
25
85
|
createdAt: Date;
|
26
86
|
updatedAt: Date;
|
27
87
|
deletedAt: Date | null;
|
88
|
+
headers: {
|
89
|
+
key: string;
|
90
|
+
value: string;
|
91
|
+
}[] | null;
|
92
|
+
upload: {
|
93
|
+
id: string;
|
94
|
+
status: string | null;
|
95
|
+
createdAt: Date;
|
96
|
+
updatedAt: Date;
|
97
|
+
deletedAt: Date | null;
|
98
|
+
fileName: string;
|
99
|
+
fileKey: string;
|
100
|
+
bucketName: string;
|
101
|
+
fileSize: number;
|
102
|
+
fileUrl: string | null;
|
103
|
+
} | null;
|
28
104
|
fields: {
|
29
105
|
data: string[];
|
30
106
|
};
|
31
107
|
}, {
|
32
108
|
name: string;
|
109
|
+
type: "custom" | "iframe" | null;
|
33
110
|
id: string;
|
34
111
|
url: string;
|
35
|
-
position: "menu" | "ticket_detail" | "contact_detail" |
|
112
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
113
|
+
method: "get" | "post" | null;
|
36
114
|
description: string | null;
|
37
115
|
createdAt: Date;
|
38
116
|
updatedAt: Date;
|
39
117
|
deletedAt: Date | null;
|
118
|
+
headers: {
|
119
|
+
key: string;
|
120
|
+
value: string;
|
121
|
+
}[] | null;
|
122
|
+
upload: {
|
123
|
+
id: string;
|
124
|
+
status: string | null;
|
125
|
+
createdAt: Date;
|
126
|
+
updatedAt: Date;
|
127
|
+
deletedAt: Date | null;
|
128
|
+
fileName: string;
|
129
|
+
fileKey: string;
|
130
|
+
bucketName: string;
|
131
|
+
fileSize: number;
|
132
|
+
fileUrl: string | null;
|
133
|
+
} | null;
|
40
134
|
fields: {
|
41
135
|
data: string[];
|
42
136
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../src/widget/schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../src/widget/schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAOpB,eAAO,MAAM,oBAAoB,kKAM/B,CAAC;AAEH,eAAO,MAAM,gBAAgB,8DAG3B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;EAG7B,CAAC;AAEH,eAAO,MAAM,kBAAkB,yDAG7B,CAAC;AAEH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUvB,CAAC"}
|
@@ -1,9 +1,34 @@
|
|
1
1
|
import z from 'zod';
|
2
|
+
export declare const WidgetUploadAttachmentSchema: z.ZodObject<{
|
3
|
+
bucketName: z.ZodString;
|
4
|
+
fileKey: z.ZodString;
|
5
|
+
fileName: z.ZodString;
|
6
|
+
fileSize: z.ZodNumber;
|
7
|
+
url: z.ZodNullable<z.ZodString>;
|
8
|
+
fileType: z.ZodString;
|
9
|
+
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
10
|
+
}, "strip", z.ZodTypeAny, {
|
11
|
+
url: string | null;
|
12
|
+
fileName: string;
|
13
|
+
fileType: string;
|
14
|
+
fileKey: string;
|
15
|
+
bucketName: string;
|
16
|
+
fileSize: number;
|
17
|
+
thumbnailUrl?: string | undefined;
|
18
|
+
}, {
|
19
|
+
url: string | null;
|
20
|
+
fileName: string;
|
21
|
+
fileType: string;
|
22
|
+
fileKey: string;
|
23
|
+
bucketName: string;
|
24
|
+
fileSize: number;
|
25
|
+
thumbnailUrl?: string | undefined;
|
26
|
+
}>;
|
2
27
|
export declare const CreateWidgetSchema: z.ZodObject<{
|
3
28
|
name: z.ZodString;
|
4
|
-
description: z.ZodString
|
29
|
+
description: z.ZodOptional<z.ZodString>;
|
5
30
|
url: z.ZodString;
|
6
|
-
position: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">]>;
|
31
|
+
position: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">, z.ZodLiteral<"contact_profile">, z.ZodLiteral<"inbox_detail">]>;
|
7
32
|
fields: z.ZodOptional<z.ZodObject<{
|
8
33
|
data: z.ZodArray<z.ZodString, "many">;
|
9
34
|
}, "strip", z.ZodTypeAny, {
|
@@ -11,28 +36,95 @@ export declare const CreateWidgetSchema: z.ZodObject<{
|
|
11
36
|
}, {
|
12
37
|
data: string[];
|
13
38
|
}>>;
|
39
|
+
widgetUploadAttachment: z.ZodOptional<z.ZodObject<{
|
40
|
+
bucketName: z.ZodString;
|
41
|
+
fileKey: z.ZodString;
|
42
|
+
fileName: z.ZodString;
|
43
|
+
fileSize: z.ZodNumber;
|
44
|
+
url: z.ZodNullable<z.ZodString>;
|
45
|
+
fileType: z.ZodString;
|
46
|
+
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
47
|
+
}, "strip", z.ZodTypeAny, {
|
48
|
+
url: string | null;
|
49
|
+
fileName: string;
|
50
|
+
fileType: string;
|
51
|
+
fileKey: string;
|
52
|
+
bucketName: string;
|
53
|
+
fileSize: number;
|
54
|
+
thumbnailUrl?: string | undefined;
|
55
|
+
}, {
|
56
|
+
url: string | null;
|
57
|
+
fileName: string;
|
58
|
+
fileType: string;
|
59
|
+
fileKey: string;
|
60
|
+
bucketName: string;
|
61
|
+
fileSize: number;
|
62
|
+
thumbnailUrl?: string | undefined;
|
63
|
+
}>>;
|
64
|
+
type: z.ZodUnion<[z.ZodLiteral<"iframe">, z.ZodLiteral<"custom">]>;
|
65
|
+
headers: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
66
|
+
key: z.ZodString;
|
67
|
+
value: z.ZodString;
|
68
|
+
}, "strip", z.ZodTypeAny, {
|
69
|
+
key: string;
|
70
|
+
value: string;
|
71
|
+
}, {
|
72
|
+
key: string;
|
73
|
+
value: string;
|
74
|
+
}>, "many">>;
|
75
|
+
method: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"get">, z.ZodLiteral<"post">]>>;
|
14
76
|
}, "strip", z.ZodTypeAny, {
|
15
77
|
name: string;
|
78
|
+
type: "custom" | "iframe";
|
16
79
|
url: string;
|
17
|
-
position: "menu" | "ticket_detail" | "contact_detail";
|
18
|
-
description
|
80
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
81
|
+
description?: string | undefined;
|
19
82
|
fields?: {
|
20
83
|
data: string[];
|
21
84
|
} | undefined;
|
85
|
+
widgetUploadAttachment?: {
|
86
|
+
url: string | null;
|
87
|
+
fileName: string;
|
88
|
+
fileType: string;
|
89
|
+
fileKey: string;
|
90
|
+
bucketName: string;
|
91
|
+
fileSize: number;
|
92
|
+
thumbnailUrl?: string | undefined;
|
93
|
+
} | undefined;
|
94
|
+
headers?: {
|
95
|
+
key: string;
|
96
|
+
value: string;
|
97
|
+
}[] | undefined;
|
98
|
+
method?: "get" | "post" | undefined;
|
22
99
|
}, {
|
23
100
|
name: string;
|
101
|
+
type: "custom" | "iframe";
|
24
102
|
url: string;
|
25
|
-
position: "menu" | "ticket_detail" | "contact_detail";
|
26
|
-
description
|
103
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
104
|
+
description?: string | undefined;
|
27
105
|
fields?: {
|
28
106
|
data: string[];
|
29
107
|
} | undefined;
|
108
|
+
widgetUploadAttachment?: {
|
109
|
+
url: string | null;
|
110
|
+
fileName: string;
|
111
|
+
fileType: string;
|
112
|
+
fileKey: string;
|
113
|
+
bucketName: string;
|
114
|
+
fileSize: number;
|
115
|
+
thumbnailUrl?: string | undefined;
|
116
|
+
} | undefined;
|
117
|
+
headers?: {
|
118
|
+
key: string;
|
119
|
+
value: string;
|
120
|
+
}[] | undefined;
|
121
|
+
method?: "get" | "post" | undefined;
|
30
122
|
}>;
|
31
123
|
export declare const UpdateWidgetSchema: z.ZodObject<{
|
32
124
|
name: z.ZodString;
|
33
|
-
description: z.ZodString
|
125
|
+
description: z.ZodOptional<z.ZodString>;
|
34
126
|
url: z.ZodString;
|
35
|
-
position: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">]>;
|
127
|
+
position: z.ZodUnion<[z.ZodLiteral<"menu">, z.ZodLiteral<"ticket_detail">, z.ZodLiteral<"contact_detail">, z.ZodLiteral<"contact_profile">, z.ZodLiteral<"inbox_detail">]>;
|
36
128
|
fields: z.ZodOptional<z.ZodObject<{
|
37
129
|
data: z.ZodArray<z.ZodString, "many">;
|
38
130
|
}, "strip", z.ZodTypeAny, {
|
@@ -40,22 +132,89 @@ export declare const UpdateWidgetSchema: z.ZodObject<{
|
|
40
132
|
}, {
|
41
133
|
data: string[];
|
42
134
|
}>>;
|
135
|
+
widgetUploadAttachment: z.ZodOptional<z.ZodObject<{
|
136
|
+
bucketName: z.ZodString;
|
137
|
+
fileKey: z.ZodString;
|
138
|
+
fileName: z.ZodString;
|
139
|
+
fileSize: z.ZodNumber;
|
140
|
+
url: z.ZodNullable<z.ZodString>;
|
141
|
+
fileType: z.ZodString;
|
142
|
+
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
143
|
+
}, "strip", z.ZodTypeAny, {
|
144
|
+
url: string | null;
|
145
|
+
fileName: string;
|
146
|
+
fileType: string;
|
147
|
+
fileKey: string;
|
148
|
+
bucketName: string;
|
149
|
+
fileSize: number;
|
150
|
+
thumbnailUrl?: string | undefined;
|
151
|
+
}, {
|
152
|
+
url: string | null;
|
153
|
+
fileName: string;
|
154
|
+
fileType: string;
|
155
|
+
fileKey: string;
|
156
|
+
bucketName: string;
|
157
|
+
fileSize: number;
|
158
|
+
thumbnailUrl?: string | undefined;
|
159
|
+
}>>;
|
160
|
+
type: z.ZodUnion<[z.ZodLiteral<"iframe">, z.ZodLiteral<"custom">]>;
|
161
|
+
headers: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
162
|
+
key: z.ZodString;
|
163
|
+
value: z.ZodString;
|
164
|
+
}, "strip", z.ZodTypeAny, {
|
165
|
+
key: string;
|
166
|
+
value: string;
|
167
|
+
}, {
|
168
|
+
key: string;
|
169
|
+
value: string;
|
170
|
+
}>, "many">>;
|
171
|
+
method: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"get">, z.ZodLiteral<"post">]>>;
|
43
172
|
}, "strip", z.ZodTypeAny, {
|
44
173
|
name: string;
|
174
|
+
type: "custom" | "iframe";
|
45
175
|
url: string;
|
46
|
-
position: "menu" | "ticket_detail" | "contact_detail";
|
47
|
-
description
|
176
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
177
|
+
description?: string | undefined;
|
48
178
|
fields?: {
|
49
179
|
data: string[];
|
50
180
|
} | undefined;
|
181
|
+
widgetUploadAttachment?: {
|
182
|
+
url: string | null;
|
183
|
+
fileName: string;
|
184
|
+
fileType: string;
|
185
|
+
fileKey: string;
|
186
|
+
bucketName: string;
|
187
|
+
fileSize: number;
|
188
|
+
thumbnailUrl?: string | undefined;
|
189
|
+
} | undefined;
|
190
|
+
headers?: {
|
191
|
+
key: string;
|
192
|
+
value: string;
|
193
|
+
}[] | undefined;
|
194
|
+
method?: "get" | "post" | undefined;
|
51
195
|
}, {
|
52
196
|
name: string;
|
197
|
+
type: "custom" | "iframe";
|
53
198
|
url: string;
|
54
|
-
position: "menu" | "ticket_detail" | "contact_detail";
|
55
|
-
description
|
199
|
+
position: "menu" | "ticket_detail" | "contact_detail" | "contact_profile" | "inbox_detail";
|
200
|
+
description?: string | undefined;
|
56
201
|
fields?: {
|
57
202
|
data: string[];
|
58
203
|
} | undefined;
|
204
|
+
widgetUploadAttachment?: {
|
205
|
+
url: string | null;
|
206
|
+
fileName: string;
|
207
|
+
fileType: string;
|
208
|
+
fileKey: string;
|
209
|
+
bucketName: string;
|
210
|
+
fileSize: number;
|
211
|
+
thumbnailUrl?: string | undefined;
|
212
|
+
} | undefined;
|
213
|
+
headers?: {
|
214
|
+
key: string;
|
215
|
+
value: string;
|
216
|
+
}[] | undefined;
|
217
|
+
method?: "get" | "post" | undefined;
|
59
218
|
}>;
|
60
219
|
export declare const GetWidgetUrlPathQuerySchema: z.ZodObject<{
|
61
220
|
widgetId: z.ZodString;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"validation.d.ts","sourceRoot":"","sources":["../../../../src/widget/validation.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;
|
1
|
+
{"version":3,"file":"validation.d.ts","sourceRoot":"","sources":["../../../../src/widget/validation.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAQpB,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;EAQvC,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiB7B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAqB,CAAC;AAErD,eAAO,MAAM,2BAA2B;;;;;;;;;EAKtC,CAAC"}
|
package/dist/index.js
CHANGED
@@ -4271,12 +4271,17 @@ var import_core13 = require("@ts-rest/core");
|
|
4271
4271
|
var import_zod53 = __toESM(require("zod"));
|
4272
4272
|
var GetDashboardQueryParamsSchema = import_zod53.default.object({
|
4273
4273
|
channelIds: import_zod53.default.array(import_zod53.default.string().uuid()).optional(),
|
4274
|
-
selectedDate: import_zod53.default.string()
|
4274
|
+
selectedDate: import_zod53.default.string().min(1)
|
4275
4275
|
});
|
4276
4276
|
var GetMessageChannelQueryParamsSchema = GetDashboardQueryParamsSchema.extend({
|
4277
4277
|
time: import_zod53.default.enum(["byDay", "byMonth", "byHour"]),
|
4278
4278
|
channelIds: import_zod53.default.array(import_zod53.default.string()).optional()
|
4279
4279
|
});
|
4280
|
+
var DashboardGlobalFiltersSchema = import_zod53.default.object({
|
4281
|
+
automationQueueId: import_zod53.default.string().uuid().optional(),
|
4282
|
+
selectedDate: import_zod53.default.string().min(1),
|
4283
|
+
channelIds: import_zod53.default.array(import_zod53.default.string().uuid()).optional()
|
4284
|
+
});
|
4280
4285
|
var DashboardQueryParamsSchema = GetDashboardQueryParamsSchema.extend({
|
4281
4286
|
automationQueueId: import_zod53.default.string().uuid().optional(),
|
4282
4287
|
channelIds: import_zod53.default.array(import_zod53.default.string().uuid()).optional(),
|
@@ -4761,7 +4766,7 @@ var dashboardContract = (0, import_core13.initContract)().router(
|
|
4761
4766
|
method: "GET",
|
4762
4767
|
path: "/message/platform",
|
4763
4768
|
summary: "Get message platform data",
|
4764
|
-
query:
|
4769
|
+
query: DashboardGlobalFiltersSchema,
|
4765
4770
|
headers: DefaultHeaderSchema,
|
4766
4771
|
responses: {
|
4767
4772
|
200: DefaultSuccessResponseSchema.extend({
|
@@ -4770,6 +4775,14 @@ var dashboardContract = (0, import_core13.initContract)().router(
|
|
4770
4775
|
401: DefaultUnauthorizedSchema
|
4771
4776
|
}
|
4772
4777
|
},
|
4778
|
+
exportRoomChannelCounts: {
|
4779
|
+
method: "GET",
|
4780
|
+
path: "/export-room-channel-counts",
|
4781
|
+
query: DashboardGlobalFiltersSchema,
|
4782
|
+
responses: {
|
4783
|
+
200: DefaultSuccessResponseSchema
|
4784
|
+
}
|
4785
|
+
},
|
4773
4786
|
getMessageRoomStatusDispositionData: {
|
4774
4787
|
method: "GET",
|
4775
4788
|
path: "/message/disposition",
|
@@ -4804,7 +4817,7 @@ var dashboardContract = (0, import_core13.initContract)().router(
|
|
4804
4817
|
method: "GET",
|
4805
4818
|
path: "/message/total-incoming",
|
4806
4819
|
summary: "Get total incoming message data",
|
4807
|
-
query:
|
4820
|
+
query: DashboardGlobalFiltersSchema,
|
4808
4821
|
headers: DefaultHeaderSchema,
|
4809
4822
|
responses: {
|
4810
4823
|
200: DefaultSuccessResponseSchema.extend({
|
@@ -4813,6 +4826,14 @@ var dashboardContract = (0, import_core13.initContract)().router(
|
|
4813
4826
|
401: DefaultUnauthorizedSchema
|
4814
4827
|
}
|
4815
4828
|
},
|
4829
|
+
exportIncomingMessageCounts: {
|
4830
|
+
method: "GET",
|
4831
|
+
path: "/export-incoming-message-counts",
|
4832
|
+
query: DashboardGlobalFiltersSchema,
|
4833
|
+
responses: {
|
4834
|
+
200: DefaultSuccessResponseSchema
|
4835
|
+
}
|
4836
|
+
},
|
4816
4837
|
getCallCounts: {
|
4817
4838
|
method: "GET",
|
4818
4839
|
path: "/call-counts",
|
@@ -6955,21 +6976,48 @@ var FieldsSchema = import_zod85.default.object({ data: import_zod85.default.arra
|
|
6955
6976
|
var WidgetPositionSchema = import_zod85.default.union([
|
6956
6977
|
import_zod85.default.literal("menu"),
|
6957
6978
|
import_zod85.default.literal("ticket_detail"),
|
6958
|
-
import_zod85.default.literal("contact_detail")
|
6979
|
+
import_zod85.default.literal("contact_detail"),
|
6980
|
+
import_zod85.default.literal("contact_profile"),
|
6981
|
+
import_zod85.default.literal("inbox_detail")
|
6982
|
+
]);
|
6983
|
+
var WidgetTypeSchema = import_zod85.default.union([
|
6984
|
+
import_zod85.default.literal("iframe"),
|
6985
|
+
import_zod85.default.literal("custom")
|
6986
|
+
]);
|
6987
|
+
var WidgetHeaderSchema = import_zod85.default.object({
|
6988
|
+
key: import_zod85.default.string(),
|
6989
|
+
value: import_zod85.default.string()
|
6990
|
+
});
|
6991
|
+
var WidgetMethodSchema = import_zod85.default.union([
|
6992
|
+
import_zod85.default.literal("get"),
|
6993
|
+
import_zod85.default.literal("post")
|
6959
6994
|
]);
|
6960
6995
|
var WidgetSchema = DefaultEntitySchema.extend({
|
6961
6996
|
name: import_zod85.default.string(),
|
6962
6997
|
description: import_zod85.default.string().nullable(),
|
6963
|
-
position: WidgetPositionSchema
|
6998
|
+
position: WidgetPositionSchema,
|
6964
6999
|
fields: FieldsSchema,
|
6965
|
-
url: import_zod85.default.string()
|
7000
|
+
url: import_zod85.default.string(),
|
7001
|
+
upload: UploadSchema.nullable(),
|
7002
|
+
type: WidgetTypeSchema.nullable(),
|
7003
|
+
headers: import_zod85.default.array(WidgetHeaderSchema).nullable(),
|
7004
|
+
method: WidgetMethodSchema.nullable()
|
6966
7005
|
});
|
6967
7006
|
|
6968
7007
|
// src/widget/validation.ts
|
6969
7008
|
var import_zod86 = __toESM(require("zod"));
|
7009
|
+
var WidgetUploadAttachmentSchema = import_zod86.default.object({
|
7010
|
+
bucketName: import_zod86.default.string(),
|
7011
|
+
fileKey: import_zod86.default.string(),
|
7012
|
+
fileName: import_zod86.default.string(),
|
7013
|
+
fileSize: import_zod86.default.number(),
|
7014
|
+
url: import_zod86.default.string().nullable(),
|
7015
|
+
fileType: import_zod86.default.string(),
|
7016
|
+
thumbnailUrl: import_zod86.default.string().optional()
|
7017
|
+
});
|
6970
7018
|
var CreateWidgetSchema = import_zod86.default.object({
|
6971
7019
|
name: import_zod86.default.string(),
|
6972
|
-
description: import_zod86.default.string(),
|
7020
|
+
description: import_zod86.default.string().optional(),
|
6973
7021
|
url: import_zod86.default.string(),
|
6974
7022
|
position: WidgetPositionSchema,
|
6975
7023
|
fields: import_zod86.default.object({
|
@@ -6977,7 +7025,11 @@ var CreateWidgetSchema = import_zod86.default.object({
|
|
6977
7025
|
// Array of attribute system names
|
6978
7026
|
import_zod86.default.array(import_zod86.default.string())
|
6979
7027
|
)
|
6980
|
-
}).optional()
|
7028
|
+
}).optional(),
|
7029
|
+
widgetUploadAttachment: WidgetUploadAttachmentSchema.optional(),
|
7030
|
+
type: WidgetTypeSchema,
|
7031
|
+
headers: import_zod86.default.array(WidgetHeaderSchema).optional(),
|
7032
|
+
method: WidgetMethodSchema.optional()
|
6981
7033
|
});
|
6982
7034
|
var UpdateWidgetSchema = CreateWidgetSchema;
|
6983
7035
|
var GetWidgetUrlPathQuerySchema = import_zod86.default.object({
|