This library hasn’t been properly vetted by security researchers. Do not use in life and death situations!
There’s a lot of setup required, so please read the README, but once you’ve got it set up, it’s pretty easy to use:
var newmsg = "Message to userA."
Not that hard, right? There’s a ton of different options, though they are pretty well-documented. What is odd though, is that apparently messages aren’t encrypted at first; you must call
to make that happen. I believe this is because the OTR protocol itself allows for unencrypted messages, and otr.js seems to be a lower-level library that others will build upon, rather than something you’d use directly.