Hi Guys,
Is there any codes/ways to display the API Token and API Endpoint(just like in the web panel) on the mobile Application?
Hi Guys,
Is there any codes/ways to display the API Token and API Endpoint(just like in the web panel) on the mobile Application?
There are some risks created; but take a look at the code for “Smart Alarm” in the SmartThings Community GitHub for an example of generating an Access Token from within your SmartApp in order to offer REST-API endpoint accesses.
Note that an Access Token is not required to offer REST-API access! You can just use the installed Application ID ($app.id
)in the URL, and the user will be prompted for their Login and Password to create a temporary session. This is the safer way to offer access.
Thanks,I will try this.