openclaw - 💡(How to fix) Fix WhatsApp: message tool send fails with 'No active WhatsApp Web listener' while channel is connected and replies work [4 comments, 4 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#49336Fetched 2026-04-08 00:56:22
View on GitHub
Comments
4
Participants
4
Timeline
7
Reactions
0
Author
Timeline (top)
commented ×4closed ×1cross-referenced ×1locked ×1

The message tool's send action always fails with:

Error: No active WhatsApp Web listener (account: default). Start the gateway, then link WhatsApp with: openclaw channels login --channel whatsapp --account default.

However:

  • openclaw channels status --probe shows: enabled, configured, linked, running, connected
  • Inbound WhatsApp messages are received and routed to sessions correctly
  • Normal agent replies are delivered to WhatsApp successfully
  • Only the message tool's proactive send (action=send, channel=whatsapp, target=<phone>) fails

Error Message

Gateway logs show WhatsApp connected and listening:

[whatsapp] [default] starting provider (+15615039444)
[whatsapp] Listening for personal WhatsApp inbound messages.

But sends fail:

[ws] ⇄ res ✗ send 9ms errorCode=UNAVAILABLE errorMessage=Error: No active WhatsApp Web listener...

Root Cause

The message tool's send action always fails with:

Error: No active WhatsApp Web listener (account: default). Start the gateway, then link WhatsApp with: openclaw channels login --channel whatsapp --account default.

However:

  • openclaw channels status --probe shows: enabled, configured, linked, running, connected
  • Inbound WhatsApp messages are received and routed to sessions correctly
  • Normal agent replies are delivered to WhatsApp successfully
  • Only the message tool's proactive send (action=send, channel=whatsapp, target=<phone>) fails

Code Example

Error: No active WhatsApp Web listener (account: default). Start the gateway, then link WhatsApp with: openclaw channels login --channel whatsapp --account default.

---

[whatsapp] [default] starting provider (+15615039444)
[whatsapp] Listening for personal WhatsApp inbound messages.

---

[ws] ⇄ res ✗ send 9ms errorCode=UNAVAILABLE errorMessage=Error: No active WhatsApp Web listener...
RAW_BUFFERClick to expand / collapse

Bug Report

Version: 2026.3.13 (61d171a) OS: macOS 15.6 (arm64)

Description

The message tool's send action always fails with:

Error: No active WhatsApp Web listener (account: default). Start the gateway, then link WhatsApp with: openclaw channels login --channel whatsapp --account default.

However:

  • openclaw channels status --probe shows: enabled, configured, linked, running, connected
  • Inbound WhatsApp messages are received and routed to sessions correctly
  • Normal agent replies are delivered to WhatsApp successfully
  • Only the message tool's proactive send (action=send, channel=whatsapp, target=<phone>) fails

Steps to Reproduce

  1. Link WhatsApp via openclaw channels login --channel whatsapp
  2. Verify status shows connected: openclaw channels status --probe
  3. Send a message from WhatsApp to the agent — it arrives fine
  4. Agent replies are delivered to WhatsApp fine
  5. Use the message tool with action=send, channel=whatsapp, target=15615039444 → fails

Likely Cause

The listener registry checked by the send path (auth-profiles-*.js, reply-*.js, model-selection-*.js) is not being populated, even though the channel's inbound listener and reply path are operational. The send path checks if (!listener) and throws, but the reply path uses a different mechanism to reach the WhatsApp connection.

Logs

Gateway logs show WhatsApp connected and listening:

[whatsapp] [default] starting provider (+15615039444)
[whatsapp] Listening for personal WhatsApp inbound messages.

But sends fail:

[ws] ⇄ res ✗ send 9ms errorCode=UNAVAILABLE errorMessage=Error: No active WhatsApp Web listener...

Impact

  • Cannot send proactive WhatsApp messages (grade reports, reminders, etc.)
  • Cron jobs that send WhatsApp messages also fail
  • Regression from 2026.3.12 where sends worked fine (last successful send: March 13)

extent analysis

Fix Plan

To resolve the issue with the message tool's send action failing due to "No active WhatsApp Web listener," we need to ensure the listener registry is properly populated for the send path.

Step-by-Step Solution:

  1. Update Listener Registry Check: Modify the auth-profiles-*.js, reply-*.js, and model-selection-*.js files to correctly populate the listener registry for the send path.
  2. Verify WhatsApp Connection: Before sending a message, ensure the WhatsApp connection is active by checking the gateway logs for the "Listening for personal WhatsApp inbound messages" message.
  3. Code Changes: Update the send path logic to use the same mechanism as the reply path to reach the WhatsApp connection.

Example Code Snippet (JavaScript):

// Assuming 'listener' is the variable checked for WhatsApp listener availability
if (!listener) {
  // Instead of throwing an error, try to establish or retrieve the WhatsApp connection
  listener = getWhatsAppListener(); // Implement getWhatsAppListener() to return the active listener
  if (!listener) {
    throw new Error('No active WhatsApp Web listener');
  }
}

// Function to retrieve the WhatsApp listener, similar to how the reply path works
function getWhatsAppListener() {
  // Logic to retrieve or establish the WhatsApp listener, potentially using the same method as the reply path
  // For demonstration purposes, assume 'whatsappConnection' is the established connection
  const whatsappConnection = getEstablishedWhatsAppConnection();
  return whatsappConnection.listener;
}

// Example function to establish or retrieve the WhatsApp connection
function getEstablishedWhatsAppConnection() {
  // Implement logic to establish or retrieve the WhatsApp connection
  // This could involve checking the gateway logs, the channel status, or directly querying the WhatsApp API
  // For simplicity, assume the connection is already established and stored
  return {
    listener: {
      // Properties and methods of the listener
    }
  };
}

Verification

To verify the fix worked:

  • Run the message tool with action=send, channel=whatsapp, target=<phone> again.
  • Check the gateway logs for successful send operations.
  • Test proactive message sending through cron jobs or other automated processes.

Extra Tips

  • Ensure all dependencies and libraries are up-to-date, as regressions can sometimes be caused by version mismatches.
  • Review the WhatsApp API documentation and the library or framework used for WhatsApp integration to ensure compliance with the latest requirements and best practices.
  • Consider implementing additional logging or monitoring to detect and diagnose similar issues more efficiently in the future.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING