Before I venture down this rabbit hole too deep. I am wondering is it possible to set up event subscriptions only using HTTP post and get through something like Postman?
If I’m not mistaken I will have to first create an app using the API to get a oauth token. Then I can use that to do my subscriptions.
I know I am probably missing something and that is why I am posting my question here what else am I missing. Is this even possible?
You would need to create an endpoint app or an OAuth integration to tell SmartThings where to send the events you would like to subscribe to.
Are there any work examples available to build of off?
nayelyz
(SmartThings Developer Support)
September 30, 2022, 4:08pm
4
In the Developer Programs > Tutorials section of the forum, you can find a sample to create a Simple SmartApp which contains samples of subscriptions:
Getting Started with a Simple SmartApp using the new SmartApp SDK
This SDK builds on the CoreSDK and provides kick start for SmartApp development. The SmartApp SDK reduces the amount of code necessary to write a SmartApp using the new platform and API. The SmartApp SDK supports both Webhook and AWS Lamda deployment, but this tutorial will focus on the deploying a webhook SmartApp using Glitch.
Maybe Try this first:
Prerequisites
Samsung Account
Developer Workspace Account
Github or Glitch Account
One Contact Sensor
One or more Light Devices
Guide
I suggest having all of the required accounts created before getting started. You will need a location prepared with at least one contact sensor and one or more light devices.
Links
SDK: GitHub - SmartThingsCommunity/smartapp-sdk-nodejs…
Note: Remember this SDK is based on the Core SDK, so, in that repo, you can see which functions (requests) you can use. You’ll find them inside each endpoint: https://github.com/SmartThingsCommunity/smartthings-core-sdk/tree/master/src/endpoint
This is important because there are different types of subscriptions as specified in the API reference .