How to configure HTTP Request command?

Fredrik Hänninen shared this problem 10 months ago
Known

I try to activate motion detection in an IP-camera when the alarm i armed.

I found out that this URL works fine:

192.168.X.X/motion.cgi?MotionDetectionEnable=1&ConfigReboot=No&user=XXXXX&pwd=XXXXX

When I write it in the webbrowser and press enter it works fine. I can turn motion detection on and off.

I tried to use it with a HTTP Request command but it wont work.

I guess the problem is that I don't know how to send http-request from Zipatile.

Can someone help me, please. Explain how to use it or give an example.

Best Answer
photo

I managed to solve it now, by using GET and this url: http://admin:password@192.168.1.X/motion.cgi?MotionDetectionEnable=1&ConfigReboot=No

Comments (18)

photo
1

This is how the rule works.

photo
1

I figured out the problem but not how to solve it.

After I restarted the computer the URL did not work if I did not enter the username and password.

After I enter the user name and password this URL work

http://192.168.X.XX/motion.cgi?MotionDetectionEnable=0&ConfigReboot=No


Obviesly I don't get access to the camera.

How am I supposed to write the url to get the auktorisation?

photo
1

Hello Fredrik,

I tell you how I use this feature. In my case the camera is able to send a http request when an event happens. So I've created a rule on my camera that calls to a certain URL when motion is detected. But which URL?

In Zipato I have created a virtual sensor and I use that URL to make the sensor, which I've called "Movement".

My problem was that the camera only calls once each time it detects movement. And doesn't call to set moment = no. So in zipato I've created a rule with a timmer to make "Movement" = NO.

photo
1

I This is not the solution I'm lockning for. My camera cant send http requests. I just want to turn of motion detection so the camera stops sending mail when I'm at home.

I'm still interested in you example, how did you write the code in the camera and in the rule creator? Can you post some snapshots?

photo
1

Did you try "Post" rather than "Put"? Just a thought.

photo
1

I did try both.

Thank you. It could be the smallest mistake.

photo
1

Fredrik, in my case the camera detects the movement and activates a rule into the camera. That rule into the camera calls to a url (Zipato virtual sensor). In my case I am not allowed to access to this property of the camera with nor without a password.

photo
1

Fredrik, where you able to solve this?

I have Dlink camera and this url works fine in browser. But wont work with Zipato.

http://192.168.1.X/motion.cgi?MotionDetectionEnable=1&ConfigReboot=No&user=admin&pwd=password

photo
2

I managed to solve it now, by using GET and this url: http://admin:password@192.168.1.X/motion.cgi?MotionDetectionEnable=1&ConfigReboot=No

photo
1

Ja Mattias det fungerar.

It works

The trouble was that, the http command that needed separat login did only work with internet explorer. For that reason I did all tests with explorer.

I tried you code in chrome. It worked fine without separat login. And it works with zipatile and my dlink.

Thank you very much.

photo
photo
1

Solution is this format

http://admin:password@192.168.1.X/motion.cgi?MotionDetectionEnable=1&ConfigReboot=No

It works with chrome and Zipato http command but not with internet explorer.

photo
1

My problem is similar. I wand to send an URL to my Devolo Home Control to activate a scene there. I have a URL to trigger this scene. It works on my chrome explorer. If I give this URL in the address field of chrome the scene is triggered. However I tried different configurations with HTTP-Request of Zipato. None worked. I think years ago I had success, but now I need your help how to configure HTTP-Request.

photo
1

if you send the url from your browser it should work via the http puzzle. Have you tried get and post methods?

When you send from your browser, have you already logged in with a password previously? Is there a login and password in your url if so?

photo
1

Yes I have tried get &post, but I have not included a password in URL. The URL is: https://www.mydevolo.com/v1/hc/gateways/1504013000002245/scenes/......... How to include the password??

photo
1

Now I used the user/password as above user:password@

https://mic.....:ba......@http://www.mydevolo.com/v1/hc/gateways/1504013000002245/scenes/........

It does not work either.

photo
1

I think HTTP-Request does not support HTTPS. Zipato, can you confirm this?

photo
1

I think that is correct. Only HTTP not HTTPS.

photo
1

also you the url you have has 2 * http:// in it. You will need to look at your api to see how devolo attach login and passwords to a url. They may not even support it in a url post.

photo