Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fkanout/appc-pubsub

 
 

Repository files navigation

Appcelerator PubSub Client library

NPM version

The library makes it easy to publish events to the Appcelerator PubSub API service.

Installation

npm install appc-pubsub --save

Usage

You must first include the library and create an instance. At a minimum, you must pass in the key and secret values for constructing the client.

var PubSub = require('appc-pubsub'),
    pubsub = new PubSub({
        key: 'MY_KEY',
        secret: 'MY_SECRET'
    });

Once you have created the client instance, you can publish events.

pubsub.publish('com.foo.bar');

You can optional pass payload data for your event by passing an object as the second parameter:

pubsub.publish('com.foo.bar', {bar:1});

License

The library is Confidential and Proprietary to Appcelerator, Inc. and licensed under the Appcelerator Software License Agreement. Copyright (c) 2015 by Appcelerator, Inc. All Rights Reserved.

About

Appcelerator PubSub client library

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%