I created some iOS Shortcuts for interacting with SmartThings devices, rules and scenes.
There are four general Shortcuts (ending in _api) that provides the following functionality:
Execute a Rule (ST_Rule_API)
Execute a Scene (ST_Scene_API)
Get Device Status (ST_Device_Status_API)
Send Device JSON commands (ST_Device_CMD_API)
To use the general Shortcuts, you need to edit each one and add your personal access token (pat entry) to the dictionary and your location id (locid entry) for the ST_Rule_API
To control SmartThings devices/rules/scenes, create a duplicate of the corresponding test_xxxx Shortcut, rename the Shortcut and edit the Shortcut to add the appropriate id and for sending device commands, add the minimized JSON command, for example:
{âcommandsâ: [{âcomponentâ: âmainâ,âcapabilityâ: âswitchâ,âcommandâ:âonâ}]}
Once youâve created your Shortcuts, you can added them to your Home Screen or as widget for easy execution.
Or use Siri to execute the Shortcut by saying âHey Sir Shortcut yourShortNameâ. I found that Siri finds Shortcuts much better when you include âShortcutâ in the phrase
This looks exactly what I want. Can you explain what you mean by âadd your personal access token (pat entry) to the dictionary and your location id (locid entry) for the ST_Rule_APIâ
How do I do that?
Hi Rambo, Iâve followed your instructions and it worked beautifully, now I can control the lights with Siri! This is amazing. Thank you so much! This was my first ever shortcut experiences, Iâve never used Shortcuts before.
Iâm so glad the shortcuts are working well for you. Shortcuts are actually pretty powerful though rather cryptic to create
I use Siri mostly to open my garage. Itâs awesome when Iâm in the backyard and the garage is open by the time I walk to the front to get something out of it
Itâs wonderful ! And unexpectedly simple. When iâve been exploring myself the ST API documentation, it seamed so difficult. First of all, the âAuth 2.0â scared me quite well, as i thought, that there should be quite complicated script in order to use that auth 2.0 (i thought, itâs kind of two ways keys exchange or so), and thus, i dropped an idea. But just the token and the typical JSON post request - itâs just fâŚing grate ! Thank You so much! Now i can control everything with my apple watchâs âtapâ or âclenchâ gesture. Cool!
With my iPad, notifications donât show up until I open it. For obvious reasons; WiFi goes off when in sleep mode.
But if you have a IOS device you can leave on at all times, you could use this - along with Notification shortcuts - to send your Chamberlain garage door status to Smartthings. It would be a one-way integration, but it would allow the garage door status changes to trigger Smartthings automations.
I got my pat id and loc id but now I couldnât add it to st api
Here is my expectation I have a Meross garage door opener I just want to open and close through ios shortcuts ! That way I can make use of my nfc tags again ! TiA
Did you get the model of the Meross garage door opener that also works with Apple HomeKit? If so, it will work with Siri without having to do anything special.