Post to login url

Can I post to the url https://graph.api.smartthings.com/login/auth using HTTPclient or using chrome rest client?

What are you trying to accomplish?

Trying to write a service to get a json response for the url…
https://graph.api.smartthings.com/api/hubs/3593a525-2369-432f-84d4-147d8cf3c6c2/events. But when I make a http call to that url using HTTPClient getting a HTML back from the server to login into the smartthing account…
I need to be able to by pass the HTML login or able to login programatically . And then make a request to get the event info in json format.

Is there any way to acomplish this?

You could create an endpoint SmartApp and use the events() method on your device collection.

Events reference:
http://docs.smartthings.com/en/latest/ref-docs/device-ref.html?#events

Web Service SmartApp Reference:
http://docs.smartthings.com/en/latest/smartapp-web-services-developers-guide/index.html

There may be ways to directly hit the endpoints you listed, but they are not officially supported.

1 Like