Skip to content

NodeJS utilities to automate things based on Fortum Tarkka hourly prices

License

Notifications You must be signed in to change notification settings

ikaakkola/nodejs-tarkka

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

nodejs-tarkka

NodeJS utilities to automate things based on Fortum Tarkka hourly prices

Examples

Fetch 'Tarkka' hourly data

nodejs /path/to/tarkka_fetch.js /tmp/tarkka_result.json

Query highest 5 hours from previously fetched data

nodejs /path/to/tarkka_query.js /tmp/tarkka_result.json highest 5

Publish particle.io event if current hour is one of the highest 5

nodejs /path/to/tarkka_particleIoEvent.js access_token event_name /path/to/tarkka_query.js /tmp/tarkka_result.json highest 5 

The above publishes an event to particle.io as ''event_name'' if the current hour (the hour the command is run) is within the 5 highest hours.

Call 'myFunction' on device 'aaabbb' with parameter 'R0:HIGH' if current hour is over 4.2

nodejs /path/to/tarkka_particleIoCallFunction.js access_token device_id myFunction R0:HIGH /path/to/tarkka_query.js /tmp/tarkka_result.json over 4.2

About

NodeJS utilities to automate things based on Fortum Tarkka hourly prices

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published