@botpress/sdk 3.6.2 → 4.0.0
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/.turbo/turbo-build.log +4 -4
- package/dist/bot/client/types.d.ts +10 -9
- package/dist/bot/common/generic.d.ts +6 -1
- package/dist/bot/server/types.d.ts +2 -1
- package/dist/fixtures.d.ts +5 -2
- package/dist/index.cjs.map +2 -2
- package/dist/index.mjs.map +2 -2
- package/dist/integration/client/types.d.ts +10 -4
- package/dist/integration/common/generic.d.ts +6 -1
- package/dist/integration/definition/types.d.ts +2 -1
- package/dist/message.d.ts +44 -44
- package/dist/plugin/common/generic.d.ts +6 -1
- package/dist/utils/type-utils.d.ts +10 -0
- package/package.json +2 -2
|
@@ -96,26 +96,32 @@ export type UpdateUser<TIntegration extends common.BaseIntegration> = (x: utils.
|
|
|
96
96
|
export type DeleteUser<_TIntegration extends common.BaseIntegration> = client.Client['deleteUser'];
|
|
97
97
|
type StateResponse<TIntegration extends common.BaseIntegration, TState extends keyof TIntegration['states']> = {
|
|
98
98
|
state: utils.Merge<Awaited<Res<client.Client['getState']>>['state'], {
|
|
99
|
-
|
|
99
|
+
name: utils.Cast<TState, string>;
|
|
100
|
+
type: utils.Cast<TIntegration['states'][TState]['type'], string>;
|
|
101
|
+
payload: TIntegration['states'][TState]['payload'];
|
|
100
102
|
}>;
|
|
101
103
|
meta: {
|
|
102
104
|
cached: boolean;
|
|
103
105
|
};
|
|
104
106
|
};
|
|
105
107
|
export type GetState<TIntegration extends common.BaseIntegration> = <TState extends keyof TIntegration['states']>(x: utils.Merge<Arg<client.Client['getState']>, {
|
|
108
|
+
type: utils.Cast<TIntegration['states'][TState]['type'], string>;
|
|
106
109
|
name: utils.Cast<TState, string>;
|
|
107
110
|
}>) => Promise<StateResponse<TIntegration, TState>>;
|
|
108
111
|
export type SetState<TIntegration extends common.BaseIntegration> = <TState extends keyof TIntegration['states']>(x: utils.Merge<Arg<client.Client['setState']>, {
|
|
109
112
|
name: utils.Cast<TState, string>;
|
|
110
|
-
|
|
113
|
+
type: utils.Cast<TIntegration['states'][TState]['type'], string>;
|
|
114
|
+
payload: TIntegration['states'][TState]['payload'] | null;
|
|
111
115
|
}>) => Promise<StateResponse<TIntegration, TState>>;
|
|
112
116
|
export type GetOrSetState<TIntegration extends common.BaseIntegration> = <TState extends keyof TIntegration['states']>(x: utils.Merge<Arg<client.Client['getOrSetState']>, {
|
|
113
117
|
name: utils.Cast<TState, string>;
|
|
114
|
-
|
|
118
|
+
type: utils.Cast<TIntegration['states'][TState]['type'], string>;
|
|
119
|
+
payload: TIntegration['states'][TState]['payload'];
|
|
115
120
|
}>) => Promise<StateResponse<TIntegration, TState>>;
|
|
116
121
|
export type PatchState<TIntegration extends common.BaseIntegration> = <TState extends keyof TIntegration['states']>(x: utils.Merge<Arg<client.Client['patchState']>, {
|
|
117
122
|
name: utils.Cast<TState, string>;
|
|
118
|
-
|
|
123
|
+
type: utils.Cast<TIntegration['states'][TState]['type'], string>;
|
|
124
|
+
payload: Partial<TIntegration['states'][TState]['payload']>;
|
|
119
125
|
}>) => Promise<StateResponse<TIntegration, TState>>;
|
|
120
126
|
export type ConfigureIntegration<_TIntegration extends common.BaseIntegration> = client.Client['configureIntegration'];
|
|
121
127
|
export type UploadFile<_TIntegration extends common.BaseIntegration> = client.Client['uploadFile'];
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as utils from '../../utils/type-utils';
|
|
2
|
+
import * as def from '../definition';
|
|
2
3
|
export type BaseMessage = {
|
|
3
4
|
tags: Record<string, any>;
|
|
4
5
|
};
|
|
@@ -17,6 +18,10 @@ export type BaseAction = {
|
|
|
17
18
|
input: any;
|
|
18
19
|
output: any;
|
|
19
20
|
};
|
|
21
|
+
export type BaseState = {
|
|
22
|
+
type: def.StateType;
|
|
23
|
+
payload: any;
|
|
24
|
+
};
|
|
20
25
|
export type BaseIntegration = {
|
|
21
26
|
name: string;
|
|
22
27
|
version: string;
|
|
@@ -25,7 +30,7 @@ export type BaseIntegration = {
|
|
|
25
30
|
actions: Record<string, BaseAction>;
|
|
26
31
|
channels: Record<string, BaseChannel>;
|
|
27
32
|
events: Record<string, any>;
|
|
28
|
-
states: Record<string,
|
|
33
|
+
states: Record<string, BaseState>;
|
|
29
34
|
user: BaseUser;
|
|
30
35
|
entities: Record<string, any>;
|
|
31
36
|
};
|
|
@@ -48,8 +48,9 @@ export type ActionDefinition<TAction extends BaseActions[string] = BaseActions[s
|
|
|
48
48
|
billable?: boolean;
|
|
49
49
|
cacheable?: boolean;
|
|
50
50
|
};
|
|
51
|
+
export type StateType = 'integration' | 'conversation' | 'user';
|
|
51
52
|
export type StateDefinition<TState extends BaseStates[string] = BaseStates[string]> = SchemaDefinition<TState> & {
|
|
52
|
-
type:
|
|
53
|
+
type: StateType;
|
|
53
54
|
};
|
|
54
55
|
export type UserDefinition = Partial<{
|
|
55
56
|
tags: Record<string, TagDefinition>;
|
package/dist/message.d.ts
CHANGED
|
@@ -89,53 +89,53 @@ export declare const defaults: {
|
|
|
89
89
|
value: import("@bpinternal/zui").ZodString;
|
|
90
90
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
91
91
|
value: string;
|
|
92
|
-
action: "
|
|
92
|
+
action: "url" | "postback" | "say";
|
|
93
93
|
label: string;
|
|
94
94
|
}, {
|
|
95
95
|
value: string;
|
|
96
|
-
action: "
|
|
96
|
+
action: "url" | "postback" | "say";
|
|
97
97
|
label: string;
|
|
98
98
|
}>, "many">;
|
|
99
99
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
100
100
|
actions: {
|
|
101
101
|
value: string;
|
|
102
|
-
action: "
|
|
102
|
+
action: "url" | "postback" | "say";
|
|
103
103
|
label: string;
|
|
104
104
|
}[];
|
|
105
105
|
title: string;
|
|
106
|
-
imageUrl?: string | undefined;
|
|
107
106
|
subtitle?: string | undefined;
|
|
107
|
+
imageUrl?: string | undefined;
|
|
108
108
|
}, {
|
|
109
109
|
actions: {
|
|
110
110
|
value: string;
|
|
111
|
-
action: "
|
|
111
|
+
action: "url" | "postback" | "say";
|
|
112
112
|
label: string;
|
|
113
113
|
}[];
|
|
114
114
|
title: string;
|
|
115
|
-
imageUrl?: string | undefined;
|
|
116
115
|
subtitle?: string | undefined;
|
|
116
|
+
imageUrl?: string | undefined;
|
|
117
117
|
}>, "many">;
|
|
118
118
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
119
119
|
items: {
|
|
120
120
|
actions: {
|
|
121
121
|
value: string;
|
|
122
|
-
action: "
|
|
122
|
+
action: "url" | "postback" | "say";
|
|
123
123
|
label: string;
|
|
124
124
|
}[];
|
|
125
125
|
title: string;
|
|
126
|
-
imageUrl?: string | undefined;
|
|
127
126
|
subtitle?: string | undefined;
|
|
127
|
+
imageUrl?: string | undefined;
|
|
128
128
|
}[];
|
|
129
129
|
}, {
|
|
130
130
|
items: {
|
|
131
131
|
actions: {
|
|
132
132
|
value: string;
|
|
133
|
-
action: "
|
|
133
|
+
action: "url" | "postback" | "say";
|
|
134
134
|
label: string;
|
|
135
135
|
}[];
|
|
136
136
|
title: string;
|
|
137
|
-
imageUrl?: string | undefined;
|
|
138
137
|
subtitle?: string | undefined;
|
|
138
|
+
imageUrl?: string | undefined;
|
|
139
139
|
}[];
|
|
140
140
|
}>;
|
|
141
141
|
};
|
|
@@ -150,31 +150,31 @@ export declare const defaults: {
|
|
|
150
150
|
value: import("@bpinternal/zui").ZodString;
|
|
151
151
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
152
152
|
value: string;
|
|
153
|
-
action: "
|
|
153
|
+
action: "url" | "postback" | "say";
|
|
154
154
|
label: string;
|
|
155
155
|
}, {
|
|
156
156
|
value: string;
|
|
157
|
-
action: "
|
|
157
|
+
action: "url" | "postback" | "say";
|
|
158
158
|
label: string;
|
|
159
159
|
}>, "many">;
|
|
160
160
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
161
161
|
actions: {
|
|
162
162
|
value: string;
|
|
163
|
-
action: "
|
|
163
|
+
action: "url" | "postback" | "say";
|
|
164
164
|
label: string;
|
|
165
165
|
}[];
|
|
166
166
|
title: string;
|
|
167
|
-
imageUrl?: string | undefined;
|
|
168
167
|
subtitle?: string | undefined;
|
|
168
|
+
imageUrl?: string | undefined;
|
|
169
169
|
}, {
|
|
170
170
|
actions: {
|
|
171
171
|
value: string;
|
|
172
|
-
action: "
|
|
172
|
+
action: "url" | "postback" | "say";
|
|
173
173
|
label: string;
|
|
174
174
|
}[];
|
|
175
175
|
title: string;
|
|
176
|
-
imageUrl?: string | undefined;
|
|
177
176
|
subtitle?: string | undefined;
|
|
177
|
+
imageUrl?: string | undefined;
|
|
178
178
|
}>;
|
|
179
179
|
};
|
|
180
180
|
readonly dropdown: {
|
|
@@ -243,15 +243,15 @@ export declare const defaults: {
|
|
|
243
243
|
text: string;
|
|
244
244
|
}>;
|
|
245
245
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
246
|
-
type: "text";
|
|
247
246
|
payload: {
|
|
248
247
|
text: string;
|
|
249
248
|
};
|
|
250
|
-
}, {
|
|
251
249
|
type: "text";
|
|
250
|
+
}, {
|
|
252
251
|
payload: {
|
|
253
252
|
text: string;
|
|
254
253
|
};
|
|
254
|
+
type: "text";
|
|
255
255
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
256
256
|
type: import("@bpinternal/zui").ZodLiteral<"markdown">;
|
|
257
257
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -262,15 +262,15 @@ export declare const defaults: {
|
|
|
262
262
|
markdown: string;
|
|
263
263
|
}>;
|
|
264
264
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
265
|
-
type: "markdown";
|
|
266
265
|
payload: {
|
|
267
266
|
markdown: string;
|
|
268
267
|
};
|
|
269
|
-
}, {
|
|
270
268
|
type: "markdown";
|
|
269
|
+
}, {
|
|
271
270
|
payload: {
|
|
272
271
|
markdown: string;
|
|
273
272
|
};
|
|
273
|
+
type: "markdown";
|
|
274
274
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
275
275
|
type: import("@bpinternal/zui").ZodLiteral<"image">;
|
|
276
276
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -281,15 +281,15 @@ export declare const defaults: {
|
|
|
281
281
|
imageUrl: string;
|
|
282
282
|
}>;
|
|
283
283
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
284
|
-
type: "image";
|
|
285
284
|
payload: {
|
|
286
285
|
imageUrl: string;
|
|
287
286
|
};
|
|
288
|
-
}, {
|
|
289
287
|
type: "image";
|
|
288
|
+
}, {
|
|
290
289
|
payload: {
|
|
291
290
|
imageUrl: string;
|
|
292
291
|
};
|
|
292
|
+
type: "image";
|
|
293
293
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
294
294
|
type: import("@bpinternal/zui").ZodLiteral<"audio">;
|
|
295
295
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -300,15 +300,15 @@ export declare const defaults: {
|
|
|
300
300
|
audioUrl: string;
|
|
301
301
|
}>;
|
|
302
302
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
303
|
-
type: "audio";
|
|
304
303
|
payload: {
|
|
305
304
|
audioUrl: string;
|
|
306
305
|
};
|
|
307
|
-
}, {
|
|
308
306
|
type: "audio";
|
|
307
|
+
}, {
|
|
309
308
|
payload: {
|
|
310
309
|
audioUrl: string;
|
|
311
310
|
};
|
|
311
|
+
type: "audio";
|
|
312
312
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
313
313
|
type: import("@bpinternal/zui").ZodLiteral<"video">;
|
|
314
314
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -319,15 +319,15 @@ export declare const defaults: {
|
|
|
319
319
|
videoUrl: string;
|
|
320
320
|
}>;
|
|
321
321
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
322
|
-
type: "video";
|
|
323
322
|
payload: {
|
|
324
323
|
videoUrl: string;
|
|
325
324
|
};
|
|
326
|
-
}, {
|
|
327
325
|
type: "video";
|
|
326
|
+
}, {
|
|
328
327
|
payload: {
|
|
329
328
|
videoUrl: string;
|
|
330
329
|
};
|
|
330
|
+
type: "video";
|
|
331
331
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
332
332
|
type: import("@bpinternal/zui").ZodLiteral<"file">;
|
|
333
333
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -341,17 +341,17 @@ export declare const defaults: {
|
|
|
341
341
|
title?: string | undefined;
|
|
342
342
|
}>;
|
|
343
343
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
344
|
-
type: "file";
|
|
345
344
|
payload: {
|
|
346
345
|
fileUrl: string;
|
|
347
346
|
title?: string | undefined;
|
|
348
347
|
};
|
|
349
|
-
}, {
|
|
350
348
|
type: "file";
|
|
349
|
+
}, {
|
|
351
350
|
payload: {
|
|
352
351
|
fileUrl: string;
|
|
353
352
|
title?: string | undefined;
|
|
354
353
|
};
|
|
354
|
+
type: "file";
|
|
355
355
|
}>, import("@bpinternal/zui").ZodObject<{
|
|
356
356
|
type: import("@bpinternal/zui").ZodLiteral<"location">;
|
|
357
357
|
payload: import("@bpinternal/zui").ZodObject<{
|
|
@@ -371,103 +371,103 @@ export declare const defaults: {
|
|
|
371
371
|
address?: string | undefined;
|
|
372
372
|
}>;
|
|
373
373
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
374
|
-
type: "location";
|
|
375
374
|
payload: {
|
|
376
375
|
latitude: number;
|
|
377
376
|
longitude: number;
|
|
378
377
|
title?: string | undefined;
|
|
379
378
|
address?: string | undefined;
|
|
380
379
|
};
|
|
381
|
-
}, {
|
|
382
380
|
type: "location";
|
|
381
|
+
}, {
|
|
383
382
|
payload: {
|
|
384
383
|
latitude: number;
|
|
385
384
|
longitude: number;
|
|
386
385
|
title?: string | undefined;
|
|
387
386
|
address?: string | undefined;
|
|
388
387
|
};
|
|
388
|
+
type: "location";
|
|
389
389
|
}>]>, "many">;
|
|
390
390
|
}, "strip", import("@bpinternal/zui").ZodTypeAny, {
|
|
391
391
|
items: ({
|
|
392
|
-
type: "text";
|
|
393
392
|
payload: {
|
|
394
393
|
text: string;
|
|
395
394
|
};
|
|
395
|
+
type: "text";
|
|
396
396
|
} | {
|
|
397
|
-
type: "markdown";
|
|
398
397
|
payload: {
|
|
399
398
|
markdown: string;
|
|
400
399
|
};
|
|
400
|
+
type: "markdown";
|
|
401
401
|
} | {
|
|
402
|
-
type: "image";
|
|
403
402
|
payload: {
|
|
404
403
|
imageUrl: string;
|
|
405
404
|
};
|
|
405
|
+
type: "image";
|
|
406
406
|
} | {
|
|
407
|
-
type: "audio";
|
|
408
407
|
payload: {
|
|
409
408
|
audioUrl: string;
|
|
410
409
|
};
|
|
410
|
+
type: "audio";
|
|
411
411
|
} | {
|
|
412
|
-
type: "video";
|
|
413
412
|
payload: {
|
|
414
413
|
videoUrl: string;
|
|
415
414
|
};
|
|
415
|
+
type: "video";
|
|
416
416
|
} | {
|
|
417
|
-
type: "file";
|
|
418
417
|
payload: {
|
|
419
418
|
fileUrl: string;
|
|
420
419
|
title?: string | undefined;
|
|
421
420
|
};
|
|
421
|
+
type: "file";
|
|
422
422
|
} | {
|
|
423
|
-
type: "location";
|
|
424
423
|
payload: {
|
|
425
424
|
latitude: number;
|
|
426
425
|
longitude: number;
|
|
427
426
|
title?: string | undefined;
|
|
428
427
|
address?: string | undefined;
|
|
429
428
|
};
|
|
429
|
+
type: "location";
|
|
430
430
|
})[];
|
|
431
431
|
}, {
|
|
432
432
|
items: ({
|
|
433
|
-
type: "text";
|
|
434
433
|
payload: {
|
|
435
434
|
text: string;
|
|
436
435
|
};
|
|
436
|
+
type: "text";
|
|
437
437
|
} | {
|
|
438
|
-
type: "markdown";
|
|
439
438
|
payload: {
|
|
440
439
|
markdown: string;
|
|
441
440
|
};
|
|
441
|
+
type: "markdown";
|
|
442
442
|
} | {
|
|
443
|
-
type: "image";
|
|
444
443
|
payload: {
|
|
445
444
|
imageUrl: string;
|
|
446
445
|
};
|
|
446
|
+
type: "image";
|
|
447
447
|
} | {
|
|
448
|
-
type: "audio";
|
|
449
448
|
payload: {
|
|
450
449
|
audioUrl: string;
|
|
451
450
|
};
|
|
451
|
+
type: "audio";
|
|
452
452
|
} | {
|
|
453
|
-
type: "video";
|
|
454
453
|
payload: {
|
|
455
454
|
videoUrl: string;
|
|
456
455
|
};
|
|
456
|
+
type: "video";
|
|
457
457
|
} | {
|
|
458
|
-
type: "file";
|
|
459
458
|
payload: {
|
|
460
459
|
fileUrl: string;
|
|
461
460
|
title?: string | undefined;
|
|
462
461
|
};
|
|
462
|
+
type: "file";
|
|
463
463
|
} | {
|
|
464
|
-
type: "location";
|
|
465
464
|
payload: {
|
|
466
465
|
latitude: number;
|
|
467
466
|
longitude: number;
|
|
468
467
|
title?: string | undefined;
|
|
469
468
|
address?: string | undefined;
|
|
470
469
|
};
|
|
470
|
+
type: "location";
|
|
471
471
|
})[];
|
|
472
472
|
}>;
|
|
473
473
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as bot from '../../bot';
|
|
1
2
|
import { BaseIntegration, DefaultIntegration, InputBaseIntegration } from '../../integration/common/generic';
|
|
2
3
|
import { BaseInterface, InputBaseInterface, DefaultInterface } from '../../interface/common/generic';
|
|
3
4
|
import * as utils from '../../utils/type-utils';
|
|
@@ -15,6 +16,10 @@ export type BaseWorkflow = {
|
|
|
15
16
|
[k: string]: string;
|
|
16
17
|
};
|
|
17
18
|
};
|
|
19
|
+
export type BaseState = {
|
|
20
|
+
type: bot.StateType;
|
|
21
|
+
payload: any;
|
|
22
|
+
};
|
|
18
23
|
export type BasePlugin = {
|
|
19
24
|
name: string;
|
|
20
25
|
version: string;
|
|
@@ -22,7 +27,7 @@ export type BasePlugin = {
|
|
|
22
27
|
integrations: Record<string, BaseIntegration>;
|
|
23
28
|
interfaces: Record<string, BaseInterface>;
|
|
24
29
|
events: Record<string, any>;
|
|
25
|
-
states: Record<string,
|
|
30
|
+
states: Record<string, BaseState>;
|
|
26
31
|
actions: Record<string, BaseAction>;
|
|
27
32
|
tables: Record<string, BaseTable>;
|
|
28
33
|
workflows: Record<string, BaseWorkflow>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export type Function<I extends any[] = any, O extends any = any> = (...args: I) => O;
|
|
1
2
|
export type ValueOf<T> = T[keyof T];
|
|
2
3
|
export type Merge<A extends object, B extends object> = Omit<A, keyof B> & B;
|
|
3
4
|
export type Cast<T, U> = T extends U ? T : U;
|
|
@@ -6,6 +7,9 @@ export type Writable<T> = {
|
|
|
6
7
|
-readonly [K in keyof T]: T[K];
|
|
7
8
|
};
|
|
8
9
|
export type Default<T, U> = undefined extends T ? U : T;
|
|
10
|
+
export type Not<X extends boolean> = X extends true ? false : true;
|
|
11
|
+
export type And<X extends boolean, Y extends boolean> = X extends true ? (Y extends true ? true : false) : false;
|
|
12
|
+
export type Or<X extends boolean, Y extends boolean> = X extends true ? true : Y extends true ? true : false;
|
|
9
13
|
export type AtLeastOne<T> = [T, ...T[]];
|
|
10
14
|
export type AtLeastOneProperty<T> = T extends undefined ? {} : {
|
|
11
15
|
[K in keyof T]?: T[K];
|
|
@@ -23,6 +27,12 @@ export type IsExtend<X, Y> = X extends Y ? true : false;
|
|
|
23
27
|
export type IsEquivalent<X, Y> = IsExtend<X, Y> extends true ? IsExtend<Y, X> : false;
|
|
24
28
|
export type IsIdentical<X, Y> = (<T>() => T extends X ? 1 : 2) extends <T>() => T extends Y ? 1 : 2 ? true : false;
|
|
25
29
|
export type IsEqual<X, Y> = IsIdentical<Normalize<X>, Normalize<Y>>;
|
|
30
|
+
/**
|
|
31
|
+
* For F1 function to extend F2 function,
|
|
32
|
+
* F2 input should extend F1 input so that if you call F1 thinking it is F2, it still works.
|
|
33
|
+
* IsStricterFunction is not an extension check as it allows F1 to require a stricter input than F2.
|
|
34
|
+
*/
|
|
35
|
+
export type IsStricterFunction<F1 extends Function, F2 extends Function> = And<IsExtend<ReturnType<F1>, ReturnType<F2>>, IsExtend<Parameters<F1>, Parameters<F2>>>;
|
|
26
36
|
export type AssertExtends<_A extends B, B> = true;
|
|
27
37
|
export type AssertNotExtends<A, B> = A extends B ? false : true;
|
|
28
38
|
export type AssertTrue<_T extends true> = true;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@botpress/sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "Botpress SDK",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"author": "",
|
|
17
17
|
"license": "MIT",
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@botpress/client": "0.48.
|
|
19
|
+
"@botpress/client": "0.48.3",
|
|
20
20
|
"browser-or-node": "^2.1.1"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|