pedroslopez / whatsapp-web.js

A WhatsApp client library for NodeJS that connects through the WhatsApp Web browser app
https://wwebjs.dev
Apache License 2.0
14.95k stars 3.55k forks source link

Not able to send Contact #2680

Open Raunakriya opened 8 months ago

Raunakriya commented 8 months ago

Is there an existing issue for this?

Describe the bug

I am trying to send contact in contact card formate. But not able to send.

Expected behavior

Want to Get contact in contact card formate.

Steps to Reproduce the Bug or Issue

  1. when I am sending a contact it goes to text formate.

Relevant Code

client.sendMessage(contactNo+ '@c.us', 'BEGIN:VCARD\n' + 'VERSION:3.0\n' + 'N:Ln;abc;;;\n' + 'FN:abcLn\n' + 'TEL;type=Mobile;waid=917491945069:+91 74919 45069\n' + 'END:VCARD',{ parseVCards: false }

Browser Type

Google Chrome

WhatsApp Account Type

Standard

Does your WhatsApp account have multidevice enabled?

Yes, I am using Multi Device

Environment

OS: Window Phone OS: [Android, iOS] whatsapp-web.js version [1.23.1-alpha.0] WhatsApp Web version [run await client.getWWebVersion()]: Node.js Version [v18.18.0]

Additional context

No response

RC047 commented 8 months ago

You can check this pulls #1995

Raunakriya commented 8 months ago

You can check this pulls #1995

Ok Thanks , Is there any other way to fix it except node_modules .

MuhammadAsad6889 commented 8 months ago

Anyone please help I'm facing this erorr IMG_20231214_023931_062

Heracraft commented 7 months ago

Anyone please help I'm facing this erorr IMG_20231214_023931_062

Your wid is invalid, your probably passing a phone number directly but a WhatsApp ID is something like ${phoneNumber}@c.us eg. 6285311174928@c.us

videjunior commented 6 months ago

You can check this pulls #1995

The proposed solution is no longer valid. The problem persists.

khsoh commented 2 weeks ago

The proposed solution does not work on 1.25.0