I'm working on a setup with EmonCMS, where I would like to automatic create Input and Feeds by using JSON call. In that case I need to get the Input-ID, so I can the Process's on it.
Do anyone know if there are a way to get the Input-ID with JSON by using Node & Name ?
Or are there other ways to create Feeds automatic with URL calls
Re: How to get the Input-ID, by using json call
If you log into emoncms. Click on Input and then click on the "Input Api Help" scroll down to the bottom and you'll see the answers.
Do anyone know if there are a way to get the Input-ID -> http://emoncms.org/input/list.json
are there other ways to create Feeds automatic with URL calls -> http://emoncms.org/input/process/add.json?inputid=1&processid=1&arg=-1&newfeedname=power
Re: How to get the Input-ID, by using json call
All the "Input process actions" specifyed in "Input Api Help" need the Inputid, and thats why I need it ..
I can use the "list.json" function, but then I get ALL input information, and I have to find the correct inputid in there..
My plan is also to use the "add.json" function to create my Feeds, but again I need the inputid
So are the only way to get a "inputid" by using "list.json" function ?
Re: How to get the Input-ID, by using json call
You can read the inputid with an python script like this:
#!/usr/bin/python
import urllib
response=urllib.urlopen('http://yyyyyyyyyy/emoncms/input/list.json&apikey=XXXXXXXXXXXXXXXXXXXXX')
print response.read()
where:
yyyyyyyyyy is IP from emoncms server
XXXXXXXXXXXXXXXXXXXXX is apikey
By