mirror of
https://github.com/mimamch/wa-multi-session.git
synced 2026-04-25 08:45:59 +03:00
[GH-ISSUE #9] Send document pdf #9
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @sumanmanna6111 on GitHub (Jul 16, 2023).
Original GitHub issue: https://github.com/mimamch/wa-multi-session/issues/9
Add this features
@mimamch commented on GitHub (Jul 16, 2023):
Thank u for asking,
We have created this feature last week.
Check this function or see readme documentation
const filename = "mydocument.docx"; const document = fs.readFileSync(filename); // return Buffer const send = await whatsapp.sendDocument({ sessionId: "session1", to: "6281234567890", filename: filename, media: document, text: "Hei, Check this Document", });@sumanmanna6111 commented on GitHub (Aug 12, 2023):
pdf not sending properly
@mimamch commented on GitHub (Aug 12, 2023):
Can you give more spesific about "pdf not sending"??????
@sumanmanna6111 commented on GitHub (Aug 13, 2023):
const document = fs.readFileSync(filename); // return Buffer
const send = await whatsapp.sendDocument({
sessionId: "session1",
to: "6281234567890",
filename: filename,
media: document,
text: "Hei, Check this Document",
});
but with this code sending a document of 64kb but it not a pdf file .
its send a unsupported file.
@mimamch commented on GitHub (Aug 13, 2023):
Can you give screenshot of code n files you sent, and the error
@sumanmanna6111 commented on GitHub (Aug 13, 2023):
after update wa-multi-session now its working file.
Can you add message seen, delivered status