I’m trying to setup this curl command as a rest sensor:
curl -s "https://auth.tado.com/oauth/token" -d client_id=tado-web-app -d grant_type=password -d scope=home.user -d username="[email protected]" -d password="Password123" -d client_secret=wZa
When I use the curl command it works fine, but I cannot figure out how to correctly pass the parameter values to the rest sensor. I’ve tried many combinations. What’s the correct method?
I just get unauthorised using things like:
- resource: https://auth.tado.com/oauth/token
method: POST
payload: '{ "client_id":"tado-web-app","grant_type":"password","scope":"home.user","username","myemailaddress","password","mypassword","client_secret":"mysecret"}'