This is a simple chat bot that you can use with the www.userlike.com live chat
Getting started
- Create an account at https://www.userlike.com
- Add a new operator to you setup https://www.userlike.com/en/dashboard/config/operator/add
- Remember the username and password of this operator, which we will use later.
Install the chat bot
-
Install node.js (Not using OSX? Take a look here https://nodejs.org/en/download/package-manager/)
brew install node
-
Install coffeescript
npm install -g coffee-script
-
Checkout the chat bot repo and install dependencies
git checkout https://github.com/optixx/userlike-chatbot.git cd userlike-chatbot npm install
-
Start the chat bot using your operator credentials
coffee bot.coffee <USERNAME>@userlike.com <PASSWORD>
How does it work
The bot opens a xmpp connection to the Userlike system. Each new visitors gets a session which is State Machine Object. Every incoming message triggers an event into the State machine, which trigger the message processing and depending on the State Object moves forwards in the State machine chain.