Skip to content

call_log message #3564

Open
Open
@Denis-Redis1

Description

@Denis-Redis1

Is there an existing issue for this?

  • I have searched the existing issues.

Is this a problem caused by your code, or is it specifically because of the library?

  • I have double-checked my code carefully.

Describe the bug.

When WhatsApp Web sends a call_log update, the raw payload often does not include the isNewMsgfield. Because whatsapp-web.js currently does:

if (msg.isNewMsg) {
...
}

node_modules/whatsapp-web.js/src/Client.js:701
all call_log messages are silently ignored and never emitted as high-level message events.

Expected Behavior

call_log messages should be emitted when received, even if isNewMsg is undefined. Call-log notifications (missed or received calls) are legitimate “new” events and should not be filtered out.

Steps to Reproduce the Bug or Issue

  1. Use LocalAuth (or your chosen auth strategy) and instantiate a Client.
  2. Place or miss a call to the WhatsApp number—this generates a call_log update.
  3. Observe in your debugger that the raw event payload has type === 'call_log' but no isNewMsg property.
  4. Notice your message listener is never called for call logs.

WhatsApp Account Type

Standard

Browser Type

Chromium

Operation System Type

Linux

Phone OS Type

Android

WhatsApp-Web.js Version

v1.28.0

WhatsApp Web Version

2.3000.1023186384

Node.js Version

20.18.1

Authentication Strategy

LocalAuth

Additional Context

Call logs are functionally "new messages" (notifications), so the isNewMsg check is overly strict. A fix could:
Default isNewMsg to true for call_log types, or
Skip the check entirely for call logs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions