david6
(David)
January 5, 2023, 8:09pm
1
I’m looking for any guidance on how to register and receive events (i.e. switch state change) in an application I’m coding. Application will run on my home computer and I’d like to recieve push events whenever a device changes state.
nayelyz
(SmartThings Developer Support)
January 5, 2023, 11:38pm
2
Welcome to the SmartThings Community, @david6 !
For this, you need to create a SmartApp as using its token type and installedAppId
allows us to create subscriptions: API | Developer Documentation | SmartThings
Here’s a tutorial on how to create a simple SmartApp:
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…
1 Like