Skip to content
/ spook Public

Spook is the ghost that hangs around your Campfire

License

Notifications You must be signed in to change notification settings

snelson/spook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spook

A super simple node.js library for building Campfire bots.

Usage

Coffeescript

Spook = require('./path-to/spook')

spook = new Spook
  apiKey: 'api-key'
  subdomain: 'account-subdomain'
  roomID: 12345

spook.respondTo ->

  @match 'ping', ->
    @say 'pong'

  @match 'echo (.+)', (message) ->
    @say message

spook.connect()

Javascript

var Spook = require('./path-to/spook');

spook = new Spook({
  apiKey: 'api-key',
  subdomain: 'account-subdomain',
  roomID: 12345
});

spook.respondTo(function() {

  this.match('ping', function() {
    this.say('pong');
  });

  this.match('echo (.+)', function (message) {
    this.say(message);
  });
});

spook.connect();

About

Spook is the ghost that hangs around your Campfire

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published