"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const socket_1 = require("../libs/socket");
function sendWhatsAppMediaSocket(ticket, newMedia) {
    const io = socket_1.getIO();
    io.to(`session_${ticket.whatsappId.toString()}`).emit("send_media", {
        action: "create",
        msg: {
            number: `${ticket.contact.number}@${ticket.isGroup ? "g" : "c"}.us`,
            media: newMedia,
            sendAudioAsVoice: true
        }
    });
}
exports.default = sendWhatsAppMediaSocket;
