Javascript libraries are not in the best shape, but you could try to use the headless version of ConverseJS.
Edit: there is a version of ConverseJS that works as a browser plugin called "Pade" if I recall correctly. Might be a good reference point.
XMPP (aka Jabber) is the community-owned standard for real-time federated messaging.
JoinJabber.org admin support chat
Javascript libraries are not in the best shape, but you could try to use the headless version of ConverseJS.
Edit: there is a version of ConverseJS that works as a browser plugin called "Pade" if I recall correctly. Might be a good reference point.
Thanks. I've seen ConverseJS but it seems overkill to what I have in mind. Is there any part of the modules that can be taken out of the main code base and used just to authenticate and receive the messages?
I think it uses this internally: https://github.com/strophe/strophejs
There is also: https://github.com/legastero/stanza
That looks more like it! I will try them out and report back how it went. Thank you very much!