Page 1 of 1
Delete device with Json?
Posted: Thursday 30 June 2016 19:21
by Westcott
Is it possible to delete devices with Json?
Something like -
/json.htm?type=command¶m=deletedevice&idx=IDX
This doesn't work, returning an ERR status
Re: Delete device with Json?
Posted: Thursday 30 June 2016 19:27
by Egregius
Think it should be something like:
Code: Select all
http://192.168.0.10:8084/json.htm?type=setused&idx=535&name=test&description=&used=false
That's the url that's called when you edit/remove a device.
Or
Code: Select all
http://192.168.0.10:8084/json.htm?type=deletedevice&idx=535
when deleting from the devices view.
Both urls tested and confirmed as working.
Re: Delete device with Json?
Posted: Thursday 30 June 2016 20:04
by Westcott
Hi Egregius,
Thanks for the quick answer!
Yes, your 2nd example works for me, even simpler than I guessed.
Perhaps it should be documented in the Wiki?
I'm going to use it to delete spurious unused devices added by RFX and RFlink.
Re: Delete device with Json?
Posted: Thursday 30 June 2016 21:32
by Egregius
Be carefull...
I would just leave them there or disable new sensors.