MWareman Posted December 24, 2016 Share Posted December 24, 2016 (edited) TL;DR; "Please add and expose logging to ISY Portal for inbound requests containing the users inbound key.... with the HTTP code response..." .... So, spending time messing with Google Home (Assistant) - and it's really cool. One thing I'm working on right now is fan control. So, I have 4 scenes ('Fan-Off', 'Fan-Low', 'Fan-Medium' and 'Fan-High') and these all work flawlessly with a KPL. I have created ISY Portal IFTTT triggers for these scenes: https://my.isy.io/api/ifttt/family_fan_off/key/{GUID-removed-for-security} https://my.isy.io/api/ifttt/family_fan_low/key/{GUID-removed-for-security} https://my.isy.io/api/ifttt/family_fan_medium/key/{GUID-removed-for-security} https://my.isy.io/api/ifttt/family_fan_high/key/{GUID-removed-for-security} POSTing to the URLs results in correct activation... All good so far, and nothing unusual here. In IFTTT, I have created a applet with 'Google Assistant' in the 'If' section, and 'Maker' in the 'Then'. Here are the details: Say a phrase with a text ingredient What do you want to say? "set family fan $" What's another way to say it? "set family fan to $" And another way? "set fan $" What do you want the Assistant to say in response? "Setting family room fan $" Make a web request URL "https://my.isy.io/api/ifttt/family_fan_{{TextField}}/key/{GUID-removed-for-security}" Method: "POST" Content Type: "application/x-www-form-encoded" For those that are used to Alexa, Google Assistant has the ability to parse a word, value or a word and value from what you say, and use that element in the response. In this case, I'm having it parse 'off', 'low' etc from my verbal request, and using it in the response URL to Maker (and ultimately the ISY Portal). Should be very cool - except when I ask 'Hey Google, Family Fan Low', Home responds 'Setting family room fan low' but nothing happens. If I look at the IFTTT activity log for the applet, I see two errors logged for the verbal action: "set family fan low" "! Maker Error - An error with Maker prevented your Applet from working" and "! Action Skipped" After some digging around, I found the site to look at what Google home heard (you have to enable request logging in your Google Account first - ... 'https://myactivity.google.com/item?product=31' I discovered that Google Home was hearing 'set family fan love' instead... resulting in the URL being 'https://my.isy.io/api/ifttt/family_fan_love/key/{GUID-removed-for-security}'. This results in a '400 - Bad Request' from the ISY Portal when Maker sends it... It would be nice if they added the ability to constrain $ so one of a list of possible words (something like ${low|medium|high|off}) - but it's still a pretty cool ability. What took me 4 rules with Alexa I've done with one on Google Home. Now, the feature requests.... On ISY Portal - clearly the currently named 'IFTTT Inbound Events' can, in fact, be used for services other than IFTTT. It's likely more properly named 'Inbound webhooks' or 'Inbound triggers'. Any chance you could consider renaming this? Also, renaming the key (from "IFTTT inbound key" to "Inbound key")... Second, there is no logging of requests exposed. Under 'Logs' - could you expose inbound requests that contain the users current key... This way, we can see requests that have the key, but do not otherwise match configured rules... If we had this, it would have been trivial to see the problem (I would have seen a request to 'https://my.isy.io/api/ifttt/family_fan_love}/key/{GUID-removed-for-security}' with the 400 error that resulted...). It would make troubleshooting *much* easier... Thank you! Michael. Edited December 24, 2016 by MWareman Quote Link to comment
apostolakisl Posted December 25, 2016 Share Posted December 25, 2016 This is a little off topic from what you are saying but in the same line. I was looking at some example code that has been written for Amazon to control DirecTV receivers. It appears that you can avoid the IFTTT thing alogether and go direct from a custom Alexa skill to your ISY. Based on my first run through, it looks like you can parse everything directly and substitute variables. For example, you might say, Alexa change channel to <name of channel here or number> and it will either plug in the number you say or look up the name you say and substitute the number. In my mind this is the best way to work all of this as it has the least number of moving parts. Quote Link to comment
Michel Kohanim Posted December 25, 2016 Share Posted December 25, 2016 Hi Michael, Thanks so very much for the details and suggestions. We will definitely look into both (logging + renaming). With kind regards, Michel Quote Link to comment
Michel Kohanim Posted December 26, 2016 Share Posted December 26, 2016 Hi Michael, Had a chat with Benoit and we can definitely implement your suggestions shortly and along with Google Home ... I just cannot give you an ETA, sorry! One question: with regards to log - and in order to conserve space/resources - we are thinking of a round robin which only stores the last 10 connections. Would that be sufficient for you? With kind regards, Michel Quote Link to comment
MWareman Posted December 27, 2016 Author Share Posted December 27, 2016 One question: with regards to log - and in order to conserve space/resources - we are thinking of a round robin which only stores the last 10 connections. Would that be sufficient for you? Yes! Perfectly. During troubleshooting, it's usually relatively real-time anyway. Thank you! Michael. Quote Link to comment
Michel Kohanim Posted December 27, 2016 Share Posted December 27, 2016 Hi Michael, Thanks so very much (as always)! With kind regards, Michel Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.