File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ export class MessageRaw {
3232 source_reply_id ?: string ;
3333 chatwoot ?: ChatwootMessage ;
3434 contextInfo ?: any ;
35+ status ?: wa . StatusMessage | any ;
3536}
3637
3738type MessageRawBoolean < T > = {
Original file line number Diff line number Diff line change @@ -1001,6 +1001,15 @@ export class BaileysStartupService extends WAStartupService {
10011001 continue ;
10021002 }
10031003
1004+ const status : Record < number , wa . StatusMessage > = {
1005+ 0 : 'ERROR' ,
1006+ 1 : 'PENDING' ,
1007+ 2 : 'SERVER_ACK' ,
1008+ 3 : 'DELIVERY_ACK' ,
1009+ 4 : 'READ' ,
1010+ 5 : 'PLAYED' ,
1011+ } ;
1012+
10041013 messagesRaw . push ( {
10051014 key : m . key ,
10061015 pushName : m . pushName || m . key . remoteJid . split ( '@' ) [ 0 ] ,
@@ -1009,6 +1018,7 @@ export class BaileysStartupService extends WAStartupService {
10091018 messageType : getContentType ( m . message ) ,
10101019 messageTimestamp : m . messageTimestamp as number ,
10111020 owner : this . instance . name ,
1021+ status : m . status ? status [ m . status ] : null ,
10121022 } ) ;
10131023 }
10141024
You can’t perform that action at this time.
0 commit comments