2022-01-06 01:26:15 +00:00
|
|
|
import Message from "../models/Message";
|
|
|
|
import Ticket from "../models/Ticket";
|
|
|
|
|
|
|
|
const SerializeWbotMsgId = (ticket: Ticket, message: Message): string => {
|
2023-02-07 15:47:40 +00:00
|
|
|
const serializedMsgId = `${message.fromMe}_${ticket.contact.number}@${ticket.isGroup ? "g" : "c" }.us_${message.id}`;
|
2022-01-06 01:26:15 +00:00
|
|
|
|
|
|
|
return serializedMsgId;
|
|
|
|
};
|
|
|
|
|
|
|
|
export default SerializeWbotMsgId;
|