@botpress/api 1.73.3 → 1.74.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/.eslintrc.js +0 -1
- package/dist/index.js +152 -1049
- package/dist/src/gen/runtime/state.d.ts +8 -468
- package/dist/src/gen/state.d.ts +34 -377
- package/dist/src/gen/tables/state.d.ts +26 -0
- package/package.json +7 -7
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as opapi from '@bpinternal/opapi';
|
|
2
|
-
export type State = opapi.State<'User' | 'Conversation' | 'Event' | 'Message' | 'State' | '
|
|
2
|
+
export type State = opapi.State<'User' | 'Conversation' | 'Event' | 'Message' | 'State' | 'Workflow', 'x-bot-id' | 'x-integration-id' | 'x-integration-alias', 'user' | 'conversation' | 'event' | 'message' | 'state' | 'hub' | 'action' | 'workflow' | 'tag'>;
|
|
3
3
|
export declare const state: {
|
|
4
4
|
operations: {
|
|
5
5
|
createConversation: {
|
|
@@ -347,6 +347,8 @@ export declare const state: {
|
|
|
347
347
|
properties: {
|
|
348
348
|
currentTaskId: {
|
|
349
349
|
type: "string";
|
|
350
|
+
deprecated: true;
|
|
351
|
+
description: string;
|
|
350
352
|
};
|
|
351
353
|
tags: {
|
|
352
354
|
type: "object";
|
|
@@ -2668,373 +2670,6 @@ export declare const state: {
|
|
|
2668
2670
|
};
|
|
2669
2671
|
};
|
|
2670
2672
|
};
|
|
2671
|
-
getTask: {
|
|
2672
|
-
name: string;
|
|
2673
|
-
description: string;
|
|
2674
|
-
method: "get";
|
|
2675
|
-
path: string;
|
|
2676
|
-
parameters: {
|
|
2677
|
-
id: {
|
|
2678
|
-
in: "path";
|
|
2679
|
-
type: "string";
|
|
2680
|
-
description: string;
|
|
2681
|
-
};
|
|
2682
|
-
"x-bot-id": {
|
|
2683
|
-
in: "header";
|
|
2684
|
-
description: string;
|
|
2685
|
-
type: "string";
|
|
2686
|
-
required: true;
|
|
2687
|
-
};
|
|
2688
|
-
"x-integration-id": {
|
|
2689
|
-
in: "header";
|
|
2690
|
-
description: string;
|
|
2691
|
-
type: "string";
|
|
2692
|
-
required: false;
|
|
2693
|
-
};
|
|
2694
|
-
"x-integration-alias": {
|
|
2695
|
-
in: "header";
|
|
2696
|
-
description: string;
|
|
2697
|
-
type: "string";
|
|
2698
|
-
required: false;
|
|
2699
|
-
};
|
|
2700
|
-
};
|
|
2701
|
-
section: "task";
|
|
2702
|
-
response: {
|
|
2703
|
-
description: string;
|
|
2704
|
-
schema: {
|
|
2705
|
-
type: "object";
|
|
2706
|
-
properties: {
|
|
2707
|
-
task: {
|
|
2708
|
-
$ref: string;
|
|
2709
|
-
};
|
|
2710
|
-
};
|
|
2711
|
-
required: string[];
|
|
2712
|
-
title: string;
|
|
2713
|
-
additionalProperties: false;
|
|
2714
|
-
};
|
|
2715
|
-
};
|
|
2716
|
-
};
|
|
2717
|
-
createTask: {
|
|
2718
|
-
name: string;
|
|
2719
|
-
description: string;
|
|
2720
|
-
method: "post";
|
|
2721
|
-
path: string;
|
|
2722
|
-
requestBody: {
|
|
2723
|
-
description: string;
|
|
2724
|
-
schema: {
|
|
2725
|
-
type: "object";
|
|
2726
|
-
properties: {
|
|
2727
|
-
title: {
|
|
2728
|
-
type: "string";
|
|
2729
|
-
maxLength: number;
|
|
2730
|
-
description: string;
|
|
2731
|
-
};
|
|
2732
|
-
description: {
|
|
2733
|
-
type: "string";
|
|
2734
|
-
maxLength: number;
|
|
2735
|
-
description: string;
|
|
2736
|
-
};
|
|
2737
|
-
type: {
|
|
2738
|
-
type: "string";
|
|
2739
|
-
maxLength: number;
|
|
2740
|
-
description: string;
|
|
2741
|
-
};
|
|
2742
|
-
data: {
|
|
2743
|
-
type: "object";
|
|
2744
|
-
additionalProperties: true;
|
|
2745
|
-
description: string;
|
|
2746
|
-
};
|
|
2747
|
-
parentTaskId: {
|
|
2748
|
-
type: "string";
|
|
2749
|
-
description: string;
|
|
2750
|
-
};
|
|
2751
|
-
conversationId: {
|
|
2752
|
-
type: "string";
|
|
2753
|
-
description: string;
|
|
2754
|
-
};
|
|
2755
|
-
userId: {
|
|
2756
|
-
type: "string";
|
|
2757
|
-
description: string;
|
|
2758
|
-
};
|
|
2759
|
-
timeoutAt: {
|
|
2760
|
-
type: "string";
|
|
2761
|
-
format: string;
|
|
2762
|
-
description: string;
|
|
2763
|
-
};
|
|
2764
|
-
tags: {
|
|
2765
|
-
type: "object";
|
|
2766
|
-
additionalProperties: {
|
|
2767
|
-
type: "string";
|
|
2768
|
-
maxLength: number;
|
|
2769
|
-
};
|
|
2770
|
-
description: string;
|
|
2771
|
-
};
|
|
2772
|
-
};
|
|
2773
|
-
required: string[];
|
|
2774
|
-
title: string;
|
|
2775
|
-
additionalProperties: false;
|
|
2776
|
-
};
|
|
2777
|
-
};
|
|
2778
|
-
section: "task";
|
|
2779
|
-
response: {
|
|
2780
|
-
description: string;
|
|
2781
|
-
status: 201;
|
|
2782
|
-
schema: {
|
|
2783
|
-
type: "object";
|
|
2784
|
-
properties: {
|
|
2785
|
-
task: {
|
|
2786
|
-
$ref: string;
|
|
2787
|
-
};
|
|
2788
|
-
};
|
|
2789
|
-
required: string[];
|
|
2790
|
-
title: string;
|
|
2791
|
-
additionalProperties: false;
|
|
2792
|
-
};
|
|
2793
|
-
};
|
|
2794
|
-
parameters: {
|
|
2795
|
-
"x-bot-id": {
|
|
2796
|
-
in: "header";
|
|
2797
|
-
description: string;
|
|
2798
|
-
type: "string";
|
|
2799
|
-
required: true;
|
|
2800
|
-
};
|
|
2801
|
-
"x-integration-id": {
|
|
2802
|
-
in: "header";
|
|
2803
|
-
description: string;
|
|
2804
|
-
type: "string";
|
|
2805
|
-
required: false;
|
|
2806
|
-
};
|
|
2807
|
-
"x-integration-alias": {
|
|
2808
|
-
in: "header";
|
|
2809
|
-
description: string;
|
|
2810
|
-
type: "string";
|
|
2811
|
-
required: false;
|
|
2812
|
-
};
|
|
2813
|
-
};
|
|
2814
|
-
};
|
|
2815
|
-
updateTask: {
|
|
2816
|
-
name: string;
|
|
2817
|
-
description: string;
|
|
2818
|
-
method: "put";
|
|
2819
|
-
path: string;
|
|
2820
|
-
parameters: {
|
|
2821
|
-
id: {
|
|
2822
|
-
in: "path";
|
|
2823
|
-
type: "string";
|
|
2824
|
-
description: string;
|
|
2825
|
-
};
|
|
2826
|
-
"x-bot-id": {
|
|
2827
|
-
in: "header";
|
|
2828
|
-
description: string;
|
|
2829
|
-
type: "string";
|
|
2830
|
-
required: true;
|
|
2831
|
-
};
|
|
2832
|
-
"x-integration-id": {
|
|
2833
|
-
in: "header";
|
|
2834
|
-
description: string;
|
|
2835
|
-
type: "string";
|
|
2836
|
-
required: false;
|
|
2837
|
-
};
|
|
2838
|
-
"x-integration-alias": {
|
|
2839
|
-
in: "header";
|
|
2840
|
-
description: string;
|
|
2841
|
-
type: "string";
|
|
2842
|
-
required: false;
|
|
2843
|
-
};
|
|
2844
|
-
};
|
|
2845
|
-
requestBody: {
|
|
2846
|
-
description: string;
|
|
2847
|
-
schema: {
|
|
2848
|
-
type: "object";
|
|
2849
|
-
properties: {
|
|
2850
|
-
title: {
|
|
2851
|
-
type: "string";
|
|
2852
|
-
description: string;
|
|
2853
|
-
};
|
|
2854
|
-
description: {
|
|
2855
|
-
type: "string";
|
|
2856
|
-
description: string;
|
|
2857
|
-
};
|
|
2858
|
-
data: {
|
|
2859
|
-
type: "object";
|
|
2860
|
-
additionalProperties: true;
|
|
2861
|
-
description: string;
|
|
2862
|
-
};
|
|
2863
|
-
timeoutAt: {
|
|
2864
|
-
type: "string";
|
|
2865
|
-
format: string;
|
|
2866
|
-
description: string;
|
|
2867
|
-
};
|
|
2868
|
-
status: {
|
|
2869
|
-
type: "string";
|
|
2870
|
-
enum: string[];
|
|
2871
|
-
description: string;
|
|
2872
|
-
};
|
|
2873
|
-
tags: {
|
|
2874
|
-
type: "object";
|
|
2875
|
-
additionalProperties: {
|
|
2876
|
-
type: "string";
|
|
2877
|
-
maxLength: number;
|
|
2878
|
-
};
|
|
2879
|
-
description: string;
|
|
2880
|
-
};
|
|
2881
|
-
};
|
|
2882
|
-
title: string;
|
|
2883
|
-
additionalProperties: false;
|
|
2884
|
-
};
|
|
2885
|
-
};
|
|
2886
|
-
section: "task";
|
|
2887
|
-
response: {
|
|
2888
|
-
description: string;
|
|
2889
|
-
schema: {
|
|
2890
|
-
type: "object";
|
|
2891
|
-
properties: {
|
|
2892
|
-
task: {
|
|
2893
|
-
$ref: string;
|
|
2894
|
-
};
|
|
2895
|
-
};
|
|
2896
|
-
required: string[];
|
|
2897
|
-
title: string;
|
|
2898
|
-
additionalProperties: false;
|
|
2899
|
-
};
|
|
2900
|
-
};
|
|
2901
|
-
};
|
|
2902
|
-
deleteTask: {
|
|
2903
|
-
name: string;
|
|
2904
|
-
description: string;
|
|
2905
|
-
method: "delete";
|
|
2906
|
-
path: string;
|
|
2907
|
-
parameters: {
|
|
2908
|
-
id: {
|
|
2909
|
-
in: "path";
|
|
2910
|
-
type: "string";
|
|
2911
|
-
description: string;
|
|
2912
|
-
};
|
|
2913
|
-
"x-bot-id": {
|
|
2914
|
-
in: "header";
|
|
2915
|
-
description: string;
|
|
2916
|
-
type: "string";
|
|
2917
|
-
required: true;
|
|
2918
|
-
};
|
|
2919
|
-
"x-integration-id": {
|
|
2920
|
-
in: "header";
|
|
2921
|
-
description: string;
|
|
2922
|
-
type: "string";
|
|
2923
|
-
required: false;
|
|
2924
|
-
};
|
|
2925
|
-
"x-integration-alias": {
|
|
2926
|
-
in: "header";
|
|
2927
|
-
description: string;
|
|
2928
|
-
type: "string";
|
|
2929
|
-
required: false;
|
|
2930
|
-
};
|
|
2931
|
-
};
|
|
2932
|
-
section: "task";
|
|
2933
|
-
response: {
|
|
2934
|
-
description: string;
|
|
2935
|
-
schema: {
|
|
2936
|
-
type: "object";
|
|
2937
|
-
title: string;
|
|
2938
|
-
additionalProperties: false;
|
|
2939
|
-
};
|
|
2940
|
-
};
|
|
2941
|
-
};
|
|
2942
|
-
listTasks: {
|
|
2943
|
-
name: string;
|
|
2944
|
-
description: string;
|
|
2945
|
-
method: "get";
|
|
2946
|
-
path: string;
|
|
2947
|
-
parameters: {
|
|
2948
|
-
nextToken: {
|
|
2949
|
-
in: "query";
|
|
2950
|
-
description: string;
|
|
2951
|
-
type: "string";
|
|
2952
|
-
};
|
|
2953
|
-
tags: {
|
|
2954
|
-
in: "query";
|
|
2955
|
-
type: "object";
|
|
2956
|
-
schema: {
|
|
2957
|
-
type: "object";
|
|
2958
|
-
additionalProperties: {
|
|
2959
|
-
type: "string";
|
|
2960
|
-
};
|
|
2961
|
-
};
|
|
2962
|
-
description: string;
|
|
2963
|
-
};
|
|
2964
|
-
conversationId: {
|
|
2965
|
-
in: "query";
|
|
2966
|
-
type: "string";
|
|
2967
|
-
description: string;
|
|
2968
|
-
};
|
|
2969
|
-
userId: {
|
|
2970
|
-
in: "query";
|
|
2971
|
-
type: "string";
|
|
2972
|
-
description: string;
|
|
2973
|
-
};
|
|
2974
|
-
parentTaskId: {
|
|
2975
|
-
in: "query";
|
|
2976
|
-
type: "string";
|
|
2977
|
-
description: string;
|
|
2978
|
-
};
|
|
2979
|
-
status: {
|
|
2980
|
-
in: "query";
|
|
2981
|
-
type: "string[]";
|
|
2982
|
-
description: string;
|
|
2983
|
-
enum: string[];
|
|
2984
|
-
};
|
|
2985
|
-
type: {
|
|
2986
|
-
in: "query";
|
|
2987
|
-
type: "string";
|
|
2988
|
-
description: string;
|
|
2989
|
-
};
|
|
2990
|
-
"x-bot-id": {
|
|
2991
|
-
in: "header";
|
|
2992
|
-
description: string;
|
|
2993
|
-
type: "string";
|
|
2994
|
-
required: true;
|
|
2995
|
-
};
|
|
2996
|
-
"x-integration-id": {
|
|
2997
|
-
in: "header";
|
|
2998
|
-
description: string;
|
|
2999
|
-
type: "string";
|
|
3000
|
-
required: false;
|
|
3001
|
-
};
|
|
3002
|
-
"x-integration-alias": {
|
|
3003
|
-
in: "header";
|
|
3004
|
-
description: string;
|
|
3005
|
-
type: "string";
|
|
3006
|
-
required: false;
|
|
3007
|
-
};
|
|
3008
|
-
};
|
|
3009
|
-
section: "task";
|
|
3010
|
-
response: {
|
|
3011
|
-
description: string;
|
|
3012
|
-
schema: {
|
|
3013
|
-
type: "object";
|
|
3014
|
-
properties: {
|
|
3015
|
-
tasks: {
|
|
3016
|
-
type: "array";
|
|
3017
|
-
items: {
|
|
3018
|
-
$ref: string;
|
|
3019
|
-
};
|
|
3020
|
-
};
|
|
3021
|
-
meta: {
|
|
3022
|
-
type: "object";
|
|
3023
|
-
properties: {
|
|
3024
|
-
nextToken: {
|
|
3025
|
-
type: "string";
|
|
3026
|
-
description: string;
|
|
3027
|
-
};
|
|
3028
|
-
};
|
|
3029
|
-
additionalProperties: false;
|
|
3030
|
-
};
|
|
3031
|
-
};
|
|
3032
|
-
required: string[];
|
|
3033
|
-
title: string;
|
|
3034
|
-
additionalProperties: false;
|
|
3035
|
-
};
|
|
3036
|
-
};
|
|
3037
|
-
};
|
|
3038
2673
|
createWorkflow: {
|
|
3039
2674
|
name: string;
|
|
3040
2675
|
description: string;
|
|
@@ -3654,6 +3289,10 @@ export declare const state: {
|
|
|
3654
3289
|
schema: {
|
|
3655
3290
|
type: "object";
|
|
3656
3291
|
properties: {
|
|
3292
|
+
id: {
|
|
3293
|
+
type: "string";
|
|
3294
|
+
description: string;
|
|
3295
|
+
};
|
|
3657
3296
|
name: {
|
|
3658
3297
|
type: "string";
|
|
3659
3298
|
description: string;
|
|
@@ -3826,8 +3465,6 @@ export declare const state: {
|
|
|
3826
3465
|
patchStateBody: true;
|
|
3827
3466
|
callActionBody: true;
|
|
3828
3467
|
configureIntegrationBody: true;
|
|
3829
|
-
createTaskBody: true;
|
|
3830
|
-
updateTaskBody: true;
|
|
3831
3468
|
createWorkflowBody: true;
|
|
3832
3469
|
updateWorkflowBody: true;
|
|
3833
3470
|
getOrCreateWorkflowBody: true;
|
|
@@ -3870,11 +3507,6 @@ export declare const state: {
|
|
|
3870
3507
|
patchStateResponse: true;
|
|
3871
3508
|
callActionResponse: true;
|
|
3872
3509
|
configureIntegrationResponse: true;
|
|
3873
|
-
getTaskResponse: true;
|
|
3874
|
-
createTaskResponse: true;
|
|
3875
|
-
updateTaskResponse: true;
|
|
3876
|
-
deleteTaskResponse: true;
|
|
3877
|
-
listTasksResponse: true;
|
|
3878
3510
|
createWorkflowResponse: true;
|
|
3879
3511
|
getWorkflowResponse: true;
|
|
3880
3512
|
updateWorkflowResponse: true;
|
|
@@ -3891,7 +3523,6 @@ export declare const state: {
|
|
|
3891
3523
|
Event: true;
|
|
3892
3524
|
Message: true;
|
|
3893
3525
|
State: true;
|
|
3894
|
-
Task: true;
|
|
3895
3526
|
Workflow: true;
|
|
3896
3527
|
};
|
|
3897
3528
|
};
|
|
@@ -3963,6 +3594,7 @@ export declare const state: {
|
|
|
3963
3594
|
type: "string";
|
|
3964
3595
|
minLength: number;
|
|
3965
3596
|
maxLength: number;
|
|
3597
|
+
deprecated: true;
|
|
3966
3598
|
description: string;
|
|
3967
3599
|
};
|
|
3968
3600
|
currentWorkflowId: {
|
|
@@ -4188,92 +3820,6 @@ export declare const state: {
|
|
|
4188
3820
|
additionalProperties: false;
|
|
4189
3821
|
};
|
|
4190
3822
|
};
|
|
4191
|
-
Task: {
|
|
4192
|
-
section: "task";
|
|
4193
|
-
schema: {
|
|
4194
|
-
type: "object";
|
|
4195
|
-
properties: {
|
|
4196
|
-
id: {
|
|
4197
|
-
type: "string";
|
|
4198
|
-
minLength: number;
|
|
4199
|
-
maxLength: number;
|
|
4200
|
-
description: string;
|
|
4201
|
-
};
|
|
4202
|
-
title: {
|
|
4203
|
-
type: "string";
|
|
4204
|
-
maxLength: number;
|
|
4205
|
-
description: string;
|
|
4206
|
-
};
|
|
4207
|
-
description: {
|
|
4208
|
-
type: "string";
|
|
4209
|
-
maxLength: number;
|
|
4210
|
-
description: string;
|
|
4211
|
-
};
|
|
4212
|
-
type: {
|
|
4213
|
-
type: "string";
|
|
4214
|
-
description: string;
|
|
4215
|
-
};
|
|
4216
|
-
data: {
|
|
4217
|
-
type: "object";
|
|
4218
|
-
additionalProperties: true;
|
|
4219
|
-
description: string;
|
|
4220
|
-
};
|
|
4221
|
-
status: {
|
|
4222
|
-
type: "string";
|
|
4223
|
-
enum: string[];
|
|
4224
|
-
description: string;
|
|
4225
|
-
};
|
|
4226
|
-
parentTaskId: {
|
|
4227
|
-
type: "string";
|
|
4228
|
-
minLength: number;
|
|
4229
|
-
maxLength: number;
|
|
4230
|
-
description: string;
|
|
4231
|
-
};
|
|
4232
|
-
conversationId: {
|
|
4233
|
-
type: "string";
|
|
4234
|
-
minLength: number;
|
|
4235
|
-
maxLength: number;
|
|
4236
|
-
description: string;
|
|
4237
|
-
};
|
|
4238
|
-
userId: {
|
|
4239
|
-
type: "string";
|
|
4240
|
-
minLength: number;
|
|
4241
|
-
maxLength: number;
|
|
4242
|
-
description: string;
|
|
4243
|
-
};
|
|
4244
|
-
timeoutAt: {
|
|
4245
|
-
type: "string";
|
|
4246
|
-
format: string;
|
|
4247
|
-
description: string;
|
|
4248
|
-
};
|
|
4249
|
-
createdAt: {
|
|
4250
|
-
type: "string";
|
|
4251
|
-
format: string;
|
|
4252
|
-
description: string;
|
|
4253
|
-
};
|
|
4254
|
-
updatedAt: {
|
|
4255
|
-
type: "string";
|
|
4256
|
-
format: string;
|
|
4257
|
-
description: string;
|
|
4258
|
-
};
|
|
4259
|
-
failureReason: {
|
|
4260
|
-
type: "string";
|
|
4261
|
-
maxLength: number;
|
|
4262
|
-
description: string;
|
|
4263
|
-
};
|
|
4264
|
-
tags: {
|
|
4265
|
-
type: "object";
|
|
4266
|
-
additionalProperties: {
|
|
4267
|
-
type: "string";
|
|
4268
|
-
};
|
|
4269
|
-
description: string;
|
|
4270
|
-
};
|
|
4271
|
-
};
|
|
4272
|
-
required: string[];
|
|
4273
|
-
description: string;
|
|
4274
|
-
additionalProperties: false;
|
|
4275
|
-
};
|
|
4276
|
-
};
|
|
4277
3823
|
Workflow: {
|
|
4278
3824
|
section: "workflow";
|
|
4279
3825
|
schema: {
|
|
@@ -4404,12 +3950,6 @@ export declare const state: {
|
|
|
4404
3950
|
name: "action";
|
|
4405
3951
|
operations: string[];
|
|
4406
3952
|
schema?: undefined;
|
|
4407
|
-
} | {
|
|
4408
|
-
description: string;
|
|
4409
|
-
title: string;
|
|
4410
|
-
name: "task";
|
|
4411
|
-
operations: string[];
|
|
4412
|
-
schema: string;
|
|
4413
3953
|
} | {
|
|
4414
3954
|
description: string;
|
|
4415
3955
|
title: string;
|