DEV Community


Integrate messaging platform with Rails app

shan profile image Shanmugavel Arunachalam ・1 min read


I am doing R&D to integrate messaging platform to our Ruby on Rails web application.

Basically, The authenticated users could able to chat between them

One to one
Public and Private Chat
Group Chat

I started exploring the following messaging services and ordered according to my preference.

  1. Pusher
  2. Twilio
  3. Slack
  4. Sendbird
  5. Smooch
  6. TalkJs
  7. Telegram

It would be great if you share your views on this.


Editor guide
ben profile image
Ben Halpern

I know Stream also released an option here. Perhaps @nickparsons could add some info here.

We investigated a lot of options when exploring this same problem. I think a lot of the questions relate to where you want to fit in in terms of abstractions. Some are lower level tools, some are more opinionated.

I also ran into some areas where security/privacy was a concern depending on the use case of the project in terms of private/public chats.

It will also depend on whether you want a max of ~150 or so folks in a public chat or ~1500 etc. Some of the tools have hard limits.

cc: @zmarkan and @philnash who may have more thoughts.

shan profile image
philnash profile image
Phil Nash

Thanks Ben!

nickparsons profile image
Nick Parsons

As @ben kindly pointed out, Stream Chat would be another great solution. Our infrastructure handles everything for you, so you don't have to worry about standing up databases, etc. on your own. Just write a few lines of JS and you're good to go! The Stream Chat JS SDK would be an excellent place to start after checking out the API Tour here.

Bonus! If you're using React, we have developed a set of React components for the various chat types that we support. More on the React Components can be found here.

Not using React? No problem! Base your chat experience off of our carefully designed Chat UI Kit.

Full list of features here :)

shan profile image
andrewbrown profile image
Andrew Brown 🇨🇦

The most cost-effective solution will be to roll your own using AWS services.

AWS AppSync can get you started by launching a CloudFormation template to provision the services you need for your backend.
You'd have to take care of UI yourself but there are plently of Chat UIs for various web-frameworks.

Another idea is to setup your own MQTT server. I had some experience using this for building a chat app that was launch into the india market and needed to work at scale.

shan profile image
philnash profile image
Phil Nash

Hey @iashanmugavel , I'm a developer evangelist at Twilio. Our Programmable Chat API does cover public/private chats and with private chats you can control whether it is between two people or group.

It can integrate with any web framework, you'd need to create your users an access token on your Rails server which you would then use to authenticate our client side SDK.

For advanced use, Chat also has a bunch of roles and permissions you can use to control which users can take certain actions. And events in chat can send you webhooks too.

I'd love to answer any questions or concerns you have about it.

shan profile image