9.1.0 • Published 5 months ago

lightstreamer-client-node v9.1.0

Weekly downloads
180
License
Apache-2.0
Repository
github
Last release
5 months ago

Lightstreamer Client Node.js SDK

The Lightstreamer Client Node.js SDK enables any Node.js application to communicate bidirectionally with a Lightstreamer server. The API allows to subscribe to real-time data pushed by a server and to send any message to the server.

Use

Install the package using npm

npm install lightstreamer-client-node

The SDK for Node.js Clients allows you to develop JavaScript applications by using the same API already provided by the SDK for Web Clients.

You can start writing your application by loading lightstreamer-client-node module as in the following example. Alternatively, you can load a minified version of the library by requiring lightstreamer-client-node/lightstreamer-node.min module.

var Ls = require('lightstreamer-client-node');

var sub = new Ls.Subscription("MERGE",["item1","item2","item3"],["stock_name","last_price"]);
sub.setDataAdapter("QUOTE_ADAPTER");
sub.setRequestedSnapshot("yes");
sub.addListener({
    onItemUpdate: function(obj) {
      console.log(obj.getValue("stock_name") + ": " + obj.getValue("last_price"));
    }
});
var client = new Ls.LightstreamerClient("http://push.lightstreamer.com","DEMO");  
client.connect();
client.subscribe(sub);

Compatibility

The library requires Server 7.4.0.

Documentation

9.1.0

5 months ago

9.0.0-beta.3

11 months ago

9.0.0

10 months ago

9.0.0-beta.2

1 year ago

9.0.0-beta.1

1 year ago

8.0.5

2 years ago

8.2.0-beta3

2 years ago

8.2.0-beta2

2 years ago

8.0.4

2 years ago

8.1.0-beta4

2 years ago

8.1.0-beta3

3 years ago

8.0.3

3 years ago

8.1.0-beta2

4 years ago

8.1.0-beta1

4 years ago

8.1.0-beta

4 years ago

8.0.2

4 years ago

8.0.1

5 years ago

8.0.0

5 years ago

8.0.0-rc1

5 years ago