@periskope/types 0.6.465 → 0.6.467
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/billing.types.d.ts +75 -0
- package/dist/billing.types.d.ts.map +1 -1
- package/dist/rules.types.d.ts +7 -3
- package/dist/rules.types.d.ts.map +1 -1
- package/dist/rules.types.js +16 -0
- package/dist/supabase.types.d.ts +269 -133
- package/dist/supabase.types.d.ts.map +1 -1
- package/dist/supabase.types.js +2 -1
- package/dist/types.d.ts +19 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/billing.types.ts +92 -1
- package/src/rules.types.ts +17 -0
- package/src/supabase.types.ts +283 -154
- package/src/types.ts +20 -0
- package/tsconfig.tsbuildinfo +1 -1
package/dist/supabase.types.d.ts
CHANGED
|
@@ -796,6 +796,60 @@ export type Database = {
|
|
|
796
796
|
};
|
|
797
797
|
Relationships: [];
|
|
798
798
|
};
|
|
799
|
+
tbl_ai_training_runs: {
|
|
800
|
+
Row: {
|
|
801
|
+
attempts: number;
|
|
802
|
+
created_at: string;
|
|
803
|
+
created_count: number | null;
|
|
804
|
+
dispatched_at: string | null;
|
|
805
|
+
error: string | null;
|
|
806
|
+
org_id: string;
|
|
807
|
+
performed_at: string | null;
|
|
808
|
+
period_end: string;
|
|
809
|
+
period_start: string;
|
|
810
|
+
run_id: string;
|
|
811
|
+
status: Database["public"]["Enums"]["enum_ai_training_runs_status"];
|
|
812
|
+
trigger: Database["public"]["Enums"]["enum_ai_training_runs_trigger"];
|
|
813
|
+
updated_at: string;
|
|
814
|
+
updated_count: number | null;
|
|
815
|
+
week_start: string;
|
|
816
|
+
};
|
|
817
|
+
Insert: {
|
|
818
|
+
attempts?: number;
|
|
819
|
+
created_at?: string;
|
|
820
|
+
created_count?: number | null;
|
|
821
|
+
dispatched_at?: string | null;
|
|
822
|
+
error?: string | null;
|
|
823
|
+
org_id: string;
|
|
824
|
+
performed_at?: string | null;
|
|
825
|
+
period_end: string;
|
|
826
|
+
period_start: string;
|
|
827
|
+
run_id?: string;
|
|
828
|
+
status?: Database["public"]["Enums"]["enum_ai_training_runs_status"];
|
|
829
|
+
trigger?: Database["public"]["Enums"]["enum_ai_training_runs_trigger"];
|
|
830
|
+
updated_at?: string;
|
|
831
|
+
updated_count?: number | null;
|
|
832
|
+
week_start: string;
|
|
833
|
+
};
|
|
834
|
+
Update: {
|
|
835
|
+
attempts?: number;
|
|
836
|
+
created_at?: string;
|
|
837
|
+
created_count?: number | null;
|
|
838
|
+
dispatched_at?: string | null;
|
|
839
|
+
error?: string | null;
|
|
840
|
+
org_id?: string;
|
|
841
|
+
performed_at?: string | null;
|
|
842
|
+
period_end?: string;
|
|
843
|
+
period_start?: string;
|
|
844
|
+
run_id?: string;
|
|
845
|
+
status?: Database["public"]["Enums"]["enum_ai_training_runs_status"];
|
|
846
|
+
trigger?: Database["public"]["Enums"]["enum_ai_training_runs_trigger"];
|
|
847
|
+
updated_at?: string;
|
|
848
|
+
updated_count?: number | null;
|
|
849
|
+
week_start?: string;
|
|
850
|
+
};
|
|
851
|
+
Relationships: [];
|
|
852
|
+
};
|
|
799
853
|
tbl_api_logs: {
|
|
800
854
|
Row: {
|
|
801
855
|
org_id: string;
|
|
@@ -832,6 +886,73 @@ export type Database = {
|
|
|
832
886
|
};
|
|
833
887
|
Relationships: [];
|
|
834
888
|
};
|
|
889
|
+
tbl_api_tokens: {
|
|
890
|
+
Row: {
|
|
891
|
+
exp: string;
|
|
892
|
+
iat: string;
|
|
893
|
+
id: string;
|
|
894
|
+
is_revealed: boolean;
|
|
895
|
+
name: string;
|
|
896
|
+
org_id: string;
|
|
897
|
+
refresh_token_hash: string | null;
|
|
898
|
+
role: string;
|
|
899
|
+
token: string;
|
|
900
|
+
token_hash: string;
|
|
901
|
+
token_metadata: Json;
|
|
902
|
+
type: string;
|
|
903
|
+
};
|
|
904
|
+
Insert: {
|
|
905
|
+
exp: string;
|
|
906
|
+
iat: string;
|
|
907
|
+
id: string;
|
|
908
|
+
is_revealed?: boolean;
|
|
909
|
+
name: string;
|
|
910
|
+
org_id: string;
|
|
911
|
+
refresh_token_hash?: string | null;
|
|
912
|
+
role: string;
|
|
913
|
+
token: string;
|
|
914
|
+
token_hash: string;
|
|
915
|
+
token_metadata?: Json;
|
|
916
|
+
type: string;
|
|
917
|
+
};
|
|
918
|
+
Update: {
|
|
919
|
+
exp?: string;
|
|
920
|
+
iat?: string;
|
|
921
|
+
id?: string;
|
|
922
|
+
is_revealed?: boolean;
|
|
923
|
+
name?: string;
|
|
924
|
+
org_id?: string;
|
|
925
|
+
refresh_token_hash?: string | null;
|
|
926
|
+
role?: string;
|
|
927
|
+
token?: string;
|
|
928
|
+
token_hash?: string;
|
|
929
|
+
token_metadata?: Json;
|
|
930
|
+
type?: string;
|
|
931
|
+
};
|
|
932
|
+
Relationships: [
|
|
933
|
+
{
|
|
934
|
+
foreignKeyName: "tbl_api_tokens_org_id_fkey";
|
|
935
|
+
columns: ["org_id"];
|
|
936
|
+
isOneToOne: false;
|
|
937
|
+
referencedRelation: "tbl_org";
|
|
938
|
+
referencedColumns: ["org_id"];
|
|
939
|
+
},
|
|
940
|
+
{
|
|
941
|
+
foreignKeyName: "tbl_api_tokens_org_id_fkey";
|
|
942
|
+
columns: ["org_id"];
|
|
943
|
+
isOneToOne: false;
|
|
944
|
+
referencedRelation: "view_org";
|
|
945
|
+
referencedColumns: ["org_id"];
|
|
946
|
+
},
|
|
947
|
+
{
|
|
948
|
+
foreignKeyName: "tbl_api_tokens_org_id_fkey";
|
|
949
|
+
columns: ["org_id"];
|
|
950
|
+
isOneToOne: false;
|
|
951
|
+
referencedRelation: "view_org_all";
|
|
952
|
+
referencedColumns: ["org_id"];
|
|
953
|
+
}
|
|
954
|
+
];
|
|
955
|
+
};
|
|
835
956
|
tbl_automation_rules: {
|
|
836
957
|
Row: {
|
|
837
958
|
actions: Json;
|
|
@@ -897,29 +1018,29 @@ export type Database = {
|
|
|
897
1018
|
Row: {
|
|
898
1019
|
chat_ids: string[];
|
|
899
1020
|
created_at: string;
|
|
900
|
-
updated_at: string | null;
|
|
901
1021
|
created_by: string | null;
|
|
902
1022
|
org_id: string;
|
|
903
1023
|
template_id: string;
|
|
904
1024
|
template_name: string;
|
|
1025
|
+
updated_at: string | null;
|
|
905
1026
|
};
|
|
906
1027
|
Insert: {
|
|
907
1028
|
chat_ids?: string[];
|
|
908
1029
|
created_at?: string;
|
|
909
|
-
updated_at?: string | null;
|
|
910
1030
|
created_by?: string | null;
|
|
911
1031
|
org_id: string;
|
|
912
1032
|
template_id?: string;
|
|
913
1033
|
template_name: string;
|
|
1034
|
+
updated_at?: string | null;
|
|
914
1035
|
};
|
|
915
1036
|
Update: {
|
|
916
1037
|
chat_ids?: string[];
|
|
917
1038
|
created_at?: string;
|
|
918
|
-
updated_at?: string | null;
|
|
919
1039
|
created_by?: string | null;
|
|
920
1040
|
org_id?: string;
|
|
921
1041
|
template_id?: string;
|
|
922
1042
|
template_name?: string;
|
|
1043
|
+
updated_at?: string | null;
|
|
923
1044
|
};
|
|
924
1045
|
Relationships: [
|
|
925
1046
|
{
|
|
@@ -958,9 +1079,9 @@ export type Database = {
|
|
|
958
1079
|
message_id: string | null;
|
|
959
1080
|
org_id: string;
|
|
960
1081
|
org_phone: string | null;
|
|
1082
|
+
poll_results: Json | null;
|
|
961
1083
|
read_count: number | null;
|
|
962
1084
|
remarks: string | null;
|
|
963
|
-
poll_results: Json | null;
|
|
964
1085
|
};
|
|
965
1086
|
Insert: {
|
|
966
1087
|
broadcast_id: string;
|
|
@@ -974,9 +1095,9 @@ export type Database = {
|
|
|
974
1095
|
message_id?: string | null;
|
|
975
1096
|
org_id: string;
|
|
976
1097
|
org_phone?: string | null;
|
|
1098
|
+
poll_results?: Json | null;
|
|
977
1099
|
read_count?: number | null;
|
|
978
1100
|
remarks?: string | null;
|
|
979
|
-
poll_results?: Json | null;
|
|
980
1101
|
};
|
|
981
1102
|
Update: {
|
|
982
1103
|
broadcast_id?: string;
|
|
@@ -990,9 +1111,9 @@ export type Database = {
|
|
|
990
1111
|
message_id?: string | null;
|
|
991
1112
|
org_id?: string;
|
|
992
1113
|
org_phone?: string | null;
|
|
1114
|
+
poll_results?: Json | null;
|
|
993
1115
|
read_count?: number | null;
|
|
994
1116
|
remarks?: string | null;
|
|
995
|
-
poll_results?: Json | null;
|
|
996
1117
|
};
|
|
997
1118
|
Relationships: [
|
|
998
1119
|
{
|
|
@@ -1163,6 +1284,42 @@ export type Database = {
|
|
|
1163
1284
|
}
|
|
1164
1285
|
];
|
|
1165
1286
|
};
|
|
1287
|
+
tbl_chat_audit_logs: {
|
|
1288
|
+
Row: {
|
|
1289
|
+
action: string | null;
|
|
1290
|
+
chat_id: string | null;
|
|
1291
|
+
log_id: string;
|
|
1292
|
+
new_record: Json | null;
|
|
1293
|
+
old_record: Json | null;
|
|
1294
|
+
org_id: string | null;
|
|
1295
|
+
performed_by: string | null;
|
|
1296
|
+
timestamp: string;
|
|
1297
|
+
type: string | null;
|
|
1298
|
+
};
|
|
1299
|
+
Insert: {
|
|
1300
|
+
action?: string | null;
|
|
1301
|
+
chat_id?: string | null;
|
|
1302
|
+
log_id?: string;
|
|
1303
|
+
new_record?: Json | null;
|
|
1304
|
+
old_record?: Json | null;
|
|
1305
|
+
org_id?: string | null;
|
|
1306
|
+
performed_by?: string | null;
|
|
1307
|
+
timestamp?: string;
|
|
1308
|
+
type?: string | null;
|
|
1309
|
+
};
|
|
1310
|
+
Update: {
|
|
1311
|
+
action?: string | null;
|
|
1312
|
+
chat_id?: string | null;
|
|
1313
|
+
log_id?: string;
|
|
1314
|
+
new_record?: Json | null;
|
|
1315
|
+
old_record?: Json | null;
|
|
1316
|
+
org_id?: string | null;
|
|
1317
|
+
performed_by?: string | null;
|
|
1318
|
+
timestamp?: string;
|
|
1319
|
+
type?: string | null;
|
|
1320
|
+
};
|
|
1321
|
+
Relationships: [];
|
|
1322
|
+
};
|
|
1166
1323
|
tbl_chat_logs: {
|
|
1167
1324
|
Row: {
|
|
1168
1325
|
action: string | null;
|
|
@@ -1803,6 +1960,7 @@ export type Database = {
|
|
|
1803
1960
|
is_read_only: boolean | null;
|
|
1804
1961
|
latest_mention_at: string | null;
|
|
1805
1962
|
latest_message: Json | null;
|
|
1963
|
+
latest_message_timestamp: string | null;
|
|
1806
1964
|
member_count: number | null;
|
|
1807
1965
|
member_unread_count: Json | null;
|
|
1808
1966
|
mute_expiration: number | null;
|
|
@@ -1834,6 +1992,7 @@ export type Database = {
|
|
|
1834
1992
|
is_read_only?: boolean | null;
|
|
1835
1993
|
latest_mention_at?: string | null;
|
|
1836
1994
|
latest_message?: Json | null;
|
|
1995
|
+
latest_message_timestamp?: string | null;
|
|
1837
1996
|
member_count?: number | null;
|
|
1838
1997
|
member_unread_count?: Json | null;
|
|
1839
1998
|
mute_expiration?: number | null;
|
|
@@ -1865,6 +2024,7 @@ export type Database = {
|
|
|
1865
2024
|
is_read_only?: boolean | null;
|
|
1866
2025
|
latest_mention_at?: string | null;
|
|
1867
2026
|
latest_message?: Json | null;
|
|
2027
|
+
latest_message_timestamp?: string | null;
|
|
1868
2028
|
member_count?: number | null;
|
|
1869
2029
|
member_unread_count?: Json | null;
|
|
1870
2030
|
mute_expiration?: number | null;
|
|
@@ -2241,59 +2401,6 @@ export type Database = {
|
|
|
2241
2401
|
}
|
|
2242
2402
|
];
|
|
2243
2403
|
};
|
|
2244
|
-
tbl_api_tokens: {
|
|
2245
|
-
Row: {
|
|
2246
|
-
exp: string;
|
|
2247
|
-
iat: string;
|
|
2248
|
-
id: string;
|
|
2249
|
-
is_revealed: boolean;
|
|
2250
|
-
name: string;
|
|
2251
|
-
org_id: string;
|
|
2252
|
-
refresh_token_hash: string | null;
|
|
2253
|
-
role: string;
|
|
2254
|
-
token: string;
|
|
2255
|
-
token_hash: string;
|
|
2256
|
-
token_metadata: Json;
|
|
2257
|
-
type: string;
|
|
2258
|
-
};
|
|
2259
|
-
Insert: {
|
|
2260
|
-
exp: string;
|
|
2261
|
-
iat: string;
|
|
2262
|
-
id: string;
|
|
2263
|
-
is_revealed?: boolean;
|
|
2264
|
-
name: string;
|
|
2265
|
-
org_id: string;
|
|
2266
|
-
refresh_token_hash?: string | null;
|
|
2267
|
-
role: string;
|
|
2268
|
-
token: string;
|
|
2269
|
-
token_hash: string;
|
|
2270
|
-
token_metadata?: Json;
|
|
2271
|
-
type: string;
|
|
2272
|
-
};
|
|
2273
|
-
Update: {
|
|
2274
|
-
exp?: string;
|
|
2275
|
-
iat?: string;
|
|
2276
|
-
id?: string;
|
|
2277
|
-
is_revealed?: boolean;
|
|
2278
|
-
name?: string;
|
|
2279
|
-
org_id?: string;
|
|
2280
|
-
refresh_token_hash?: string | null;
|
|
2281
|
-
role?: string;
|
|
2282
|
-
token?: string;
|
|
2283
|
-
token_hash?: string;
|
|
2284
|
-
token_metadata?: Json;
|
|
2285
|
-
type?: string;
|
|
2286
|
-
};
|
|
2287
|
-
Relationships: [
|
|
2288
|
-
{
|
|
2289
|
-
foreignKeyName: "tbl_api_tokens_org_id_fkey";
|
|
2290
|
-
columns: ["org_id"];
|
|
2291
|
-
isOneToOne: false;
|
|
2292
|
-
referencedRelation: "tbl_org";
|
|
2293
|
-
referencedColumns: ["org_id"];
|
|
2294
|
-
}
|
|
2295
|
-
];
|
|
2296
|
-
};
|
|
2297
2404
|
tbl_integration_tokens: {
|
|
2298
2405
|
Row: {
|
|
2299
2406
|
exp: string;
|
|
@@ -2373,51 +2480,6 @@ export type Database = {
|
|
|
2373
2480
|
};
|
|
2374
2481
|
Relationships: [];
|
|
2375
2482
|
};
|
|
2376
|
-
tbl_mcp_tokens: {
|
|
2377
|
-
Row: {
|
|
2378
|
-
access_token_expires_at: string;
|
|
2379
|
-
access_token_hash: string;
|
|
2380
|
-
client_id: string;
|
|
2381
|
-
client_name: string | null;
|
|
2382
|
-
created_at: string;
|
|
2383
|
-
id: string;
|
|
2384
|
-
integration_token_id: string;
|
|
2385
|
-
org_id: string;
|
|
2386
|
-
phone_scopes: string[] | null;
|
|
2387
|
-
refresh_token_expires_at: string;
|
|
2388
|
-
refresh_token_hash: string;
|
|
2389
|
-
revoked_at: string | null;
|
|
2390
|
-
};
|
|
2391
|
-
Insert: {
|
|
2392
|
-
access_token_expires_at: string;
|
|
2393
|
-
access_token_hash: string;
|
|
2394
|
-
client_id: string;
|
|
2395
|
-
client_name?: string | null;
|
|
2396
|
-
created_at?: string;
|
|
2397
|
-
id?: string;
|
|
2398
|
-
integration_token_id: string;
|
|
2399
|
-
org_id: string;
|
|
2400
|
-
phone_scopes?: string[] | null;
|
|
2401
|
-
refresh_token_expires_at: string;
|
|
2402
|
-
refresh_token_hash: string;
|
|
2403
|
-
revoked_at?: string | null;
|
|
2404
|
-
};
|
|
2405
|
-
Update: {
|
|
2406
|
-
access_token_expires_at?: string;
|
|
2407
|
-
access_token_hash?: string;
|
|
2408
|
-
client_id?: string;
|
|
2409
|
-
client_name?: string | null;
|
|
2410
|
-
created_at?: string;
|
|
2411
|
-
id?: string;
|
|
2412
|
-
integration_token_id?: string;
|
|
2413
|
-
org_id?: string;
|
|
2414
|
-
phone_scopes?: string[] | null;
|
|
2415
|
-
refresh_token_expires_at?: string;
|
|
2416
|
-
refresh_token_hash?: string;
|
|
2417
|
-
revoked_at?: string | null;
|
|
2418
|
-
};
|
|
2419
|
-
Relationships: [];
|
|
2420
|
-
};
|
|
2421
2483
|
tbl_org: {
|
|
2422
2484
|
Row: {
|
|
2423
2485
|
ai_settings: Json | null;
|
|
@@ -2620,12 +2682,15 @@ export type Database = {
|
|
|
2620
2682
|
library: string | null;
|
|
2621
2683
|
org_id: string;
|
|
2622
2684
|
org_phone: string | null;
|
|
2685
|
+
passkey_code: string | null;
|
|
2686
|
+
passkey_request: Json | null;
|
|
2623
2687
|
phone_id: string;
|
|
2624
2688
|
phone_image: string | null;
|
|
2625
2689
|
phone_name: string | null;
|
|
2626
2690
|
phone_state: Json | null;
|
|
2627
2691
|
qr_code: string | null;
|
|
2628
2692
|
queue_status: Json | null;
|
|
2693
|
+
restriction_state: Json | null;
|
|
2629
2694
|
server_image: string | null;
|
|
2630
2695
|
server_ip: string | null;
|
|
2631
2696
|
server_name: string | null;
|
|
@@ -2645,12 +2710,15 @@ export type Database = {
|
|
|
2645
2710
|
library?: string | null;
|
|
2646
2711
|
org_id: string;
|
|
2647
2712
|
org_phone?: string | null;
|
|
2713
|
+
passkey_code?: string | null;
|
|
2714
|
+
passkey_request?: Json | null;
|
|
2648
2715
|
phone_id?: string;
|
|
2649
2716
|
phone_image?: string | null;
|
|
2650
2717
|
phone_name?: string | null;
|
|
2651
2718
|
phone_state?: Json | null;
|
|
2652
2719
|
qr_code?: string | null;
|
|
2653
2720
|
queue_status?: Json | null;
|
|
2721
|
+
restriction_state?: Json | null;
|
|
2654
2722
|
server_image?: string | null;
|
|
2655
2723
|
server_ip?: string | null;
|
|
2656
2724
|
server_name?: string | null;
|
|
@@ -2670,12 +2738,15 @@ export type Database = {
|
|
|
2670
2738
|
library?: string | null;
|
|
2671
2739
|
org_id?: string;
|
|
2672
2740
|
org_phone?: string | null;
|
|
2741
|
+
passkey_code?: string | null;
|
|
2742
|
+
passkey_request?: Json | null;
|
|
2673
2743
|
phone_id?: string;
|
|
2674
2744
|
phone_image?: string | null;
|
|
2675
2745
|
phone_name?: string | null;
|
|
2676
2746
|
phone_state?: Json | null;
|
|
2677
2747
|
qr_code?: string | null;
|
|
2678
2748
|
queue_status?: Json | null;
|
|
2749
|
+
restriction_state?: Json | null;
|
|
2679
2750
|
server_image?: string | null;
|
|
2680
2751
|
server_ip?: string | null;
|
|
2681
2752
|
server_name?: string | null;
|
|
@@ -2988,7 +3059,6 @@ export type Database = {
|
|
|
2988
3059
|
chat_ids: string[];
|
|
2989
3060
|
created_at: string;
|
|
2990
3061
|
delay: number | null;
|
|
2991
|
-
scheduled_id: string;
|
|
2992
3062
|
is_active: boolean;
|
|
2993
3063
|
message_payload: Json;
|
|
2994
3064
|
next_occurrence_at: string;
|
|
@@ -2997,6 +3067,7 @@ export type Database = {
|
|
|
2997
3067
|
org_phones: string[] | null;
|
|
2998
3068
|
performed_by: string | null;
|
|
2999
3069
|
repeat_config: Json;
|
|
3070
|
+
scheduled_id: string;
|
|
3000
3071
|
updated_at: string;
|
|
3001
3072
|
variables: Json | null;
|
|
3002
3073
|
};
|
|
@@ -3004,7 +3075,6 @@ export type Database = {
|
|
|
3004
3075
|
chat_ids: string[];
|
|
3005
3076
|
created_at?: string;
|
|
3006
3077
|
delay?: number | null;
|
|
3007
|
-
scheduled_id?: string;
|
|
3008
3078
|
is_active?: boolean;
|
|
3009
3079
|
message_payload: Json;
|
|
3010
3080
|
next_occurrence_at: string;
|
|
@@ -3013,6 +3083,7 @@ export type Database = {
|
|
|
3013
3083
|
org_phones?: string[] | null;
|
|
3014
3084
|
performed_by?: string | null;
|
|
3015
3085
|
repeat_config: Json;
|
|
3086
|
+
scheduled_id?: string;
|
|
3016
3087
|
updated_at?: string;
|
|
3017
3088
|
variables?: Json | null;
|
|
3018
3089
|
};
|
|
@@ -3020,7 +3091,6 @@ export type Database = {
|
|
|
3020
3091
|
chat_ids?: string[];
|
|
3021
3092
|
created_at?: string;
|
|
3022
3093
|
delay?: number | null;
|
|
3023
|
-
scheduled_id?: string;
|
|
3024
3094
|
is_active?: boolean;
|
|
3025
3095
|
message_payload?: Json;
|
|
3026
3096
|
next_occurrence_at?: string;
|
|
@@ -3029,6 +3099,7 @@ export type Database = {
|
|
|
3029
3099
|
org_phones?: string[] | null;
|
|
3030
3100
|
performed_by?: string | null;
|
|
3031
3101
|
repeat_config?: Json;
|
|
3102
|
+
scheduled_id?: string;
|
|
3032
3103
|
updated_at?: string;
|
|
3033
3104
|
variables?: Json | null;
|
|
3034
3105
|
};
|
|
@@ -3039,6 +3110,20 @@ export type Database = {
|
|
|
3039
3110
|
isOneToOne: false;
|
|
3040
3111
|
referencedRelation: "tbl_org";
|
|
3041
3112
|
referencedColumns: ["org_id"];
|
|
3113
|
+
},
|
|
3114
|
+
{
|
|
3115
|
+
foreignKeyName: "tbl_recurring_broadcasts_org_id_fkey";
|
|
3116
|
+
columns: ["org_id"];
|
|
3117
|
+
isOneToOne: false;
|
|
3118
|
+
referencedRelation: "view_org";
|
|
3119
|
+
referencedColumns: ["org_id"];
|
|
3120
|
+
},
|
|
3121
|
+
{
|
|
3122
|
+
foreignKeyName: "tbl_recurring_broadcasts_org_id_fkey";
|
|
3123
|
+
columns: ["org_id"];
|
|
3124
|
+
isOneToOne: false;
|
|
3125
|
+
referencedRelation: "view_org_all";
|
|
3126
|
+
referencedColumns: ["org_id"];
|
|
3042
3127
|
}
|
|
3043
3128
|
];
|
|
3044
3129
|
};
|
|
@@ -3394,6 +3479,39 @@ export type Database = {
|
|
|
3394
3479
|
}
|
|
3395
3480
|
];
|
|
3396
3481
|
};
|
|
3482
|
+
tbl_usage_records: {
|
|
3483
|
+
Row: {
|
|
3484
|
+
amount: number;
|
|
3485
|
+
created_at: string;
|
|
3486
|
+
id: string;
|
|
3487
|
+
metadata: Json | null;
|
|
3488
|
+
org_id: string;
|
|
3489
|
+
source: string;
|
|
3490
|
+
transaction_type: Database["public"]["Enums"]["enum_credit_transaction_type"];
|
|
3491
|
+
unit_type: string;
|
|
3492
|
+
};
|
|
3493
|
+
Insert: {
|
|
3494
|
+
amount?: number;
|
|
3495
|
+
created_at?: string;
|
|
3496
|
+
id?: string;
|
|
3497
|
+
metadata?: Json | null;
|
|
3498
|
+
org_id: string;
|
|
3499
|
+
source: string;
|
|
3500
|
+
transaction_type?: Database["public"]["Enums"]["enum_credit_transaction_type"];
|
|
3501
|
+
unit_type?: string;
|
|
3502
|
+
};
|
|
3503
|
+
Update: {
|
|
3504
|
+
amount?: number;
|
|
3505
|
+
created_at?: string;
|
|
3506
|
+
id?: string;
|
|
3507
|
+
metadata?: Json | null;
|
|
3508
|
+
org_id?: string;
|
|
3509
|
+
source?: string;
|
|
3510
|
+
transaction_type?: Database["public"]["Enums"]["enum_credit_transaction_type"];
|
|
3511
|
+
unit_type?: string;
|
|
3512
|
+
};
|
|
3513
|
+
Relationships: [];
|
|
3514
|
+
};
|
|
3397
3515
|
};
|
|
3398
3516
|
Views: {
|
|
3399
3517
|
view_broadcast_logs: {
|
|
@@ -3402,8 +3520,12 @@ export type Database = {
|
|
|
3402
3520
|
broadcast_status: Database["public"]["Enums"]["enum_broadcast_status"] | null;
|
|
3403
3521
|
created_at: string | null;
|
|
3404
3522
|
delivered_percentage: number | null;
|
|
3523
|
+
due_at: string | null;
|
|
3405
3524
|
failed_chats: number | null;
|
|
3525
|
+
is_active: boolean | null;
|
|
3406
3526
|
message_payload: Json | null;
|
|
3527
|
+
next_occurrence_at: string | null;
|
|
3528
|
+
occurrence_count: number | null;
|
|
3407
3529
|
org_id: string | null;
|
|
3408
3530
|
parent_broadcast_id: string | null;
|
|
3409
3531
|
pending_chats: number | null;
|
|
@@ -3411,18 +3533,14 @@ export type Database = {
|
|
|
3411
3533
|
performed_by: string | null;
|
|
3412
3534
|
previous_retries: Json | null;
|
|
3413
3535
|
read_percentage: number | null;
|
|
3536
|
+
repeat_config: Json | null;
|
|
3414
3537
|
retry_count: number | null;
|
|
3415
3538
|
scheduled_at: string | null;
|
|
3416
3539
|
sent_chats: number | null;
|
|
3417
|
-
is_active: boolean | null;
|
|
3418
|
-
next_occurrence_at: string | null;
|
|
3419
|
-
occurrence_count: number | null;
|
|
3420
|
-
repeat_config: Json | null;
|
|
3421
3540
|
total_chats: number | null;
|
|
3422
3541
|
total_delivered_count: number | null;
|
|
3423
3542
|
total_member_count: number | null;
|
|
3424
3543
|
total_read_count: number | null;
|
|
3425
|
-
due_at: string | null;
|
|
3426
3544
|
};
|
|
3427
3545
|
Relationships: [
|
|
3428
3546
|
{
|
|
@@ -3512,9 +3630,11 @@ export type Database = {
|
|
|
3512
3630
|
is_archived: boolean | null;
|
|
3513
3631
|
is_exited: boolean | null;
|
|
3514
3632
|
is_muted: boolean | null;
|
|
3633
|
+
join_approval_mode: boolean | null;
|
|
3515
3634
|
label_ids: Json | null;
|
|
3516
3635
|
latest_mention_at: string | null;
|
|
3517
3636
|
latest_message: Json | null;
|
|
3637
|
+
latest_message_timestamp: string | null;
|
|
3518
3638
|
member_closed_at: Json | null;
|
|
3519
3639
|
member_count: number | null;
|
|
3520
3640
|
member_unread_count: Json | null;
|
|
@@ -3798,12 +3918,6 @@ export type Database = {
|
|
|
3798
3918
|
};
|
|
3799
3919
|
Returns: Json[];
|
|
3800
3920
|
};
|
|
3801
|
-
get_mcp_connections: {
|
|
3802
|
-
Args: {
|
|
3803
|
-
org_id_input: string;
|
|
3804
|
-
};
|
|
3805
|
-
Returns: Json;
|
|
3806
|
-
};
|
|
3807
3921
|
get_chat_properties_by_chat_ids: {
|
|
3808
3922
|
Args: {
|
|
3809
3923
|
chat_id_input?: string[];
|
|
@@ -3871,12 +3985,23 @@ export type Database = {
|
|
|
3871
3985
|
get_counts: {
|
|
3872
3986
|
Args: {
|
|
3873
3987
|
org_id_input: string;
|
|
3874
|
-
sync_wa_unread_count?: boolean;
|
|
3875
3988
|
org_phone_input?: string[];
|
|
3989
|
+
sync_wa_unread_count?: boolean;
|
|
3876
3990
|
};
|
|
3877
3991
|
Returns: Json;
|
|
3878
3992
|
};
|
|
3879
3993
|
get_export_chats_data: {
|
|
3994
|
+
Args: {
|
|
3995
|
+
chat_id_input?: string[];
|
|
3996
|
+
chat_type_input?: string;
|
|
3997
|
+
end_date_input?: string;
|
|
3998
|
+
limit_input?: number;
|
|
3999
|
+
offset_input?: number;
|
|
4000
|
+
org_id_input: string;
|
|
4001
|
+
start_date_input?: string;
|
|
4002
|
+
};
|
|
4003
|
+
Returns: Json;
|
|
4004
|
+
} | {
|
|
3880
4005
|
Args: {
|
|
3881
4006
|
chat_id_input?: string[];
|
|
3882
4007
|
chat_type_input?: string;
|
|
@@ -3926,38 +4051,44 @@ export type Database = {
|
|
|
3926
4051
|
};
|
|
3927
4052
|
Returns: Json;
|
|
3928
4053
|
};
|
|
3929
|
-
|
|
4054
|
+
get_integration_data: {
|
|
3930
4055
|
Args: {
|
|
3931
|
-
|
|
3932
|
-
message_id_input: string;
|
|
3933
|
-
org_id_input: string;
|
|
3934
|
-
org_phone_input: string;
|
|
3935
|
-
sender_id_input: string;
|
|
4056
|
+
org_id_input?: string;
|
|
3936
4057
|
};
|
|
3937
4058
|
Returns: Json;
|
|
3938
4059
|
};
|
|
3939
|
-
|
|
4060
|
+
get_mcp_connections: {
|
|
3940
4061
|
Args: {
|
|
3941
|
-
org_id_input
|
|
4062
|
+
org_id_input: string;
|
|
3942
4063
|
};
|
|
3943
4064
|
Returns: Json;
|
|
3944
4065
|
};
|
|
3945
4066
|
get_media_library: {
|
|
3946
4067
|
Args: {
|
|
3947
|
-
org_id_input: string;
|
|
3948
|
-
type_input: string;
|
|
3949
|
-
search_query?: string;
|
|
3950
4068
|
limit_input?: number;
|
|
3951
4069
|
offset_input?: number;
|
|
4070
|
+
org_id_input: string;
|
|
4071
|
+
search_query?: string;
|
|
4072
|
+
type_input: string;
|
|
3952
4073
|
};
|
|
3953
4074
|
Returns: {
|
|
4075
|
+
created_at: string;
|
|
3954
4076
|
id: string;
|
|
4077
|
+
metadata: Json;
|
|
3955
4078
|
name: string;
|
|
3956
|
-
created_at: string;
|
|
3957
4079
|
updated_at: string;
|
|
3958
|
-
metadata: Json;
|
|
3959
4080
|
}[];
|
|
3960
4081
|
};
|
|
4082
|
+
get_message_rule_info: {
|
|
4083
|
+
Args: {
|
|
4084
|
+
chat_id_input: string;
|
|
4085
|
+
message_id_input: string;
|
|
4086
|
+
org_id_input: string;
|
|
4087
|
+
org_phone_input: string;
|
|
4088
|
+
sender_id_input: string;
|
|
4089
|
+
};
|
|
4090
|
+
Returns: Json;
|
|
4091
|
+
};
|
|
3961
4092
|
get_message_workflow_info: {
|
|
3962
4093
|
Args: {
|
|
3963
4094
|
chat_id_input: string;
|
|
@@ -4182,6 +4313,7 @@ export type Database = {
|
|
|
4182
4313
|
is_read_only: boolean | null;
|
|
4183
4314
|
latest_mention_at: string | null;
|
|
4184
4315
|
latest_message: Json | null;
|
|
4316
|
+
latest_message_timestamp: string | null;
|
|
4185
4317
|
member_count: number | null;
|
|
4186
4318
|
member_unread_count: Json | null;
|
|
4187
4319
|
mute_expiration: number | null;
|
|
@@ -4342,6 +4474,8 @@ export type Database = {
|
|
|
4342
4474
|
};
|
|
4343
4475
|
Enums: {
|
|
4344
4476
|
enum_ai_context_type: "faq" | "document" | "self-learned";
|
|
4477
|
+
enum_ai_training_runs_status: "pending" | "running" | "dispatched" | "failed" | "complete";
|
|
4478
|
+
enum_ai_training_runs_trigger: "scheduled" | "manual";
|
|
4345
4479
|
enum_broadcast_status: "inprogress" | "completed" | "stopped" | "expired";
|
|
4346
4480
|
enum_chat_colors: "#B4876E" | "#A5B337" | "#06CF9C" | "#25D366" | "#02A698" | "#7D9EF1" | "#007BFC" | "#5E47DE" | "#7F66FF" | "#9333EA" | "#FA6533" | "#C4532D" | "#DC2626" | "#FF2E74" | "#DB2777";
|
|
4347
4481
|
enum_chat_tickets_status: "open" | "inprogress" | "closed" | "archived";
|
|
@@ -4411,12 +4545,14 @@ export declare const Constants: {
|
|
|
4411
4545
|
readonly public: {
|
|
4412
4546
|
readonly Enums: {
|
|
4413
4547
|
readonly enum_ai_context_type: readonly ["faq", "document", "self-learned"];
|
|
4548
|
+
readonly enum_ai_training_runs_status: readonly ["pending", "running", "dispatched", "failed", "complete"];
|
|
4549
|
+
readonly enum_ai_training_runs_trigger: readonly ["scheduled", "manual"];
|
|
4414
4550
|
readonly enum_broadcast_status: readonly ["inprogress", "completed", "stopped", "expired"];
|
|
4415
4551
|
readonly enum_chat_colors: readonly ["#B4876E", "#A5B337", "#06CF9C", "#25D366", "#02A698", "#7D9EF1", "#007BFC", "#5E47DE", "#7F66FF", "#9333EA", "#FA6533", "#C4532D", "#DC2626", "#FF2E74", "#DB2777"];
|
|
4416
4552
|
readonly enum_chat_tickets_status: readonly ["open", "inprogress", "closed", "archived"];
|
|
4417
4553
|
readonly enum_credit_transaction_type: readonly ["credit", "debit"];
|
|
4418
4554
|
readonly enum_integration_name: readonly ["org.created", "org.updated", "org.member.created", "org.member.updated", "org.subscription.trial_will_end", "chat.created", "chat.updated", "chat.notification.created", "message.created", "message.updated", "message.deleted", "message.ack.updated", "reaction.created", "reaction.updated", "ticket.created", "ticket.updated", "ticket.deleted", "org.integrations.updated", "message.flagged", "message.unflagged", "chat.label.updated", "reaction.added", "message.ticket.attached", "org.phone.created", "org.phone.connected", "org.phone.disconnected", "org.phone.qr", "org.phone.updated", "note.created", "chat.custom_properties.updated"];
|
|
4419
|
-
readonly enum_integration_type: readonly ["zapier", "pabbly", "api", "webhook", "hubspot", "freshdesk", "slack", "jira", "salesforce", "zohodesk", "gsheets", "zohocrm"
|
|
4555
|
+
readonly enum_integration_type: readonly ["zapier", "pabbly", "api", "webhook", "hubspot", "freshdesk", "slack", "jira", "salesforce", "zohodesk", "gsheets", "zohocrm"];
|
|
4420
4556
|
readonly enum_member_role: readonly ["admin", "member"];
|
|
4421
4557
|
};
|
|
4422
4558
|
};
|