I have been involved in projects where we had to make a similar build-vs-buy decision. Intially, building instant messaging platform ourselves looked like the better option because we wanted complete control over the architecture and features.
The problem was that basic chat was not really the difficult part. It’s like reliable message delivery, offline synchronization, presence, notifications, file handling, security, scaling, monitoring, and ongoing maintenance added a lot more work than we initially expected.
We ended up looking at a few existing messaging solutions as well, including MirrorFly, Chanty, Pumble mainly because we wanted to compare how much of the messaging infrastructure we could get ready-made while still having control over customization and deployment.
For a small internal application, I’d still consider building it from scratch. But if messaging isn’t the core business product, I’d generally lean toward using an established SDK or platform and building the application around it.
I’d compare solutions based on source-code access, deployment options, customization, scalability, security, integration effort, and long-term cost. For us, the main question wasn’t simply “build or buy,” but how much control we actually needed versus how much development and maintenance we were willing to take on.