@periskope/types 0.6.25 → 0.6.27
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/supabase.types.d.ts +35 -0
- package/dist/types.d.ts +11 -1
- package/package.json +1 -1
- package/supabase.types.ts +35 -0
- package/types.ts +14 -1
package/dist/supabase.types.d.ts
CHANGED
|
@@ -33,6 +33,7 @@ export interface Database {
|
|
|
33
33
|
Row: {
|
|
34
34
|
broadcast_id: string;
|
|
35
35
|
chat_ids: string[] | null;
|
|
36
|
+
completed_at: string | null;
|
|
36
37
|
created_at: string;
|
|
37
38
|
message_payload: Json | null;
|
|
38
39
|
org_id: string;
|
|
@@ -43,6 +44,7 @@ export interface Database {
|
|
|
43
44
|
Insert: {
|
|
44
45
|
broadcast_id?: string;
|
|
45
46
|
chat_ids?: string[] | null;
|
|
47
|
+
completed_at?: string | null;
|
|
46
48
|
created_at?: string;
|
|
47
49
|
message_payload?: Json | null;
|
|
48
50
|
org_id?: string;
|
|
@@ -53,6 +55,7 @@ export interface Database {
|
|
|
53
55
|
Update: {
|
|
54
56
|
broadcast_id?: string;
|
|
55
57
|
chat_ids?: string[] | null;
|
|
58
|
+
completed_at?: string | null;
|
|
56
59
|
created_at?: string;
|
|
57
60
|
message_payload?: Json | null;
|
|
58
61
|
org_id?: string;
|
|
@@ -756,6 +759,31 @@ export interface Database {
|
|
|
756
759
|
};
|
|
757
760
|
};
|
|
758
761
|
Views: {
|
|
762
|
+
view_broadcast_logs: {
|
|
763
|
+
Row: {
|
|
764
|
+
broadcast_id: string | null;
|
|
765
|
+
completed_at: string | null;
|
|
766
|
+
delivered_member_count: number | null;
|
|
767
|
+
failed_chats: number | null;
|
|
768
|
+
message_payload: Json | null;
|
|
769
|
+
org_id: string | null;
|
|
770
|
+
read_member_count: number | null;
|
|
771
|
+
scheduled_at: string | null;
|
|
772
|
+
sent_chats: number | null;
|
|
773
|
+
status: string | null;
|
|
774
|
+
total_chats: number | null;
|
|
775
|
+
total_member_count: number | null;
|
|
776
|
+
};
|
|
777
|
+
Relationships: [
|
|
778
|
+
{
|
|
779
|
+
foreignKeyName: "tbl_broadcast_messages_org_id_fkey";
|
|
780
|
+
columns: ["org_id"];
|
|
781
|
+
isOneToOne: false;
|
|
782
|
+
referencedRelation: "tbl_org";
|
|
783
|
+
referencedColumns: ["org_id"];
|
|
784
|
+
}
|
|
785
|
+
];
|
|
786
|
+
};
|
|
759
787
|
view_chats: {
|
|
760
788
|
Row: {
|
|
761
789
|
archived: boolean | null;
|
|
@@ -805,6 +833,13 @@ export interface Database {
|
|
|
805
833
|
};
|
|
806
834
|
Returns: string;
|
|
807
835
|
};
|
|
836
|
+
get_broadcast_id: {
|
|
837
|
+
Args: {
|
|
838
|
+
broadcast_id_input: string;
|
|
839
|
+
chat_id_input?: string;
|
|
840
|
+
};
|
|
841
|
+
Returns: Json;
|
|
842
|
+
};
|
|
808
843
|
get_chats: {
|
|
809
844
|
Args: {
|
|
810
845
|
chat_id_input?: string[];
|
package/dist/types.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Merge, OverrideProperties } from 'type-fest';
|
|
2
|
-
import { Chat, Location, MessageTypes } from 'whatsapp-web.js';
|
|
2
|
+
import { Chat, Location, MessageInfo, MessageTypes } from 'whatsapp-web.js';
|
|
3
3
|
import { Tables } from './supabase.types';
|
|
4
4
|
export type WhatsappChat = Chat & {
|
|
5
5
|
groupMetadata?: any;
|
|
@@ -64,3 +64,13 @@ export type SingleMessagePayload = SendMessageContent & {
|
|
|
64
64
|
chat_id: string;
|
|
65
65
|
job_id?: string;
|
|
66
66
|
};
|
|
67
|
+
export type BroadcastLogType = Tables<'view_broadcast_logs'> & {
|
|
68
|
+
logs: {
|
|
69
|
+
chat_id: string;
|
|
70
|
+
message_id: string | null;
|
|
71
|
+
read_count: number | null;
|
|
72
|
+
total_count: number | null;
|
|
73
|
+
delivery_info: MessageInfo | null;
|
|
74
|
+
delivered_count: number | null;
|
|
75
|
+
};
|
|
76
|
+
};
|
package/package.json
CHANGED
package/supabase.types.ts
CHANGED
|
@@ -32,6 +32,7 @@ export interface Database {
|
|
|
32
32
|
Row: {
|
|
33
33
|
broadcast_id: string
|
|
34
34
|
chat_ids: string[] | null
|
|
35
|
+
completed_at: string | null
|
|
35
36
|
created_at: string
|
|
36
37
|
message_payload: Json | null
|
|
37
38
|
org_id: string
|
|
@@ -42,6 +43,7 @@ export interface Database {
|
|
|
42
43
|
Insert: {
|
|
43
44
|
broadcast_id?: string
|
|
44
45
|
chat_ids?: string[] | null
|
|
46
|
+
completed_at?: string | null
|
|
45
47
|
created_at?: string
|
|
46
48
|
message_payload?: Json | null
|
|
47
49
|
org_id?: string
|
|
@@ -52,6 +54,7 @@ export interface Database {
|
|
|
52
54
|
Update: {
|
|
53
55
|
broadcast_id?: string
|
|
54
56
|
chat_ids?: string[] | null
|
|
57
|
+
completed_at?: string | null
|
|
55
58
|
created_at?: string
|
|
56
59
|
message_payload?: Json | null
|
|
57
60
|
org_id?: string
|
|
@@ -755,6 +758,31 @@ export interface Database {
|
|
|
755
758
|
}
|
|
756
759
|
}
|
|
757
760
|
Views: {
|
|
761
|
+
view_broadcast_logs: {
|
|
762
|
+
Row: {
|
|
763
|
+
broadcast_id: string | null
|
|
764
|
+
completed_at: string | null
|
|
765
|
+
delivered_member_count: number | null
|
|
766
|
+
failed_chats: number | null
|
|
767
|
+
message_payload: Json | null
|
|
768
|
+
org_id: string | null
|
|
769
|
+
read_member_count: number | null
|
|
770
|
+
scheduled_at: string | null
|
|
771
|
+
sent_chats: number | null
|
|
772
|
+
status: string | null
|
|
773
|
+
total_chats: number | null
|
|
774
|
+
total_member_count: number | null
|
|
775
|
+
}
|
|
776
|
+
Relationships: [
|
|
777
|
+
{
|
|
778
|
+
foreignKeyName: "tbl_broadcast_messages_org_id_fkey"
|
|
779
|
+
columns: ["org_id"]
|
|
780
|
+
isOneToOne: false
|
|
781
|
+
referencedRelation: "tbl_org"
|
|
782
|
+
referencedColumns: ["org_id"]
|
|
783
|
+
}
|
|
784
|
+
]
|
|
785
|
+
}
|
|
758
786
|
view_chats: {
|
|
759
787
|
Row: {
|
|
760
788
|
archived: boolean | null
|
|
@@ -804,6 +832,13 @@ export interface Database {
|
|
|
804
832
|
}
|
|
805
833
|
Returns: string
|
|
806
834
|
}
|
|
835
|
+
get_broadcast_id: {
|
|
836
|
+
Args: {
|
|
837
|
+
broadcast_id_input: string
|
|
838
|
+
chat_id_input?: string
|
|
839
|
+
}
|
|
840
|
+
Returns: Json
|
|
841
|
+
}
|
|
807
842
|
get_chats: {
|
|
808
843
|
Args: {
|
|
809
844
|
chat_id_input?: string[]
|
package/types.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Merge, OverrideProperties } from 'type-fest';
|
|
2
|
-
import { Chat, Location, MessageTypes } from 'whatsapp-web.js';
|
|
2
|
+
import { Chat, Location, MessageInfo, MessageTypes } from 'whatsapp-web.js';
|
|
3
3
|
import { Tables } from './supabase.types';
|
|
4
4
|
|
|
5
5
|
/* ----------------------------- TYPE SHORTHANDS ---------------------------- */
|
|
@@ -134,3 +134,16 @@ export type SingleMessagePayload = SendMessageContent & {
|
|
|
134
134
|
chat_id: string;
|
|
135
135
|
job_id?: string;
|
|
136
136
|
};
|
|
137
|
+
|
|
138
|
+
/* -------------------------------- BROADCAST ------------------------------- */
|
|
139
|
+
|
|
140
|
+
export type BroadcastLogType = Tables<'view_broadcast_logs'> & {
|
|
141
|
+
logs: {
|
|
142
|
+
chat_id: string,
|
|
143
|
+
message_id: string | null,
|
|
144
|
+
read_count: number | null,
|
|
145
|
+
total_count: number | null,
|
|
146
|
+
delivery_info: MessageInfo | null,
|
|
147
|
+
delivered_count: number | null
|
|
148
|
+
},
|
|
149
|
+
}
|