Optimize WhatsApp Chatbot Latency

Заказчик: AI | Опубликовано: 05.12.2025

My Node.js-based WhatsApp chatbot is taking too long to answer users. The incoming message reaches the server instantly, the logic it executes is lightweight, and the MySQL queries are trivial, yet the final reply crawls back to the user. The slowdown is consistent regardless of traffic level, so I suspect something in the message-dispatch pipeline, queue handling, or the way we interface with the WhatsApp Business API rather than code complexity. We're using MSG91 for WhatsApp services. I need a developer who can jump into the existing repository, profile the full path from the moment the webhook fires to the moment the reply hits the WhatsApp socket and implement fixes that cut the round-trip time dramatically. That will likely involve checking Node.js event-loop blocking, optimizing MySQL connection handling, reviewing any middleware we employ, and validating that our WhatsApp provider’s recommendations (timeouts, batching limits, message templates, etc.) are followed. Deliverable: a patched and documented codebase (or clear pull request) plus a short before-vs-after latency report demonstrating a tangible speed-up that users can feel.