Comments on: Looking to integrate OpenDof with my Node.Js program https://opendof.org/answers/looking-to-integrate-opendof-with-my-node-js-program/?utm_source=rss&utm_medium=rss&utm_campaign=looking-to-integrate-opendof-with-my-node-js-program Tue, 06 Jun 2017 19:45:58 +0000 hourly 1 https://wordpress.org/?v=6.0 By: amauchley https://opendof.org/answers/looking-to-integrate-opendof-with-my-node-js-program/#comment-16 Tue, 06 Jun 2017 19:45:58 +0000 https://opendof.org/answers/looking-to-integrate-opendof-with-my-node-js-program/#comment-16 Sorry for answering so late, we had some transition changes, and some things fell through the crack. To answer your questions though, we currently don’t have a JavaScript library and don’t have any plans in creating one for OpenDOF in the future, as of yet. In order to integrate OpenDOF with your Node.js application, if you feel comfortable enough, you can create a Java client (REST) library that wraps the OpenDOF libraries’ responses in order to communicate with your Node.js application. I would recommend downloading the latest Java IoT libraries here at these link(s) to get started:

– https://asset.opendof.org/artifact/org.opendof.core-java/dof-oal/7.0.5/dists/core-java-dof-oal-7.0.5.noarch.tar.gz
– https://asset.opendof.org/artifact/org.opendof.core-java/dof-inet/7.0.2/dists/core-java-dof-inet-7.0.2.noarch.tar.gz
– https://asset.opendof.org/artifact/org.opendof.core-java/dof-connection-reconnecting-listener/2.0.1/dists/core-java-dof-connection-reconnecting-listener-2.0.1.noarch.tar.gz
– https://asset.opendof.org/artifact/org.opendof.core-java/dof-slf4j-log-listener/2.0.1/dists/core-java-dof-slf4j-log-listener-2.0.1.noarch.tar.gz

For your second question about whether OpenDOF uses a publish/subscribe model, the libraries actually do both, regardless of the medium for connectivity (Wi-Fi, Cellular, etc.). For example, SET, Invoke operations push/publish to the cloud whereas DOFSubscriptions and DOFRegistrations subscribe to a device that is providing properties or potential events. So say for a light, the turning on/off of the light would be a push, and then you could have the light send off an event if it’s power usage reached a certain limit that another managing device/person would be listening to. (subscribe)

]]>