evolution-api icon indicating copy to clipboard operation
evolution-api copied to clipboard

Chatwoot integration: outgoing messages have trailing newlines on WhatsApp

Open devopspcnet opened this issue 9 months ago • 3 comments

Closing as duplicate of #2014 — Chatwoot integration meta-issue.

See #2014 for the full list of tracked Chatwoot issues and known workarounds.

devopspcnet avatar Feb 05 '26 22:02 devopspcnet

Hi everyone,

I was struggling with the 'trailing newlines' (empty spaces at the end of messages) when using Chatwoot with Evolution API v2.3.7. After several attempts with environment variables, I found a simple UX fix that solved the issue:

In Chatwoot Settings, disable the 'Send message with Ctrl + Enter' option and use only 'Enter' to send.

It seems that the TipTap editor in Chatwoot adds invisible paragraph tags or extra \n characters when the 'Ctrl + Enter' shortcut is active. By switching to 'Enter' only, the payload sent to the API is much cleaner, and the 'vacuum' in WhatsApp messages disappears completely.

Tested and working 100% on v2.3.7. Hope this saves someone some time!

thiagommkt avatar Mar 03 '26 19:03 thiagommkt

I am still experiencing this issue on the latest Chatwoot v4.11.1 (Build 939471c).

I’ve conducted cross-platform testing to isolate the behavior, and it’s clearly a Chatwoot-side issue with how the editor handles the Ctrl + Enter shortcut compared to the standard Enter key.

Test Environment:

  • Chatwoot: v4.11.1 (Build 939471c)
  • API Gateways Tested: Evolution API (v2.3.7) AND WAHA GOWS (2026.3.2 CORE)
  • Channel: WhatsApp (API Channel)

The Findings:

  1. With 'Send message with Ctrl + Enter' ENABLED: Every message sent results in a 'vacuum' (2-3 trailing newlines) on the recipient's WhatsApp. This happens regardless of whether I use Evolution API or WAHA, confirming the extra whitespace is being injected by Chatwoot into the outgoing payload.
  2. With 'Send message with Ctrl + Enter' DISABLED: Messages sent using the standard Enter key are perfectly trimmed and arrive without any extra whitespace.

Conclusion: The TipTap editor's Ctrl + Enter listener is likely failing to trim() the content or is adding an extra <p></p> block before dispatching the message. Many of us prefer to keep Ctrl + Enter enabled to prevent accidental sends, so a UX workaround isn't a permanent solution.

fredlisboa avatar Mar 08 '26 16:03 fredlisboa

Hi everyone,

I was struggling with the 'trailing newlines' (empty spaces at the end of messages) when using Chatwoot with Evolution API v2.3.7. After several attempts with environment variables, I found a simple UX fix that solved the issue:

In Chatwoot Settings, disable the 'Send message with Ctrl + Enter' option and use only 'Enter' to send.

It seems that the TipTap editor in Chatwoot adds invisible paragraph tags or extra \n characters when the 'Ctrl + Enter' shortcut is active. By switching to 'Enter' only, the payload sent to the API is much cleaner, and the 'vacuum' in WhatsApp messages disappears completely.

Tested and working 100% on v2.3.7. Hope this saves someone some time!

This worked perfectly for me. Thank you!

dijamarketing avatar May 15 '26 20:05 dijamarketing