Does OH2 http-binding suppor SSL/TLS?

Hi,

just wondering if http-binding supports the SSL/TLS protocol …
Not able to find any QA or documentation, assuming it might be possible using the ‘standalone’ keystore with proper certificate(s) imported.

Thanks in advance for any hint

b72

Reading the documentation it sounds as if.
And it does!

OK, will experiment more, as I was not successful so far.
I would like to integrate Hydrawise via its simple API (https://support.hydrawise.com/hc/en-us/articles/220354488-API-Documentation), but same link called from the browser just doesn’t work from http-binding (suing either GET or POST)
Another option could be to write the fully fledged Hydrawise binding, but I am not good in Java - however what kind of a nice challenge it would be, I’ll see.
Anyways, thanks for the feedback …

b72

I looked at the pdf, created an account to test, got my API-Key and got NO response.
I used the posted link, which started with api.hydrawise.com
After changing in that to app.hydrawise.com I got a response.

That should work. I’ll walk/talk you through if the forum is running proper again. Right now I’m getting in only intermittent.

It seems that I was a bit to optimistic. Writing the required message
into the browser returned a valid response, doing the same in a rule
using sendHttpGetRequest returned a json that is probably stating
something is wrong.

Used message:
https://app.hydrawise.com/api/v1/statusschedule?apikey=MyAPI-Key&hours=24

Return in browser:

{“controller_id”:xxx,“customer_id”:xxx,“user_id”:xxx,“trial”:1,“nextpoll”:300,“sensors”:[],“message”:"",“obs_rain”:"",“obs_rain_week”:"",“obs_maxtemp”:"",“obs_rain_upgrade”:0,“obs_rain_text”:“Yesterday”,“obs_currenttemp”:"",“watering_time”:“0 min”,“water_saving”:0,“last_contact”:“Never”,“status”:“Waiting for controller”,“status_icon”:“trial.png”,“name”:“My Controller”,“relays”:[]}

Return from rule:
{“redirect”:“login”,“aaData”:[]}

Using the same approach in order to get json returns from Tankerkoenig
works (also with https request).
ATM I’m out of clues.

Responding via Mail because the Forum is still rather “unresponsive”.

I am facing exactly the same behaviour … browser interaction works, http-binding doesn’t.
That’s why i’’ve asked about the HTTPS support, because you receive the same JSON message (as when using http-binding) if you use just plain HTTP in the browser.

b72

I’m sorry. I stated before I used the sendHttpGetRequest in a rule for a Https request on another site. I’m still searching…

No worries … i’ll experiment with curl a bit to investigate what might be the problem.
Thx for your support anyways :wink:

Since you’re a customer of Hydrawise, why not ask their support?

that’s the next option to follow

curl utility works like a charm, so my conclusion is it should be something wrong with http-binding.
possible workaround is to install exec-binding and execute a script calling curl and playing around with received JSON … seems like scratching around the head, but so far it could be the only option to get something out of it

Never used CURL myself. If you post your findings I’ll assist to write rule (s).

Thx for your support … will get back

Have a look into this Thread.
I think it is worth a try adjusted to the Hydrawise problem. I didn’t have enough time today, will do a test and report back.