@periskope/types 0.6.439 → 0.6.440
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/rules.types.d.ts +2 -15
- package/dist/rules.types.d.ts.map +1 -1
- package/dist/rules.types.js +0 -80
- package/dist/types.d.ts +6 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/rules.types.ts +507 -609
- package/src/types.ts +7 -0
package/src/rules.types.ts
CHANGED
|
@@ -74,28 +74,28 @@ export type TaskRulesInfoType<
|
|
|
74
74
|
> = Merge<
|
|
75
75
|
AppendTypes<
|
|
76
76
|
T extends 'message'
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
77
|
+
? {
|
|
78
|
+
task: TaskVariablesType;
|
|
79
|
+
message: MessageVariablesType;
|
|
80
|
+
sender: SenderVariablesType;
|
|
81
|
+
chat: ChatVariablesType;
|
|
82
|
+
}
|
|
83
|
+
: T extends 'chat'
|
|
84
|
+
? {
|
|
85
|
+
task: TaskVariablesType;
|
|
86
|
+
chat: ChatVariablesType;
|
|
87
|
+
}
|
|
88
|
+
: T extends 'ticket'
|
|
89
|
+
? {
|
|
90
|
+
task: TaskVariablesType;
|
|
91
|
+
ticket: TicketVariablesType;
|
|
92
|
+
message: MessageVariablesType;
|
|
93
|
+
sender: SenderVariablesType;
|
|
94
|
+
chat: ChatVariablesType;
|
|
95
|
+
}
|
|
96
|
+
: {
|
|
97
|
+
task: TaskVariablesType;
|
|
98
|
+
},
|
|
99
99
|
'.'
|
|
100
100
|
>,
|
|
101
101
|
{
|
|
@@ -182,21 +182,21 @@ export type RuleInfoType =
|
|
|
182
182
|
export interface Filter {
|
|
183
183
|
id: string;
|
|
184
184
|
condition:
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
185
|
+
| 'CONTAINS'
|
|
186
|
+
| 'NCONTAINS'
|
|
187
|
+
| 'EQ'
|
|
188
|
+
| 'NEQ'
|
|
189
|
+
| 'LT'
|
|
190
|
+
| 'LTE'
|
|
191
|
+
| 'GT'
|
|
192
|
+
| 'GTE'
|
|
193
|
+
| 'KNOWN'
|
|
194
|
+
| 'NKNOWN'
|
|
195
|
+
| 'IS'
|
|
196
|
+
| 'NIS'
|
|
197
|
+
| 'ON'
|
|
198
|
+
| 'STARTS_WITH'
|
|
199
|
+
| 'ENDS_WITH'; // Add other condition types as needed
|
|
200
200
|
variable: string;
|
|
201
201
|
value: string | string[];
|
|
202
202
|
variable_type?: 'string' | 'number' | 'boolean' | 'day-time' | 'date' | 'day'; // Optional, like 'Date'
|
|
@@ -284,32 +284,32 @@ export const FilterNameMap: Record<
|
|
|
284
284
|
export type VariableNameValueType = {
|
|
285
285
|
text: string;
|
|
286
286
|
type:
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
287
|
+
| 'string'
|
|
288
|
+
| 'time'
|
|
289
|
+
| 'boolean'
|
|
290
|
+
| 'dropdown'
|
|
291
|
+
| 'day-time'
|
|
292
|
+
| 'number'
|
|
293
|
+
| 'date';
|
|
294
294
|
variable_type: 'string' | 'number' | 'boolean' | 'day-time' | 'date';
|
|
295
295
|
value?:
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
296
|
+
| string
|
|
297
|
+
| {
|
|
298
|
+
id: string;
|
|
299
|
+
value: string | number | boolean;
|
|
300
|
+
label: string;
|
|
301
|
+
}[]
|
|
302
|
+
| null;
|
|
303
303
|
filters:
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
304
|
+
| Partial<
|
|
305
|
+
Record<
|
|
306
|
+
Filter['condition'],
|
|
307
|
+
{
|
|
308
|
+
info?: string;
|
|
309
|
+
}
|
|
310
|
+
>
|
|
311
|
+
>
|
|
312
|
+
| Filter['condition'][];
|
|
313
313
|
hidden?: boolean;
|
|
314
314
|
placeholder?: string;
|
|
315
315
|
info?: string;
|
|
@@ -1165,30 +1165,13 @@ export type SendMessageAction = {
|
|
|
1165
1165
|
maintain_flag_status: 'true' | 'false';
|
|
1166
1166
|
debounce_messages: 'true' | 'false';
|
|
1167
1167
|
debounce_message_time:
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1168
|
+
| `${number} ${'seconds' | 'minutes' | 'hours' | 'days'}`
|
|
1169
|
+
| null
|
|
1170
|
+
| undefined;
|
|
1171
1171
|
};
|
|
1172
1172
|
delay: `${number} ${'seconds' | 'minutes' | 'hours' | 'days'}`;
|
|
1173
1173
|
};
|
|
1174
1174
|
|
|
1175
|
-
export type SendPollOptionAction = {
|
|
1176
|
-
id: string;
|
|
1177
|
-
type: 'send_poll_message';
|
|
1178
|
-
delay: `${number} ${'seconds' | 'minutes' | 'hours' | 'days'}`;
|
|
1179
|
-
metadata: {
|
|
1180
|
-
message: string;
|
|
1181
|
-
options: string[];
|
|
1182
|
-
allow_multiple_votes: 'true' | 'false';
|
|
1183
|
-
maintain_flag_status: 'true' | 'false';
|
|
1184
|
-
debounce_messages: 'true' | 'false';
|
|
1185
|
-
debounce_message_time:
|
|
1186
|
-
| `${number} ${'seconds' | 'minutes' | 'hours' | 'days'}`
|
|
1187
|
-
| null
|
|
1188
|
-
| undefined;
|
|
1189
|
-
};
|
|
1190
|
-
};
|
|
1191
|
-
|
|
1192
1175
|
export type NotifyHttpAction = {
|
|
1193
1176
|
id: string;
|
|
1194
1177
|
type: 'notify_http';
|
|
@@ -1314,9 +1297,9 @@ export type ReplyToMessageAction = {
|
|
|
1314
1297
|
maintain_flag_status: 'true' | 'false';
|
|
1315
1298
|
debounce_messages: 'true' | 'false';
|
|
1316
1299
|
debounce_message_time:
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1300
|
+
| `${number} ${'seconds' | 'minutes' | 'hours' | 'days'}`
|
|
1301
|
+
| null
|
|
1302
|
+
| undefined;
|
|
1320
1303
|
};
|
|
1321
1304
|
};
|
|
1322
1305
|
|
|
@@ -1432,8 +1415,7 @@ export type Action =
|
|
|
1432
1415
|
| SendMessageToChatAction
|
|
1433
1416
|
| FreshdeskCreateTicketAction
|
|
1434
1417
|
| HubspotCreateTicketAction
|
|
1435
|
-
| ZohodeskCreateTicketAction
|
|
1436
|
-
| SendPollOptionAction;
|
|
1418
|
+
| ZohodeskCreateTicketAction;
|
|
1437
1419
|
|
|
1438
1420
|
export const isSendMessageOrReplyToMessageAction = (
|
|
1439
1421
|
action: Action
|
|
@@ -1441,8 +1423,7 @@ export const isSendMessageOrReplyToMessageAction = (
|
|
|
1441
1423
|
return ['send_message', 'reply_to_message'].includes(action.type);
|
|
1442
1424
|
};
|
|
1443
1425
|
|
|
1444
|
-
export type TriggerRuleType =
|
|
1445
|
-
| 'message.created'
|
|
1426
|
+
export type TriggerRuleType = | 'message.created'
|
|
1446
1427
|
| 'message.updated'
|
|
1447
1428
|
| 'chat.created'
|
|
1448
1429
|
| 'ticket.updated'
|
|
@@ -1457,7 +1438,7 @@ export type TriggerRuleType =
|
|
|
1457
1438
|
| 'task.created'
|
|
1458
1439
|
| 'task.assignee.updated'
|
|
1459
1440
|
| 'call.created'
|
|
1460
|
-
| 'member.joined'
|
|
1441
|
+
| 'member.joined'
|
|
1461
1442
|
|
|
1462
1443
|
export type Rule = OverrideProperties<
|
|
1463
1444
|
Tables<'tbl_automation_rules'>,
|
|
@@ -1609,31 +1590,29 @@ type ActionNameMapType = {
|
|
|
1609
1590
|
{
|
|
1610
1591
|
id: string;
|
|
1611
1592
|
type:
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
| 'multi_text'
|
|
1621
|
-
| 'checkbox';
|
|
1593
|
+
| 'text'
|
|
1594
|
+
| 'dropdown'
|
|
1595
|
+
| 'editor'
|
|
1596
|
+
| 'date'
|
|
1597
|
+
| 'file'
|
|
1598
|
+
| 'textarea'
|
|
1599
|
+
| 'dynamic'
|
|
1600
|
+
| 'json_editor';
|
|
1622
1601
|
value:
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1602
|
+
| 'ticket.labels'
|
|
1603
|
+
| 'org.members'
|
|
1604
|
+
| 'chat.labels'
|
|
1605
|
+
| 'org.chats'
|
|
1606
|
+
| {
|
|
1607
|
+
id: string;
|
|
1608
|
+
value: string;
|
|
1609
|
+
label: string;
|
|
1610
|
+
}[]
|
|
1611
|
+
| null
|
|
1612
|
+
| 'org.custom_properties.chat'
|
|
1613
|
+
| 'org.custom_properties.ticket'
|
|
1614
|
+
| 'custom_property_values'
|
|
1615
|
+
| 'custom_duration';
|
|
1637
1616
|
label: string;
|
|
1638
1617
|
placeholder: string;
|
|
1639
1618
|
info?: string;
|
|
@@ -1642,8 +1621,8 @@ type ActionNameMapType = {
|
|
|
1642
1621
|
}
|
|
1643
1622
|
>;
|
|
1644
1623
|
validate: K extends keyof ValidateArgsMap
|
|
1645
|
-
|
|
1646
|
-
|
|
1624
|
+
? ValidateFunction<ValidateArgsMap[K]>
|
|
1625
|
+
: ValidateFunction<never[]>;
|
|
1647
1626
|
info?: string;
|
|
1648
1627
|
validTriggers: TriggerRuleType[];
|
|
1649
1628
|
};
|
|
@@ -1789,87 +1768,6 @@ export const ActionNameMap: ActionNameMapType = {
|
|
|
1789
1768
|
],
|
|
1790
1769
|
validate: () => true,
|
|
1791
1770
|
},
|
|
1792
|
-
|
|
1793
|
-
send_poll_message: {
|
|
1794
|
-
title: 'Send Poll Message',
|
|
1795
|
-
description: 'Send a poll',
|
|
1796
|
-
inputs: {
|
|
1797
|
-
message: {
|
|
1798
|
-
id: 'message',
|
|
1799
|
-
type: 'editor',
|
|
1800
|
-
label: 'Question',
|
|
1801
|
-
placeholder: 'Type your question here...',
|
|
1802
|
-
required: true,
|
|
1803
|
-
value: null,
|
|
1804
|
-
},
|
|
1805
|
-
options: {
|
|
1806
|
-
id: 'options',
|
|
1807
|
-
type: 'multi_text',
|
|
1808
|
-
label: 'Options',
|
|
1809
|
-
placeholder: 'Add',
|
|
1810
|
-
required: true,
|
|
1811
|
-
value: null,
|
|
1812
|
-
},
|
|
1813
|
-
allow_multiple_votes: {
|
|
1814
|
-
id: 'allowMultipleVotes',
|
|
1815
|
-
type: 'checkbox',
|
|
1816
|
-
label: 'Allow Multiple Votes',
|
|
1817
|
-
placeholder: 'Select...',
|
|
1818
|
-
value: null,
|
|
1819
|
-
required: false,
|
|
1820
|
-
},
|
|
1821
|
-
maintain_flag_status: {
|
|
1822
|
-
id: 'maintain_flag_status',
|
|
1823
|
-
type: 'dropdown',
|
|
1824
|
-
label: 'Maintain Flag Status',
|
|
1825
|
-
placeholder: 'Select...',
|
|
1826
|
-
value: [
|
|
1827
|
-
{ id: 'true', value: 'true', label: 'True' },
|
|
1828
|
-
{ id: 'false', value: 'false', label: 'False' },
|
|
1829
|
-
],
|
|
1830
|
-
required: true,
|
|
1831
|
-
},
|
|
1832
|
-
debounce_messages: {
|
|
1833
|
-
id: 'debounce_messages',
|
|
1834
|
-
type: 'dropdown',
|
|
1835
|
-
label: 'Enable Cooldown Period',
|
|
1836
|
-
placeholder: 'Select...',
|
|
1837
|
-
value: [
|
|
1838
|
-
{ id: 'true', value: 'true', label: 'True' },
|
|
1839
|
-
{ id: 'false', value: 'false', label: 'False' },
|
|
1840
|
-
],
|
|
1841
|
-
info: 'If enabled, only one message per chat will be sent in the specified cooldown period',
|
|
1842
|
-
required: false,
|
|
1843
|
-
},
|
|
1844
|
-
debounce_message_time: {
|
|
1845
|
-
id: 'debounce_message_time',
|
|
1846
|
-
type: 'dynamic',
|
|
1847
|
-
label: 'Cooldown Period',
|
|
1848
|
-
placeholder: 'Enter time',
|
|
1849
|
-
value: 'custom_duration',
|
|
1850
|
-
required: false,
|
|
1851
|
-
},
|
|
1852
|
-
},
|
|
1853
|
-
validTriggers: [
|
|
1854
|
-
'message.created',
|
|
1855
|
-
'call.created',
|
|
1856
|
-
'message.updated',
|
|
1857
|
-
'chat.created',
|
|
1858
|
-
'ticket.updated',
|
|
1859
|
-
'ticket.created',
|
|
1860
|
-
'reaction.added',
|
|
1861
|
-
'message.flagged',
|
|
1862
|
-
'message.unflagged',
|
|
1863
|
-
'chat.label.updated',
|
|
1864
|
-
'message.deleted',
|
|
1865
|
-
'ticket.closed',
|
|
1866
|
-
'task.created',
|
|
1867
|
-
'task.assignee.updated',
|
|
1868
|
-
'ticket.label.updated',
|
|
1869
|
-
'member.joined',
|
|
1870
|
-
],
|
|
1871
|
-
validate: () => true,
|
|
1872
|
-
},
|
|
1873
1771
|
delete_message: {
|
|
1874
1772
|
title: 'Delete Message',
|
|
1875
1773
|
description: 'Delete a message',
|
|
@@ -2673,417 +2571,417 @@ export const editorVariables: Array<{
|
|
|
2673
2571
|
value: editorVariablesList;
|
|
2674
2572
|
validTriggers: Rule['trigger'][];
|
|
2675
2573
|
}> = [
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2834
|
-
|
|
2835
|
-
|
|
2836
|
-
|
|
2837
|
-
|
|
2838
|
-
|
|
2839
|
-
|
|
2840
|
-
|
|
2841
|
-
|
|
2842
|
-
|
|
2843
|
-
|
|
2844
|
-
|
|
2845
|
-
|
|
2846
|
-
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2872
|
-
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2877
|
-
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
2967
|
-
|
|
2968
|
-
|
|
2969
|
-
|
|
2970
|
-
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
2974
|
-
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
2985
|
-
|
|
2986
|
-
|
|
2987
|
-
|
|
2988
|
-
|
|
2989
|
-
|
|
2990
|
-
|
|
2991
|
-
|
|
2992
|
-
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
|
|
2999
|
-
|
|
3000
|
-
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3005
|
-
|
|
3006
|
-
|
|
3007
|
-
|
|
3008
|
-
|
|
3009
|
-
|
|
3010
|
-
|
|
3011
|
-
|
|
3012
|
-
|
|
3013
|
-
|
|
3014
|
-
|
|
3015
|
-
|
|
3016
|
-
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
|
|
3048
|
-
|
|
3049
|
-
|
|
3050
|
-
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
|
|
3058
|
-
|
|
3059
|
-
|
|
3060
|
-
|
|
3061
|
-
|
|
3062
|
-
|
|
3063
|
-
|
|
3064
|
-
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
|
|
3068
|
-
|
|
3069
|
-
|
|
3070
|
-
|
|
3071
|
-
|
|
3072
|
-
|
|
3073
|
-
|
|
3074
|
-
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3078
|
-
|
|
3079
|
-
|
|
3080
|
-
|
|
3081
|
-
|
|
3082
|
-
|
|
3083
|
-
|
|
3084
|
-
|
|
3085
|
-
|
|
3086
|
-
];
|
|
2574
|
+
{
|
|
2575
|
+
label: 'Ticket ID',
|
|
2576
|
+
value: 'ticket.ticket_id',
|
|
2577
|
+
validTriggers: [
|
|
2578
|
+
'ticket.updated',
|
|
2579
|
+
'ticket.created',
|
|
2580
|
+
'ticket.closed',
|
|
2581
|
+
'ticket.label.updated',
|
|
2582
|
+
],
|
|
2583
|
+
},
|
|
2584
|
+
{
|
|
2585
|
+
value: 'ticket.assignee',
|
|
2586
|
+
label: 'Ticket Assignee',
|
|
2587
|
+
validTriggers: [
|
|
2588
|
+
'ticket.updated',
|
|
2589
|
+
'ticket.created',
|
|
2590
|
+
'ticket.closed',
|
|
2591
|
+
'ticket.label.updated',
|
|
2592
|
+
],
|
|
2593
|
+
},
|
|
2594
|
+
{
|
|
2595
|
+
value: 'ticket.due_date',
|
|
2596
|
+
label: 'Ticket Due Date',
|
|
2597
|
+
validTriggers: [
|
|
2598
|
+
'ticket.updated',
|
|
2599
|
+
'ticket.created',
|
|
2600
|
+
'ticket.closed',
|
|
2601
|
+
'ticket.label.updated',
|
|
2602
|
+
],
|
|
2603
|
+
},
|
|
2604
|
+
{
|
|
2605
|
+
value: 'ticket.priority',
|
|
2606
|
+
label: 'Ticket Priority',
|
|
2607
|
+
validTriggers: [
|
|
2608
|
+
'ticket.updated',
|
|
2609
|
+
'ticket.created',
|
|
2610
|
+
'ticket.closed',
|
|
2611
|
+
'ticket.label.updated',
|
|
2612
|
+
],
|
|
2613
|
+
},
|
|
2614
|
+
{
|
|
2615
|
+
value: 'ticket.status',
|
|
2616
|
+
label: 'Ticket Status',
|
|
2617
|
+
validTriggers: [
|
|
2618
|
+
'ticket.updated',
|
|
2619
|
+
'ticket.created',
|
|
2620
|
+
'ticket.closed',
|
|
2621
|
+
'ticket.label.updated',
|
|
2622
|
+
],
|
|
2623
|
+
},
|
|
2624
|
+
{
|
|
2625
|
+
value: 'ticket.subject',
|
|
2626
|
+
label: 'Ticket Subject',
|
|
2627
|
+
validTriggers: [
|
|
2628
|
+
'ticket.updated',
|
|
2629
|
+
'ticket.created',
|
|
2630
|
+
'ticket.closed',
|
|
2631
|
+
'ticket.label.updated',
|
|
2632
|
+
],
|
|
2633
|
+
},
|
|
2634
|
+
{
|
|
2635
|
+
label: 'Message Body',
|
|
2636
|
+
value: 'message.body',
|
|
2637
|
+
validTriggers: [
|
|
2638
|
+
'message.created',
|
|
2639
|
+
'message.updated',
|
|
2640
|
+
'reaction.added',
|
|
2641
|
+
'message.flagged',
|
|
2642
|
+
'ticket.created',
|
|
2643
|
+
'ticket.updated',
|
|
2644
|
+
'ticket.closed',
|
|
2645
|
+
'ticket.label.updated',
|
|
2646
|
+
'message.deleted',
|
|
2647
|
+
'task.created',
|
|
2648
|
+
'task.assignee.updated',
|
|
2649
|
+
],
|
|
2650
|
+
},
|
|
2651
|
+
{
|
|
2652
|
+
value: 'message.media',
|
|
2653
|
+
label: 'Message Media',
|
|
2654
|
+
validTriggers: [
|
|
2655
|
+
'message.created',
|
|
2656
|
+
'message.updated',
|
|
2657
|
+
'reaction.added',
|
|
2658
|
+
'message.flagged',
|
|
2659
|
+
'ticket.created',
|
|
2660
|
+
'ticket.updated',
|
|
2661
|
+
'ticket.closed',
|
|
2662
|
+
'ticket.label.updated',
|
|
2663
|
+
'message.deleted',
|
|
2664
|
+
],
|
|
2665
|
+
},
|
|
2666
|
+
{
|
|
2667
|
+
value: 'message.message_id',
|
|
2668
|
+
label: 'Message ID',
|
|
2669
|
+
validTriggers: [
|
|
2670
|
+
'message.created',
|
|
2671
|
+
'message.updated',
|
|
2672
|
+
'reaction.added',
|
|
2673
|
+
'message.flagged',
|
|
2674
|
+
'ticket.created',
|
|
2675
|
+
'ticket.updated',
|
|
2676
|
+
'ticket.closed',
|
|
2677
|
+
'ticket.label.updated',
|
|
2678
|
+
'message.deleted',
|
|
2679
|
+
],
|
|
2680
|
+
},
|
|
2681
|
+
{
|
|
2682
|
+
value: 'message.message_type',
|
|
2683
|
+
label: 'Message Type',
|
|
2684
|
+
validTriggers: [
|
|
2685
|
+
'message.created',
|
|
2686
|
+
'message.updated',
|
|
2687
|
+
'reaction.added',
|
|
2688
|
+
'message.flagged',
|
|
2689
|
+
'ticket.created',
|
|
2690
|
+
'ticket.updated',
|
|
2691
|
+
'ticket.closed',
|
|
2692
|
+
'ticket.label.updated',
|
|
2693
|
+
'message.deleted',
|
|
2694
|
+
'task.created',
|
|
2695
|
+
'task.assignee.updated',
|
|
2696
|
+
],
|
|
2697
|
+
},
|
|
2698
|
+
{
|
|
2699
|
+
value: 'message.sender_phone',
|
|
2700
|
+
label: 'Sender Phone',
|
|
2701
|
+
validTriggers: [
|
|
2702
|
+
'message.created',
|
|
2703
|
+
'message.updated',
|
|
2704
|
+
'reaction.added',
|
|
2705
|
+
'message.flagged',
|
|
2706
|
+
'ticket.created',
|
|
2707
|
+
'ticket.updated',
|
|
2708
|
+
'ticket.closed',
|
|
2709
|
+
'ticket.label.updated',
|
|
2710
|
+
'message.deleted',
|
|
2711
|
+
],
|
|
2712
|
+
},
|
|
2713
|
+
{
|
|
2714
|
+
value: 'message.timestamp',
|
|
2715
|
+
label: 'Message Timestamp',
|
|
2716
|
+
validTriggers: [
|
|
2717
|
+
'message.created',
|
|
2718
|
+
'message.updated',
|
|
2719
|
+
'reaction.added',
|
|
2720
|
+
'message.flagged',
|
|
2721
|
+
'ticket.created',
|
|
2722
|
+
'ticket.updated',
|
|
2723
|
+
'ticket.closed',
|
|
2724
|
+
'ticket.label.updated',
|
|
2725
|
+
'message.deleted',
|
|
2726
|
+
'task.created',
|
|
2727
|
+
'task.assignee.updated',
|
|
2728
|
+
],
|
|
2729
|
+
},
|
|
2730
|
+
{
|
|
2731
|
+
value: 'sender.contact_name',
|
|
2732
|
+
label: 'Sender Name',
|
|
2733
|
+
validTriggers: [
|
|
2734
|
+
'message.created',
|
|
2735
|
+
'message.updated',
|
|
2736
|
+
'reaction.added',
|
|
2737
|
+
'message.flagged',
|
|
2738
|
+
'ticket.created',
|
|
2739
|
+
'ticket.updated',
|
|
2740
|
+
'ticket.closed',
|
|
2741
|
+
'ticket.label.updated',
|
|
2742
|
+
'message.deleted',
|
|
2743
|
+
'task.created',
|
|
2744
|
+
'task.assignee.updated',
|
|
2745
|
+
],
|
|
2746
|
+
},
|
|
2747
|
+
{
|
|
2748
|
+
value: 'sender.is_admin',
|
|
2749
|
+
label: 'Sender Is Admin',
|
|
2750
|
+
validTriggers: [
|
|
2751
|
+
'message.created',
|
|
2752
|
+
'message.updated',
|
|
2753
|
+
'reaction.added',
|
|
2754
|
+
'message.flagged',
|
|
2755
|
+
'ticket.created',
|
|
2756
|
+
'ticket.updated',
|
|
2757
|
+
'ticket.closed',
|
|
2758
|
+
'ticket.label.updated',
|
|
2759
|
+
'message.deleted',
|
|
2760
|
+
'task.created',
|
|
2761
|
+
'task.assignee.updated',
|
|
2762
|
+
],
|
|
2763
|
+
},
|
|
2764
|
+
{
|
|
2765
|
+
value: 'sender.is_internal',
|
|
2766
|
+
label: 'Sender Is Internal',
|
|
2767
|
+
validTriggers: [
|
|
2768
|
+
'message.created',
|
|
2769
|
+
'message.updated',
|
|
2770
|
+
'reaction.added',
|
|
2771
|
+
'message.flagged',
|
|
2772
|
+
'ticket.created',
|
|
2773
|
+
'ticket.updated',
|
|
2774
|
+
'ticket.closed',
|
|
2775
|
+
'ticket.label.updated',
|
|
2776
|
+
'message.deleted',
|
|
2777
|
+
'task.created',
|
|
2778
|
+
'task.assignee.updated',
|
|
2779
|
+
],
|
|
2780
|
+
},
|
|
2781
|
+
{
|
|
2782
|
+
value: 'reaction.reaction',
|
|
2783
|
+
label: 'Reaction',
|
|
2784
|
+
validTriggers: ['reaction.added'],
|
|
2785
|
+
},
|
|
2786
|
+
{
|
|
2787
|
+
value: 'reaction.sender_id',
|
|
2788
|
+
label: 'Reaction Sender Phone',
|
|
2789
|
+
validTriggers: ['reaction.added'],
|
|
2790
|
+
},
|
|
2791
|
+
{
|
|
2792
|
+
label: 'Chat Name',
|
|
2793
|
+
value: 'chat.chat_name',
|
|
2794
|
+
validTriggers: [
|
|
2795
|
+
'message.created',
|
|
2796
|
+
'call.created',
|
|
2797
|
+
'message.updated',
|
|
2798
|
+
'reaction.added',
|
|
2799
|
+
'message.flagged',
|
|
2800
|
+
'chat.created',
|
|
2801
|
+
'chat.label.updated',
|
|
2802
|
+
'ticket.created',
|
|
2803
|
+
'ticket.updated',
|
|
2804
|
+
'ticket.closed',
|
|
2805
|
+
'ticket.label.updated',
|
|
2806
|
+
'message.deleted',
|
|
2807
|
+
'task.created',
|
|
2808
|
+
'task.assignee.updated',
|
|
2809
|
+
],
|
|
2810
|
+
},
|
|
2811
|
+
{
|
|
2812
|
+
value: 'chat.assigned_to',
|
|
2813
|
+
label: 'Chat Assigned To',
|
|
2814
|
+
validTriggers: [
|
|
2815
|
+
'message.created',
|
|
2816
|
+
'call.created',
|
|
2817
|
+
'message.updated',
|
|
2818
|
+
'reaction.added',
|
|
2819
|
+
'message.flagged',
|
|
2820
|
+
'chat.created',
|
|
2821
|
+
'chat.label.updated',
|
|
2822
|
+
'ticket.created',
|
|
2823
|
+
'ticket.updated',
|
|
2824
|
+
'ticket.closed',
|
|
2825
|
+
'ticket.label.updated',
|
|
2826
|
+
'message.deleted',
|
|
2827
|
+
'task.created',
|
|
2828
|
+
'task.assignee.updated',
|
|
2829
|
+
],
|
|
2830
|
+
},
|
|
2831
|
+
{
|
|
2832
|
+
value: 'chat.assignee_name',
|
|
2833
|
+
label: 'Chat Assignee Name',
|
|
2834
|
+
validTriggers: [
|
|
2835
|
+
'message.created',
|
|
2836
|
+
'call.created',
|
|
2837
|
+
'message.updated',
|
|
2838
|
+
'reaction.added',
|
|
2839
|
+
'message.flagged',
|
|
2840
|
+
'chat.created',
|
|
2841
|
+
'chat.label.updated',
|
|
2842
|
+
'ticket.created',
|
|
2843
|
+
'ticket.updated',
|
|
2844
|
+
'ticket.closed',
|
|
2845
|
+
'message.deleted',
|
|
2846
|
+
'task.created',
|
|
2847
|
+
'task.assignee.updated',
|
|
2848
|
+
],
|
|
2849
|
+
},
|
|
2850
|
+
{
|
|
2851
|
+
value: 'chat.chat_id',
|
|
2852
|
+
label: 'Chat ID',
|
|
2853
|
+
validTriggers: [
|
|
2854
|
+
'message.created',
|
|
2855
|
+
'call.created',
|
|
2856
|
+
'message.updated',
|
|
2857
|
+
'reaction.added',
|
|
2858
|
+
'message.flagged',
|
|
2859
|
+
'chat.created',
|
|
2860
|
+
'chat.label.updated',
|
|
2861
|
+
'ticket.created',
|
|
2862
|
+
'ticket.updated',
|
|
2863
|
+
'ticket.closed',
|
|
2864
|
+
'ticket.label.updated',
|
|
2865
|
+
'message.deleted',
|
|
2866
|
+
'task.created',
|
|
2867
|
+
'task.assignee.updated',
|
|
2868
|
+
],
|
|
2869
|
+
},
|
|
2870
|
+
{
|
|
2871
|
+
value: 'chat.chat_type',
|
|
2872
|
+
label: 'Chat Type',
|
|
2873
|
+
validTriggers: [
|
|
2874
|
+
'message.created',
|
|
2875
|
+
'call.created',
|
|
2876
|
+
'message.updated',
|
|
2877
|
+
'reaction.added',
|
|
2878
|
+
'message.flagged',
|
|
2879
|
+
'chat.created',
|
|
2880
|
+
'chat.label.updated',
|
|
2881
|
+
'ticket.created',
|
|
2882
|
+
'ticket.updated',
|
|
2883
|
+
'ticket.closed',
|
|
2884
|
+
'message.deleted',
|
|
2885
|
+
'task.created',
|
|
2886
|
+
'task.assignee.updated',
|
|
2887
|
+
],
|
|
2888
|
+
},
|
|
2889
|
+
{
|
|
2890
|
+
value: 'chat.org_id',
|
|
2891
|
+
label: 'Chat Org ID',
|
|
2892
|
+
validTriggers: [
|
|
2893
|
+
'message.created',
|
|
2894
|
+
'call.created',
|
|
2895
|
+
'message.updated',
|
|
2896
|
+
'reaction.added',
|
|
2897
|
+
'message.flagged',
|
|
2898
|
+
'chat.created',
|
|
2899
|
+
'chat.label.updated',
|
|
2900
|
+
'ticket.created',
|
|
2901
|
+
'ticket.updated',
|
|
2902
|
+
'ticket.closed',
|
|
2903
|
+
'ticket.label.updated',
|
|
2904
|
+
'message.deleted',
|
|
2905
|
+
'task.created',
|
|
2906
|
+
'task.assignee.updated',
|
|
2907
|
+
],
|
|
2908
|
+
},
|
|
2909
|
+
{
|
|
2910
|
+
value: 'chat.org_phone',
|
|
2911
|
+
label: 'Chat Org Phone',
|
|
2912
|
+
validTriggers: [
|
|
2913
|
+
'message.created',
|
|
2914
|
+
'call.created',
|
|
2915
|
+
'message.updated',
|
|
2916
|
+
'reaction.added',
|
|
2917
|
+
'message.flagged',
|
|
2918
|
+
'chat.created',
|
|
2919
|
+
'chat.label.updated',
|
|
2920
|
+
'ticket.created',
|
|
2921
|
+
'ticket.updated',
|
|
2922
|
+
'ticket.closed',
|
|
2923
|
+
'ticket.label.updated',
|
|
2924
|
+
'message.deleted',
|
|
2925
|
+
'task.created',
|
|
2926
|
+
'task.assignee.updated',
|
|
2927
|
+
],
|
|
2928
|
+
},
|
|
2929
|
+
{
|
|
2930
|
+
value: 'task.title',
|
|
2931
|
+
label: 'Task Title',
|
|
2932
|
+
validTriggers: ['task.created', 'task.assignee.updated'],
|
|
2933
|
+
},
|
|
2934
|
+
{
|
|
2935
|
+
value: 'task.assignee',
|
|
2936
|
+
label: 'Task Assignee',
|
|
2937
|
+
validTriggers: ['task.created', 'task.assignee.updated'],
|
|
2938
|
+
},
|
|
2939
|
+
{
|
|
2940
|
+
value: 'task.due_date',
|
|
2941
|
+
label: 'Task Due Date',
|
|
2942
|
+
validTriggers: ['task.created', 'task.assignee.updated'],
|
|
2943
|
+
},
|
|
2944
|
+
{
|
|
2945
|
+
value: 'task.task_id',
|
|
2946
|
+
label: 'Task ID',
|
|
2947
|
+
validTriggers: ['task.created', 'task.assignee.updated'],
|
|
2948
|
+
},
|
|
2949
|
+
{
|
|
2950
|
+
value: 'task.notes',
|
|
2951
|
+
label: 'Task Notes',
|
|
2952
|
+
validTriggers: ['task.created', 'task.assignee.updated'],
|
|
2953
|
+
},
|
|
2954
|
+
{
|
|
2955
|
+
value: 'call_notification.author',
|
|
2956
|
+
label: 'Caller Phone',
|
|
2957
|
+
validTriggers: ['call.created'],
|
|
2958
|
+
},
|
|
2959
|
+
{
|
|
2960
|
+
value: 'call_notification.call_result',
|
|
2961
|
+
label: 'Call Status',
|
|
2962
|
+
validTriggers: ['call.created'],
|
|
2963
|
+
},
|
|
2964
|
+
{
|
|
2965
|
+
value: 'call_notification.timestamp',
|
|
2966
|
+
label: 'Call Timestamp',
|
|
2967
|
+
validTriggers: ['call.created'],
|
|
2968
|
+
},
|
|
2969
|
+
{
|
|
2970
|
+
value: 'member_notification.timestamp',
|
|
2971
|
+
label: 'Member Join Timestamp',
|
|
2972
|
+
validTriggers: ['member.joined'],
|
|
2973
|
+
},
|
|
2974
|
+
{
|
|
2975
|
+
value: 'member_notification.recipientids',
|
|
2976
|
+
label: 'Member Contact IDs',
|
|
2977
|
+
validTriggers: ['member.joined'],
|
|
2978
|
+
},
|
|
2979
|
+
{
|
|
2980
|
+
value: 'member_notification.type',
|
|
2981
|
+
label: 'Member Notification Type',
|
|
2982
|
+
validTriggers: ['member.joined'],
|
|
2983
|
+
},
|
|
2984
|
+
];
|
|
3087
2985
|
|
|
3088
2986
|
export const variablesExclusionList: Record<
|
|
3089
2987
|
TriggerRuleType,
|
|
@@ -3095,9 +2993,9 @@ export const variablesExclusionList: Record<
|
|
|
3095
2993
|
| keyof AppendTypes<{ reaction: ReactionVariablesType }, '.'>
|
|
3096
2994
|
| keyof AppendTypes<{ task: TaskVariablesType }, '.'>
|
|
3097
2995
|
| keyof AppendTypes<
|
|
3098
|
-
|
|
3099
|
-
|
|
3100
|
-
|
|
2996
|
+
{ call_notification: CallNotificationVariablesType },
|
|
2997
|
+
'.'
|
|
2998
|
+
>
|
|
3101
2999
|
>
|
|
3102
3000
|
> = {
|
|
3103
3001
|
'ticket.created': ['ticket.is_deleted'],
|