#!/bin/bash # RO_KEY='your-local-emoncms-read-only-apikey' RW_KEY='your-emoncms.org-read-write-apikey' # # change FF to the numerical id of the feed you wish to read data from # A=$(curl -s "http://127.0.0.1/emoncms/feed/value.json?id=FF&apikey=$RO_KEY") B=$(curl -s "http://127.0.0.1/emoncms/feed/value.json?id=FF&apikey=$RO_KEY") C=$(curl -s "http://127.0.0.1/emoncms/feed/value.json?id=FF&apikey=$RO_KEY") # A=${A//\"} # strip quotes from json string B=${B//\"} C=${C//\"} # # change NN to the number of the node you want to send data to # curl -s "https://emoncms.org/input/post?node=NN&csv=$A,$B,$C&apikey=$RW_KEY" > /dev/null 2>&1