ravedog Posted July 5, 2015 Posted July 5, 2015 (edited) Hey everyone, Tried an experiment using my Synology SS and actions. I wanted a cameras motion to trigger the ISY to turn on a light. Using the URL: https://USER:PASSWORD@192.168.1.150/rest/nodes/2A%209E%205%201/cmd/DFON in Safari and it works. Light comes on. However, using that URL in the Synology action it "Fails" (no explanation of course) I have tried moving the user name and password into the fields and still no luck. Any ideas? Thanks Found the log: Jul 5 13:44:10 extcmdexecutor.cpp:85:ExecuteMain(): Failed to send POST external command with error [3]. Jul 5 13:46:30 extcmdexecutor.cpp:81:ExecuteMain(): Failed to send GET external command with error [3]. Edited July 5, 2015 by ravedog
bleepblorp Posted July 5, 2015 Posted July 5, 2015 Have you seen this thread already? http://forum.universal-devices.com/topic/14890-synology-surveillance-station-and-rest/
ravedog Posted July 5, 2015 Author Posted July 5, 2015 Hi bleep... Yes... I did... and quite frankly - the whole thread seem to confuse me... I don't want to run external code or something on another server - I just want to call a url to turn on a light. The URL I'm using works perfectly in a web browser or using CURL. I'm not sure why it wouldn't work. Does SS 7 not work this way? That thread (like a lot of threads here on the UD forms) contains a lot of information... Calling from the ISY to the ISY... installing a PHP on the web server... I just was trying to find out if the action rule in the SS will work with a URL scheme to the ISY. The ISY already allows you to form a single URL to perform an action. Was hoping that the SS would allow me to pass this directly. (as you can see from the log its trying both POST and GET and still failing....)
bleepblorp Posted July 6, 2015 Posted July 6, 2015 Hey ravedog, That other thread was originally talking about trying to accomplish exactly the same thing that you are (SS triggers ISY) and then later refers to doing the reverse (ISY triggers SS). The first issue was solved by jwagner010: Follow these 3 steps to allow SS to trigger ISY ... http://forum.universal-devices.com/topic/14890-synology-surveillance-station-and-rest/?p=127785 ... but use this updated script for step 2 http://forum.universal-devices.com/topic/14890-synology-surveillance-station-and-rest/?p=127932 The key is that SS is not performing an HTTP GET when it executing Actions for External devices. I and others have fed back to Synology that they need to add an option to allow you to choose what SS should send for each action (similar to when you create an ISY Network Resource). If you don't have a need for ISY trigger to SS then you can ignore the rest of the thread.
ravedog Posted July 7, 2015 Author Posted July 7, 2015 Ahhhh. Thank you for that!!!! I will re-read that part and have a second look. Thank you for pointing that out On another note: did you see my log file? One was POST one was GET. Both failing. Is the SS trying both ways?
bleepblorp Posted July 8, 2015 Posted July 8, 2015 I didn't notice that your log file shows an error for POST and GET. That IS interesting, but not totally sure what to make of it :/ I'll take another look at this on the weekend though!
ravedog Posted July 8, 2015 Author Posted July 8, 2015 Had to dig to find the logs but there it was: every event triggered a pair of post and get.
xKing Posted July 9, 2015 Posted July 9, 2015 See if http:// works? Without s Sent from my iPhone using Tapatalk
ravedog Posted July 10, 2015 Author Posted July 10, 2015 (edited) Woohoo! It works! I had to change it to http:// and then move the username and password from the URL down to the fields. It worked! Now I'll just have it do a variable state change to trigger a program running a timer so it can shut off at the end of a pre-determined length!!! Thank you for your help! So I'm guessing that from reading the other post, that when that post was created, that the SS only invoked one method (POST) when SS 7 was first released. Rather than adding the option of letting the user chose POST or GET as a method - I guess they updated it to try both behind the scenes? Edited July 10, 2015 by ravedog
Recommended Posts