Skip to content
forked from emostar/pusher

A simple node.js publisher lib for pusher.com

Notifications You must be signed in to change notification settings

geeklist/pusher

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pusher

Pusher is a simple node.js publisher lib for pusher.com.

Installation

Pusher is available on npm.

$ npm install pusher

Usage

var Pusher = require('pusher');

var pusher = new Pusher({
  appId:  'YOUR_PUSHER_APP_ID',
  appKey: 'YOUR_PUSHER_APP_KEY',
  secret: 'YOUR_PUSHER_SECRET_KEY'
});

var channel = pusher.channel('sync');

var data = { name: "Joe", message_count: 23 };

channel.trigger('message', data, function(err, request, response) {
  // do something (this callback is optional)
});

Enjoy! :)

Credits

This lib is based on the work of Dave Hoover aka redsquirrel and his lib simple_pusher.

License

This code is free to use under the terms of the MIT license.

About

A simple node.js publisher lib for pusher.com

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%