syedsannan.com - logo

That time I made a WhatsApp API of my own while creating a C.R.M..



Introduction


I am the author of BASTI (C.R.M.), an operational and analytical C.R.M. solution that currently functions primarily around WhatsApp. It is a software that automates lead management and interaction, while granting the sales teams complete insight on lead activity, so that they can focus on actually important stuff such as negotiation, marketing strategies, etc.


It contains a mini-CPaaS purpose-built for it, and also a staff-based leads acceptance system.


The lead conversations happen with a mechanism termed the "salesbot". The salesbot is a set of timers set by the business on different lead stages and the message each of them will send at the end of that timer with regards to or regardless of conversaiton activity. This allows for automatic messages to be sent to the leads and their stage in the pipeline to be updated accordingly.


On the other hand, an analytics panel is provided for the business to analyze their leads, staff performance, demographics, etc.


How it Works


I developed this app using the MERN stack and also created a specialized API for it that runs on websockets. Moreover, its mobile app is made using React Native.


Now considering that you might know that there already is a WhatsApp messaging API, you might ask, why? well, that is a valid question and I have a few answers in the form of reasons for it.


  1. The official WhatsApp API is expensive.
  2. It is barely effective over websockets and with real-time data updates.

My primary reason being point #1, in contrast to what WhatsApp claims, their API costs are not very suitable for low-scale businesses. Have a look at their pricing. On the other hand, a self-made solution is completely free of cost.


Now, for obvious reasons, I cannot go into the details of how I actually implemented this workaround and what technologies I used for it, but you may take a look at how the system works.


This is a very brief rundown of the primary steps in the functionality of the software in the form of steps:
  1. The business signs up, sets up their product pipelines and their respective lead stages.
  2. They scan the QR code for each pipeline to grant WhatsApp access to the app.
  3. Someone messages them on WhatsApp.
  4. They show up as a lead in the immutable "Introduction" lead stage, after which, they move on as set in the salesbot.
  5. The salesbot has a conversation with them according to how it is defined to.
  6. The staff has a conversation with them according to the chat.
  7. The lead eventually ends up in either of these two immutable lead stages, the "Closed - won" stage, or the "Closed - lost" stage.
  8. The lead is saved as a contact and can later be bothered for any other sake, such as limited time offers and more 😅.
  9. Repeat... 🔁

Once again, this is a very brief rundown of its functionality, to highlight the primary features and flow of the system. Moreover, BASTI (C.R.M.) is currently in its M.V.P. stage so it would not be wrong to expect more from its highlighted features.


Some Screenshots

Note: This list of screenshots is non-exchaustive.

screenshotscreenshotscreenshot