1.0.4 • Published 8 years ago

slipshod v1.0.4

Weekly downloads
1
License
ISC
Repository
-
Last release
8 years ago

Slipshod

Installation

$ npm install --save slipshod
// app.js

var slipshod = require("slipshod");

slipshod.connect(function(bot){

  bot.on("dm", function(msg){
    msg.reply(msg.text.split(" ").reverse().join(" "));
  });

});
token=the-token-you-got-from-above-url node app.js

Methods

slipshod.connect( callback )

Creates a bot and connects to the real-time messaging api.

bot.on( event, callback )

Listens for events, invokes callback with message object.

Events:

  • dm
    • bot receives a direct message
  • mention
    • bot is mentioned in any channel

msg.reply( text, callback )

Contributing

  • git clone https://github.com/ga-dc/slipshod.git
  • cd slipshod/
  • npm install
1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago