Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
A streaming TCP client for the pachube TCP Server for Nodejs
CoffeeScript JavaScript
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib/pachube-stream
node_modules
src/pachube-stream
test
Cakefile
LICENSE
README.md
index.js
package.json

README.md

pachube-stream

A streaming TCP client for the pachube TCP Server

Installation

Use NPM:

npm install pachube-stream

Otherwise just use npm to link yourself

git clone http://github.com/carboncalculated/node-pachube-stream.git
cd node-pachube-stream
npm install pachube-stream -l # local 

Methods And Events

See the TCP Streaming API docs for exactly that

Usage (coffee)

{Connection} = require("pachube-stream")

conn = new Connection("Your API KEY")

conn.on "error", (error) ->
  console.log(error)

subscription = conn.subscribe("/feeds/7049")

subscription.on "complete", (data) ->
  console.log(data)

subscription.on "data", (data) ->
  console.log(data)

TODO

  • Reconnections
  • Other Methods GET ETC
  • Finish off Tests

Note on Patches/Pull Requests (Standard)

  • Fork the project.
  • Make your feature addition or bug fix.
  • Add tests for it. This is important so I don't break it in a future version unintentionally.
  • Commit, do not mess with version or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
  • Send me a pull request. Bonus points for topic branches.

Copyright

Copyright (c) 2011 Richard Hooker. See LICENSE for details.

Something went wrong with that request. Please try again.