From the documentation there doesn’t seem to be a way of getting a list of all the available presentations? It would be useful to be able to get a list of all the presentation ids available, in order to store the presentations locally. I realize they’re keyed by locale, but just being able to do this for English would be a good start.
@erickv Sorry, I should have been more clear - I’m referring to the presentations API.
Let me know if you face any issue while creating your capability presentation (remember to include your capability Id if possible).
@erickv In this case I’m not interested in creating one, but rather getting the complete list of available presentations in order to download and preprocess them for later use. Do you know of any such list?
On the topic of representations, it seems that some of the reported representations can’t be fetched at the moment? E.g. one of my lights reports the presentation id
SmartThings-smartthings-ZLL_RGB_Bulb, but a call to
https://api.smartthings.com/v1/presentation?presentationId=SmartThings-smartthings-ZLL_RGB_Bulb gives a 404, “resource not found”.
@NilsiusRex It seems that there’s no presentation with that Id under the default
mnmn. You should be able to get it under the SmartThings
Thanks @erickv, that did the trick for that one.
Now, I’m assuming that there is no list of all the available presentations, but let me know if I’m wrong.
There was a Glitch tool for this which provided reference of generic presentations (VIDs), and its focus was mainly to assist DTH development, but since we’re now able to build our own presentations based on device profiles I’m not sure if it still being maintained. I’ll ask the team about it share with you the outcome.
If you’re looking for a specific presentation, you could create a device profile at the Developer Workspace and then build the presentation from it with this ST CLI command:
# generate smartthings presentation:device-config:generate \ <device_profile_id> --json --output device_config.json # then create smartthings presentation:device-config:create \ --input device_config.json
Note: For simplicity, the above commands are based on the SmartThings CLI syntax.
I’m looking at creating a generic UI for whatever devices, but I’ll just make sure to store these on demand instead.