With the IDE going away, I thought I would write a simple device viewer as a front end for the smartthings API to see information that is not visible in the app. One of my drivers requires the user to be able to get the zigbee network id of a device, this also provides a way to do that.
The App is just HTML & Javascript (I’m not a webdev so please be kind) - there is no server component other than the smartthings server - so if you like you can just save it as a webpage down to your machine, or you can run it in-place on github pages.
How to use
Go to SmartThings. Add a little smartness to your things. and create a new PAT (personal access token), you will need to give it at least devices and locations permissions - you need to keep this secure and save it for re-use - this is affectively your username and password for the API
Go to ST Device Info Viewer, enter your token and click submit - now explore your devices
(I have tagged this as “miscellaneous” for the quick browse lists even though it’s not an Edge Driver, because that’s where I think most people would be looking for this functionality.)
Note: I originally didn’t see my Linked Services devices, but after including Device Profiles in the scopes, they showed up.
There should be no reason why it wouldn’t show linked services - I can see my Yeelight bulb (which is a linked service, can also see my hub itself, my mobile phone, my smart meter - none of them are hub devices). Not sure why you can’t see your meross devices. All the page does is call the devices endpoint of the API
VIPER is the device type for the C2C Schema. There are some weird and wonderful device types like PENGYOU. The big surprise to me is that no one is jumping up and down at EDGE_CHILD …
Nifty! Is anybody else with multiple locations seeing their devices duplicated by the number of locations? (I currently have two location and am seeing two entries for the same device)
This is a very handy tool (I’m sure the ST devs have something like this and it’s too bad they haven’t opened it up to users). Well done!
I’m definitely going to want to keep referring back to this as migration moves forward. Is there a way to pass the token as an argument, so I can bookmark the address and view it from multiple devices, or otherwise maintain access without generating new tokens? Or would it be easiest to copy the page to my own github and hard code the token in? I’m looking for a way around having to save the string somewhere and enter it repeatedly.
I can’t see what is going wrong there, but I am wondering how anyone with more than 100 devices is getting on as I don’t see where the API paging is being handled.
That was my fault, I was calling getDevices() at the end of processing the rooms - meaning if you had 2 locations it called it twice.
I’ve just published a hacky fix for that, but worried it might mean devices try to load before rooms have finished loading - hopefully that won’t happen.