@epilot/automation-client 2.9.1 → 2.9.3
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/openapi.d.ts +114 -145
- package/dist/openapi.json +55 -98
- package/package.json +1 -1
package/dist/openapi.d.ts
CHANGED
|
@@ -9,6 +9,31 @@ import type {
|
|
|
9
9
|
|
|
10
10
|
declare namespace Components {
|
|
11
11
|
namespace Schemas {
|
|
12
|
+
export interface ActionCondition {
|
|
13
|
+
id?: string;
|
|
14
|
+
/**
|
|
15
|
+
* Result of the condition evaluation
|
|
16
|
+
*/
|
|
17
|
+
evaluationResult?: boolean;
|
|
18
|
+
conditions?: /**
|
|
19
|
+
* example:
|
|
20
|
+
* {
|
|
21
|
+
* "source": {
|
|
22
|
+
* "origin": "trigger",
|
|
23
|
+
* "originType": "entity",
|
|
24
|
+
* "id": "trigger-id",
|
|
25
|
+
* "schema": "contact",
|
|
26
|
+
* "attribute": "email",
|
|
27
|
+
* "attributeType": "text"
|
|
28
|
+
* },
|
|
29
|
+
* "operation": "equals",
|
|
30
|
+
* "values": [
|
|
31
|
+
* "hello@epilot.cloud"
|
|
32
|
+
* ]
|
|
33
|
+
* }
|
|
34
|
+
*/
|
|
35
|
+
Condition[];
|
|
36
|
+
}
|
|
12
37
|
/**
|
|
13
38
|
* example:
|
|
14
39
|
* e3d3ebac-baab-4395-abf4-50b5bf1f8b74
|
|
@@ -25,7 +50,7 @@ declare namespace Components {
|
|
|
25
50
|
types?: (("CreateMeterReading" | "UpdateMeterReading" | "DocDownloadedFromPortal" | "PortalUserResetPassword" | "PortalUserResetForgotPassword") | string)[];
|
|
26
51
|
};
|
|
27
52
|
}
|
|
28
|
-
export type AnyAction = MapEntityAction | TriggerWorkflowAction | TriggerWebhookAction | CreateDocumentAction | SendEmailAction | /* Creates an order entity with prices from journey */ CartCheckoutAction | AutomationAction
|
|
53
|
+
export type AnyAction = MapEntityAction | TriggerWorkflowAction | TriggerWebhookAction | CreateDocumentAction | SendEmailAction | /* Creates an order entity with prices from journey */ CartCheckoutAction | AutomationAction;
|
|
29
54
|
export type AnyActionConfig = /**
|
|
30
55
|
* example:
|
|
31
56
|
* {
|
|
@@ -225,7 +250,7 @@ declare namespace Components {
|
|
|
225
250
|
* }
|
|
226
251
|
* }
|
|
227
252
|
*/
|
|
228
|
-
SendEmailActionConfig | /* Creates an order entity with prices from journey */ CartCheckoutActionConfig | AutomationActionConfig
|
|
253
|
+
SendEmailActionConfig | /* Creates an order entity with prices from journey */ CartCheckoutActionConfig | AutomationActionConfig;
|
|
229
254
|
export type AnyTrigger = FrontendSubmitTrigger | JourneySubmitTrigger | ApiSubmissionTrigger | /**
|
|
230
255
|
* - If provides filter_config, executes an automation based on the filtered configuration when an entity event occurs.
|
|
231
256
|
* - The conditions on a filter follows the event bridge patterns - `https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-event-patterns.html`
|
|
@@ -509,6 +534,10 @@ declare namespace Components {
|
|
|
509
534
|
[name: string]: any;
|
|
510
535
|
};
|
|
511
536
|
};
|
|
537
|
+
/**
|
|
538
|
+
* Condition Id to be checked before executing the action
|
|
539
|
+
*/
|
|
540
|
+
condition_id?: string;
|
|
512
541
|
execution_status?: ExecutionStatus;
|
|
513
542
|
started_at?: string;
|
|
514
543
|
updated_at?: string;
|
|
@@ -564,6 +593,10 @@ declare namespace Components {
|
|
|
564
593
|
[name: string]: any;
|
|
565
594
|
};
|
|
566
595
|
};
|
|
596
|
+
/**
|
|
597
|
+
* Condition Id to be checked before executing the action
|
|
598
|
+
*/
|
|
599
|
+
condition_id?: string;
|
|
567
600
|
}
|
|
568
601
|
export interface AutomationActionExecutionState {
|
|
569
602
|
execution_status?: ExecutionStatus;
|
|
@@ -624,20 +657,8 @@ declare namespace Components {
|
|
|
624
657
|
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
625
658
|
*/
|
|
626
659
|
AutomationActionId;
|
|
660
|
+
conditions?: ActionCondition[];
|
|
627
661
|
actions: AnyAction[];
|
|
628
|
-
/**
|
|
629
|
-
* The edges between actions which define the flow order
|
|
630
|
-
*/
|
|
631
|
-
edges?: /**
|
|
632
|
-
* example:
|
|
633
|
-
* {
|
|
634
|
-
* "id": "9ec3711b-db63-449c-b894-54d5bb622a8f",
|
|
635
|
-
* "start": "3567cabc-587f-4ba2-8752-1f3da0100d1f",
|
|
636
|
-
* "end": "4e29af6c-9824-461c-bcfb-505840a949ba",
|
|
637
|
-
* "condition_output": true
|
|
638
|
-
* }
|
|
639
|
-
*/
|
|
640
|
-
Edge[];
|
|
641
662
|
/**
|
|
642
663
|
* Version of the flow
|
|
643
664
|
* example:
|
|
@@ -682,23 +703,11 @@ declare namespace Components {
|
|
|
682
703
|
* submission
|
|
683
704
|
*/
|
|
684
705
|
entity_schema?: string;
|
|
706
|
+
conditions?: ActionCondition[];
|
|
685
707
|
/**
|
|
686
708
|
* The actions (nodes) of the automation flow
|
|
687
709
|
*/
|
|
688
710
|
actions: AnyActionConfig[];
|
|
689
|
-
/**
|
|
690
|
-
* The edges between actions which define the flow order
|
|
691
|
-
*/
|
|
692
|
-
edges?: /**
|
|
693
|
-
* example:
|
|
694
|
-
* {
|
|
695
|
-
* "id": "9ec3711b-db63-449c-b894-54d5bb622a8f",
|
|
696
|
-
* "start": "3567cabc-587f-4ba2-8752-1f3da0100d1f",
|
|
697
|
-
* "end": "4e29af6c-9824-461c-bcfb-505840a949ba",
|
|
698
|
-
* "condition_output": true
|
|
699
|
-
* }
|
|
700
|
-
*/
|
|
701
|
-
Edge[];
|
|
702
711
|
/**
|
|
703
712
|
* Number of automation executions that ran
|
|
704
713
|
* example:
|
|
@@ -784,6 +793,10 @@ declare namespace Components {
|
|
|
784
793
|
[name: string]: any;
|
|
785
794
|
};
|
|
786
795
|
};
|
|
796
|
+
/**
|
|
797
|
+
* Condition Id to be checked before executing the action
|
|
798
|
+
*/
|
|
799
|
+
condition_id?: string;
|
|
787
800
|
execution_status?: ExecutionStatus;
|
|
788
801
|
started_at?: string;
|
|
789
802
|
updated_at?: string;
|
|
@@ -840,6 +853,10 @@ declare namespace Components {
|
|
|
840
853
|
[name: string]: any;
|
|
841
854
|
};
|
|
842
855
|
};
|
|
856
|
+
/**
|
|
857
|
+
* Condition Id to be checked before executing the action
|
|
858
|
+
*/
|
|
859
|
+
condition_id?: string;
|
|
843
860
|
}
|
|
844
861
|
export interface CartCheckoutConfig {
|
|
845
862
|
/**
|
|
@@ -877,107 +894,43 @@ declare namespace Components {
|
|
|
877
894
|
target_unique?: string[];
|
|
878
895
|
}
|
|
879
896
|
export type Comparison = "equals" | "any_of" | "not_empty" | "is_empty";
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
* Flag indicating whether the action was created automatically or manually
|
|
900
|
-
*/
|
|
901
|
-
created_automatically?: boolean;
|
|
902
|
-
/**
|
|
903
|
-
* Flag indicating whether the same action can be in bulk in a single execution. e.g; send-email / map-entity
|
|
904
|
-
*/
|
|
905
|
-
is_bulk_action?: boolean;
|
|
906
|
-
reason?: {
|
|
897
|
+
/**
|
|
898
|
+
* example:
|
|
899
|
+
* {
|
|
900
|
+
* "source": {
|
|
901
|
+
* "origin": "trigger",
|
|
902
|
+
* "originType": "entity",
|
|
903
|
+
* "id": "trigger-id",
|
|
904
|
+
* "schema": "contact",
|
|
905
|
+
* "attribute": "email",
|
|
906
|
+
* "attributeType": "text"
|
|
907
|
+
* },
|
|
908
|
+
* "operation": "equals",
|
|
909
|
+
* "values": [
|
|
910
|
+
* "hello@epilot.cloud"
|
|
911
|
+
* ]
|
|
912
|
+
* }
|
|
913
|
+
*/
|
|
914
|
+
export interface Condition {
|
|
915
|
+
source?: {
|
|
907
916
|
/**
|
|
908
|
-
* Why the action has to be skipped/failed
|
|
909
917
|
* example:
|
|
910
|
-
*
|
|
911
|
-
*/
|
|
912
|
-
message?: string;
|
|
913
|
-
/**
|
|
914
|
-
* Extra metadata about the skipping reason - such as a certain condition not met, etc.
|
|
918
|
+
* action | trigger
|
|
915
919
|
*/
|
|
916
|
-
|
|
917
|
-
[name: string]: any;
|
|
918
|
-
};
|
|
919
|
-
};
|
|
920
|
-
execution_status?: ExecutionStatus;
|
|
921
|
-
started_at?: string;
|
|
922
|
-
updated_at?: string;
|
|
923
|
-
/**
|
|
924
|
-
* example:
|
|
925
|
-
* {}
|
|
926
|
-
*/
|
|
927
|
-
outputs?: {
|
|
928
|
-
[name: string]: any;
|
|
929
|
-
};
|
|
930
|
-
error_output?: ErrorOutput;
|
|
931
|
-
retry_strategy?: /* different behaviors for retrying failed execution actions. */ RetryStrategy;
|
|
932
|
-
actions?: AnyAction[];
|
|
933
|
-
}
|
|
934
|
-
export interface ConditionActionConfig {
|
|
935
|
-
id?: /**
|
|
936
|
-
* example:
|
|
937
|
-
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
938
|
-
*/
|
|
939
|
-
AutomationActionId;
|
|
940
|
-
flow_action_id?: /**
|
|
941
|
-
* example:
|
|
942
|
-
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
943
|
-
*/
|
|
944
|
-
AutomationActionId;
|
|
945
|
-
name?: string;
|
|
946
|
-
type?: "condition";
|
|
947
|
-
config?: ConditionConfig;
|
|
948
|
-
/**
|
|
949
|
-
* Whether to stop execution in a failed state if this action fails
|
|
950
|
-
*/
|
|
951
|
-
allow_failure?: boolean;
|
|
952
|
-
/**
|
|
953
|
-
* Flag indicating whether the action was created automatically or manually
|
|
954
|
-
*/
|
|
955
|
-
created_automatically?: boolean;
|
|
956
|
-
/**
|
|
957
|
-
* Flag indicating whether the same action can be in bulk in a single execution. e.g; send-email / map-entity
|
|
958
|
-
*/
|
|
959
|
-
is_bulk_action?: boolean;
|
|
960
|
-
reason?: {
|
|
920
|
+
origin?: string;
|
|
961
921
|
/**
|
|
962
|
-
* Why the action has to be skipped/failed
|
|
963
922
|
* example:
|
|
964
|
-
*
|
|
923
|
+
* entity | workflow | journey block
|
|
965
924
|
*/
|
|
966
|
-
|
|
967
|
-
/**
|
|
968
|
-
* Extra metadata about the skipping reason - such as a certain condition not met, etc.
|
|
969
|
-
*/
|
|
970
|
-
payload?: {
|
|
971
|
-
[name: string]: any;
|
|
972
|
-
};
|
|
973
|
-
};
|
|
974
|
-
actions?: AnyActionConfig[];
|
|
975
|
-
}
|
|
976
|
-
export interface ConditionConfig {
|
|
977
|
-
source?: {
|
|
925
|
+
originType?: string;
|
|
978
926
|
id?: string;
|
|
979
|
-
|
|
927
|
+
schema?: string;
|
|
980
928
|
attribute?: string;
|
|
929
|
+
/**
|
|
930
|
+
* example:
|
|
931
|
+
* text | boolean | date | number
|
|
932
|
+
*/
|
|
933
|
+
attributeType?: string;
|
|
981
934
|
};
|
|
982
935
|
operation?: "equals" | "not_equals" | "contains" | "not_contains" | "starts_with" | "ends_with" | "greater_than" | "less_than" | "greater_than_or_equals" | "less_than_or_equals" | "is_empty" | "is_not_empty";
|
|
983
936
|
values?: string[];
|
|
@@ -1038,6 +991,10 @@ declare namespace Components {
|
|
|
1038
991
|
[name: string]: any;
|
|
1039
992
|
};
|
|
1040
993
|
};
|
|
994
|
+
/**
|
|
995
|
+
* Condition Id to be checked before executing the action
|
|
996
|
+
*/
|
|
997
|
+
condition_id?: string;
|
|
1041
998
|
execution_status?: ExecutionStatus;
|
|
1042
999
|
started_at?: string;
|
|
1043
1000
|
updated_at?: string;
|
|
@@ -1109,6 +1066,10 @@ declare namespace Components {
|
|
|
1109
1066
|
[name: string]: any;
|
|
1110
1067
|
};
|
|
1111
1068
|
};
|
|
1069
|
+
/**
|
|
1070
|
+
* Condition Id to be checked before executing the action
|
|
1071
|
+
*/
|
|
1072
|
+
condition_id?: string;
|
|
1112
1073
|
}
|
|
1113
1074
|
export interface CreateDocumentConfig {
|
|
1114
1075
|
template_id?: string;
|
|
@@ -1117,30 +1078,6 @@ declare namespace Components {
|
|
|
1117
1078
|
export type DiffAdded = FilterConditionOnEvent;
|
|
1118
1079
|
export type DiffDeleted = FilterConditionOnEvent;
|
|
1119
1080
|
export type DiffUpdated = FilterConditionOnEvent;
|
|
1120
|
-
/**
|
|
1121
|
-
* example:
|
|
1122
|
-
* {
|
|
1123
|
-
* "id": "9ec3711b-db63-449c-b894-54d5bb622a8f",
|
|
1124
|
-
* "start": "3567cabc-587f-4ba2-8752-1f3da0100d1f",
|
|
1125
|
-
* "end": "4e29af6c-9824-461c-bcfb-505840a949ba",
|
|
1126
|
-
* "condition_output": true
|
|
1127
|
-
* }
|
|
1128
|
-
*/
|
|
1129
|
-
export interface Edge {
|
|
1130
|
-
id: string;
|
|
1131
|
-
/**
|
|
1132
|
-
* The action id from which the edge starts
|
|
1133
|
-
*/
|
|
1134
|
-
start: string;
|
|
1135
|
-
/**
|
|
1136
|
-
* The action id to which the edge ends
|
|
1137
|
-
*/
|
|
1138
|
-
end: string;
|
|
1139
|
-
/**
|
|
1140
|
-
* The condition output of the edge (binary)
|
|
1141
|
-
*/
|
|
1142
|
-
condition_output?: boolean;
|
|
1143
|
-
}
|
|
1144
1081
|
/**
|
|
1145
1082
|
* example:
|
|
1146
1083
|
* e3d3ebac-baab-4395-abf4-50b5bf1f8b74
|
|
@@ -1456,6 +1393,10 @@ declare namespace Components {
|
|
|
1456
1393
|
[name: string]: any;
|
|
1457
1394
|
};
|
|
1458
1395
|
};
|
|
1396
|
+
/**
|
|
1397
|
+
* Condition Id to be checked before executing the action
|
|
1398
|
+
*/
|
|
1399
|
+
condition_id?: string;
|
|
1459
1400
|
execution_status?: ExecutionStatus;
|
|
1460
1401
|
started_at?: string;
|
|
1461
1402
|
updated_at?: string;
|
|
@@ -1629,6 +1570,10 @@ declare namespace Components {
|
|
|
1629
1570
|
[name: string]: any;
|
|
1630
1571
|
};
|
|
1631
1572
|
};
|
|
1573
|
+
/**
|
|
1574
|
+
* Condition Id to be checked before executing the action
|
|
1575
|
+
*/
|
|
1576
|
+
condition_id?: string;
|
|
1632
1577
|
}
|
|
1633
1578
|
export interface MapEntityConfig {
|
|
1634
1579
|
mapping_config?: MappingConfigRef;
|
|
@@ -1855,6 +1800,10 @@ declare namespace Components {
|
|
|
1855
1800
|
[name: string]: any;
|
|
1856
1801
|
};
|
|
1857
1802
|
};
|
|
1803
|
+
/**
|
|
1804
|
+
* Condition Id to be checked before executing the action
|
|
1805
|
+
*/
|
|
1806
|
+
condition_id?: string;
|
|
1858
1807
|
execution_status?: ExecutionStatus;
|
|
1859
1808
|
started_at?: string;
|
|
1860
1809
|
updated_at?: string;
|
|
@@ -1920,6 +1869,10 @@ declare namespace Components {
|
|
|
1920
1869
|
[name: string]: any;
|
|
1921
1870
|
};
|
|
1922
1871
|
};
|
|
1872
|
+
/**
|
|
1873
|
+
* Condition Id to be checked before executing the action
|
|
1874
|
+
*/
|
|
1875
|
+
condition_id?: string;
|
|
1923
1876
|
}
|
|
1924
1877
|
export interface SendEmailConfig {
|
|
1925
1878
|
email_template_id?: string;
|
|
@@ -2116,6 +2069,10 @@ declare namespace Components {
|
|
|
2116
2069
|
[name: string]: any;
|
|
2117
2070
|
};
|
|
2118
2071
|
};
|
|
2072
|
+
/**
|
|
2073
|
+
* Condition Id to be checked before executing the action
|
|
2074
|
+
*/
|
|
2075
|
+
condition_id?: string;
|
|
2119
2076
|
execution_status?: ExecutionStatus;
|
|
2120
2077
|
started_at?: string;
|
|
2121
2078
|
updated_at?: string;
|
|
@@ -2184,6 +2141,10 @@ declare namespace Components {
|
|
|
2184
2141
|
[name: string]: any;
|
|
2185
2142
|
};
|
|
2186
2143
|
};
|
|
2144
|
+
/**
|
|
2145
|
+
* Condition Id to be checked before executing the action
|
|
2146
|
+
*/
|
|
2147
|
+
condition_id?: string;
|
|
2187
2148
|
}
|
|
2188
2149
|
export interface TriggerWebhookConfig {
|
|
2189
2150
|
entity_sources?: string[];
|
|
@@ -2233,6 +2194,10 @@ declare namespace Components {
|
|
|
2233
2194
|
[name: string]: any;
|
|
2234
2195
|
};
|
|
2235
2196
|
};
|
|
2197
|
+
/**
|
|
2198
|
+
* Condition Id to be checked before executing the action
|
|
2199
|
+
*/
|
|
2200
|
+
condition_id?: string;
|
|
2236
2201
|
execution_status?: ExecutionStatus;
|
|
2237
2202
|
started_at?: string;
|
|
2238
2203
|
updated_at?: string;
|
|
@@ -2320,6 +2285,10 @@ declare namespace Components {
|
|
|
2320
2285
|
[name: string]: any;
|
|
2321
2286
|
};
|
|
2322
2287
|
};
|
|
2288
|
+
/**
|
|
2289
|
+
* Condition Id to be checked before executing the action
|
|
2290
|
+
*/
|
|
2291
|
+
condition_id?: string;
|
|
2323
2292
|
}
|
|
2324
2293
|
/**
|
|
2325
2294
|
* example:
|
package/dist/openapi.json
CHANGED
|
@@ -455,6 +455,12 @@
|
|
|
455
455
|
"type": "string",
|
|
456
456
|
"example": "submission"
|
|
457
457
|
},
|
|
458
|
+
"conditions": {
|
|
459
|
+
"type": "array",
|
|
460
|
+
"items": {
|
|
461
|
+
"$ref": "#/components/schemas/ActionCondition"
|
|
462
|
+
}
|
|
463
|
+
},
|
|
458
464
|
"actions": {
|
|
459
465
|
"type": "array",
|
|
460
466
|
"description": "The actions (nodes) of the automation flow",
|
|
@@ -463,13 +469,6 @@
|
|
|
463
469
|
},
|
|
464
470
|
"readOnly": true
|
|
465
471
|
},
|
|
466
|
-
"edges": {
|
|
467
|
-
"type": "array",
|
|
468
|
-
"description": "The edges between actions which define the flow order",
|
|
469
|
-
"items": {
|
|
470
|
-
"$ref": "#/components/schemas/Edge"
|
|
471
|
-
}
|
|
472
|
-
},
|
|
473
472
|
"runs": {
|
|
474
473
|
"type": "number",
|
|
475
474
|
"example": 7,
|
|
@@ -519,37 +518,6 @@
|
|
|
519
518
|
"actions"
|
|
520
519
|
]
|
|
521
520
|
},
|
|
522
|
-
"Edge": {
|
|
523
|
-
"type": "object",
|
|
524
|
-
"properties": {
|
|
525
|
-
"id": {
|
|
526
|
-
"type": "string"
|
|
527
|
-
},
|
|
528
|
-
"start": {
|
|
529
|
-
"type": "string",
|
|
530
|
-
"description": "The action id from which the edge starts"
|
|
531
|
-
},
|
|
532
|
-
"end": {
|
|
533
|
-
"type": "string",
|
|
534
|
-
"description": "The action id to which the edge ends"
|
|
535
|
-
},
|
|
536
|
-
"condition_output": {
|
|
537
|
-
"type": "boolean",
|
|
538
|
-
"description": "The condition output of the edge (binary)"
|
|
539
|
-
}
|
|
540
|
-
},
|
|
541
|
-
"required": [
|
|
542
|
-
"id",
|
|
543
|
-
"start",
|
|
544
|
-
"end"
|
|
545
|
-
],
|
|
546
|
-
"example": {
|
|
547
|
-
"id": "9ec3711b-db63-449c-b894-54d5bb622a8f",
|
|
548
|
-
"start": "3567cabc-587f-4ba2-8752-1f3da0100d1f",
|
|
549
|
-
"end": "4e29af6c-9824-461c-bcfb-505840a949ba",
|
|
550
|
-
"condition_output": true
|
|
551
|
-
}
|
|
552
|
-
},
|
|
553
521
|
"SearchAutomationsResp": {
|
|
554
522
|
"type": "object",
|
|
555
523
|
"properties": {
|
|
@@ -615,9 +583,6 @@
|
|
|
615
583
|
},
|
|
616
584
|
{
|
|
617
585
|
"$ref": "#/components/schemas/AutomationAction"
|
|
618
|
-
},
|
|
619
|
-
{
|
|
620
|
-
"$ref": "#/components/schemas/ConditionAction"
|
|
621
586
|
}
|
|
622
587
|
]
|
|
623
588
|
},
|
|
@@ -643,9 +608,6 @@
|
|
|
643
608
|
},
|
|
644
609
|
{
|
|
645
610
|
"$ref": "#/components/schemas/AutomationActionConfig"
|
|
646
|
-
},
|
|
647
|
-
{
|
|
648
|
-
"$ref": "#/components/schemas/ConditionActionConfig"
|
|
649
611
|
}
|
|
650
612
|
]
|
|
651
613
|
},
|
|
@@ -694,6 +656,10 @@
|
|
|
694
656
|
"description": "Extra metadata about the skipping reason - such as a certain condition not met, etc."
|
|
695
657
|
}
|
|
696
658
|
}
|
|
659
|
+
},
|
|
660
|
+
"condition_id": {
|
|
661
|
+
"type": "string",
|
|
662
|
+
"description": "Condition Id to be checked before executing the action"
|
|
697
663
|
}
|
|
698
664
|
}
|
|
699
665
|
},
|
|
@@ -1802,20 +1768,32 @@
|
|
|
1802
1768
|
}
|
|
1803
1769
|
}
|
|
1804
1770
|
},
|
|
1805
|
-
"
|
|
1771
|
+
"Condition": {
|
|
1806
1772
|
"type": "object",
|
|
1807
1773
|
"properties": {
|
|
1808
1774
|
"source": {
|
|
1809
1775
|
"type": "object",
|
|
1810
1776
|
"properties": {
|
|
1777
|
+
"origin": {
|
|
1778
|
+
"type": "string",
|
|
1779
|
+
"example": "action | trigger"
|
|
1780
|
+
},
|
|
1781
|
+
"originType": {
|
|
1782
|
+
"type": "string",
|
|
1783
|
+
"example": "entity | workflow | journey block"
|
|
1784
|
+
},
|
|
1811
1785
|
"id": {
|
|
1812
1786
|
"type": "string"
|
|
1813
1787
|
},
|
|
1814
|
-
"
|
|
1788
|
+
"schema": {
|
|
1815
1789
|
"type": "string"
|
|
1816
1790
|
},
|
|
1817
1791
|
"attribute": {
|
|
1818
1792
|
"type": "string"
|
|
1793
|
+
},
|
|
1794
|
+
"attributeType": {
|
|
1795
|
+
"type": "string",
|
|
1796
|
+
"example": "text | boolean | date | number"
|
|
1819
1797
|
}
|
|
1820
1798
|
}
|
|
1821
1799
|
},
|
|
@@ -1842,59 +1820,39 @@
|
|
|
1842
1820
|
"type": "string"
|
|
1843
1821
|
}
|
|
1844
1822
|
}
|
|
1823
|
+
},
|
|
1824
|
+
"example": {
|
|
1825
|
+
"source": {
|
|
1826
|
+
"origin": "trigger",
|
|
1827
|
+
"originType": "entity",
|
|
1828
|
+
"id": "trigger-id",
|
|
1829
|
+
"schema": "contact",
|
|
1830
|
+
"attribute": "email",
|
|
1831
|
+
"attributeType": "text"
|
|
1832
|
+
},
|
|
1833
|
+
"operation": "equals",
|
|
1834
|
+
"values": [
|
|
1835
|
+
"hello@epilot.cloud"
|
|
1836
|
+
]
|
|
1845
1837
|
}
|
|
1846
1838
|
},
|
|
1847
|
-
"
|
|
1848
|
-
"
|
|
1849
|
-
|
|
1850
|
-
|
|
1839
|
+
"ActionCondition": {
|
|
1840
|
+
"type": "object",
|
|
1841
|
+
"properties": {
|
|
1842
|
+
"id": {
|
|
1843
|
+
"type": "string"
|
|
1851
1844
|
},
|
|
1852
|
-
{
|
|
1853
|
-
"type": "
|
|
1854
|
-
"
|
|
1855
|
-
"type": {
|
|
1856
|
-
"enum": [
|
|
1857
|
-
"condition"
|
|
1858
|
-
]
|
|
1859
|
-
},
|
|
1860
|
-
"actions": {
|
|
1861
|
-
"type": "array",
|
|
1862
|
-
"items": {
|
|
1863
|
-
"$ref": "#/components/schemas/AnyAction"
|
|
1864
|
-
}
|
|
1865
|
-
},
|
|
1866
|
-
"config": {
|
|
1867
|
-
"$ref": "#/components/schemas/ConditionConfig"
|
|
1868
|
-
}
|
|
1869
|
-
}
|
|
1870
|
-
}
|
|
1871
|
-
]
|
|
1872
|
-
},
|
|
1873
|
-
"ConditionActionConfig": {
|
|
1874
|
-
"allOf": [
|
|
1875
|
-
{
|
|
1876
|
-
"$ref": "#/components/schemas/AutomationActionConfig"
|
|
1845
|
+
"evaluationResult": {
|
|
1846
|
+
"type": "boolean",
|
|
1847
|
+
"description": "Result of the condition evaluation"
|
|
1877
1848
|
},
|
|
1878
|
-
{
|
|
1879
|
-
"type": "
|
|
1880
|
-
"
|
|
1881
|
-
"
|
|
1882
|
-
"enum": [
|
|
1883
|
-
"condition"
|
|
1884
|
-
]
|
|
1885
|
-
},
|
|
1886
|
-
"actions": {
|
|
1887
|
-
"type": "array",
|
|
1888
|
-
"items": {
|
|
1889
|
-
"$ref": "#/components/schemas/AnyActionConfig"
|
|
1890
|
-
}
|
|
1891
|
-
},
|
|
1892
|
-
"config": {
|
|
1893
|
-
"$ref": "#/components/schemas/ConditionConfig"
|
|
1894
|
-
}
|
|
1849
|
+
"conditions": {
|
|
1850
|
+
"type": "array",
|
|
1851
|
+
"items": {
|
|
1852
|
+
"$ref": "#/components/schemas/Condition"
|
|
1895
1853
|
}
|
|
1896
1854
|
}
|
|
1897
|
-
|
|
1855
|
+
}
|
|
1898
1856
|
},
|
|
1899
1857
|
"AutomationExecutionId": {
|
|
1900
1858
|
"type": "string",
|
|
@@ -1939,17 +1897,16 @@
|
|
|
1939
1897
|
"current_action_id": {
|
|
1940
1898
|
"$ref": "#/components/schemas/AutomationActionId"
|
|
1941
1899
|
},
|
|
1942
|
-
"
|
|
1900
|
+
"conditions": {
|
|
1943
1901
|
"type": "array",
|
|
1944
1902
|
"items": {
|
|
1945
|
-
"$ref": "#/components/schemas/
|
|
1903
|
+
"$ref": "#/components/schemas/ActionCondition"
|
|
1946
1904
|
}
|
|
1947
1905
|
},
|
|
1948
|
-
"
|
|
1906
|
+
"actions": {
|
|
1949
1907
|
"type": "array",
|
|
1950
|
-
"description": "The edges between actions which define the flow order",
|
|
1951
1908
|
"items": {
|
|
1952
|
-
"$ref": "#/components/schemas/
|
|
1909
|
+
"$ref": "#/components/schemas/AnyAction"
|
|
1953
1910
|
}
|
|
1954
1911
|
},
|
|
1955
1912
|
"version": {
|