Hubot adapter using HTTP
CoffeeScript
Switch branches/tags
Nothing to show
Latest commit bd0ddfa Mar 9, 2015 Steve Klise Create LICENSE
Permalink
Failed to load latest commit information.
LICENSE Create LICENSE Mar 9, 2015
index.coffee
package.json Bump version, pass options to user Jun 14, 2013
readme.md Bump version, pass options to user Jun 14, 2013

readme.md

Hubot Web Adapter

An adapter for Hubot to work via HTTP. Great for your custom web chat interface.

Setup

Set HUBOT_REST_SEND_URL as an environment variable to send hubot responses to.

If you want Hubot responses to be formatted for HTML, currently replacing newlines with <br>s, set HUBOT_HTML_RESPONSE to true.

Also, if you're running hubot on Heroku, set your Procfile as a web process and not an app.

Special Options Hash

Typically messages to Hubot have three parameters: Message, User and Room. This adapter allows for an extendable options has to be sent with the message.

To send options, when posting to Hubot use the following hash:

// post: /receive/:room
{
  from: 'nickname string',
  message: 'message body string',
  options: {
    "javascript": "object"
  }
}

The options hash can be accessed in a script with msg.message.user.options.