Node-Red Flow Samples/Sharing

Funny thing is that I'm usually the RTFM type but here I was relying on the node info in the sidebar which I wrongly assumed had all the goods. Another example of ASSuME.

@LosinIt just a thought now that you have multiple fields working you could just have one influxdb table for internet stats

I think

1 Like

And I'd like to but I'm not sure of the formatting... which brings up a question I was about to ask you:

How does one get to the -contrib- docs? I always check them via the option when installing to the palette but I'm not finding them on the NR site and nothing in the community there either (that I've found).

I start here
https://flows.nodered.org/search?term=influx
or google the node name :slight_smile:

1 Like

And there's the answer to my formatting question :blush: :+1:

Title - Motion lighting that is disabled with button press

Summary - I have motion lighting for lamps in the bedroom that is over ridden to stop lights coming on or off when we are in bed reading, this is triggered with a button press (either 1,2 or 3) that will either turn lights on or off depending on what we defire. This is then reset at 8pm each night to enable motion again (we usually have story time in our bedroom with curtains closed at 7pm) then the boy does to bed

Picture -

Flow -

Summary

[{"id":"e55770ba.67ea2","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"f56bcac9.b5b888","type":"hubitat device","z":"e55770ba.67ea2","name":"Master Bedroom Motion Sensor","server":"89a479f5.5c31e8","deviceId":"197","attribute":"motion","sendEvent":true,"x":130,"y":40,"wires":[["f3c54af.cc681b8"]]},{"id":"f3c54af.cc681b8","type":"switch","z":"e55770ba.67ea2","name":"Active/Inactive","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"active","vt":"str"},{"t":"eq","v":"inactive","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":380,"y":40,"wires":[["63ae3a3a.6e7064"],["1d5f6357.2e3e7d"]]},{"id":"a9f67b10.4767f8","type":"hubitat mode","z":"e55770ba.67ea2","name":"","server":"89a479f5.5c31e8","sendEvent":false,"x":1030,"y":40,"wires":[["d9e82524.1a2d98"]]},{"id":"d9e82524.1a2d98","type":"switch","z":"e55770ba.67ea2","name":"","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"Evening","vt":"str"},{"t":"eq","v":"Night","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":1190,"y":40,"wires":[["2d210c01.435d24","5e4eea2.ffc4d14"],["2d210c01.435d24","5e4eea2.ffc4d14"]]},{"id":"2d210c01.435d24","type":"hubitat command","z":"e55770ba.67ea2","name":"Lamp (K) On","server":"89a479f5.5c31e8","deviceId":"866","command":"on","commandArgs":"","x":1370,"y":20,"wires":[[]]},{"id":"5e4eea2.ffc4d14","type":"hubitat command","z":"e55770ba.67ea2","name":"Lamp (S) On","server":"89a479f5.5c31e8","deviceId":"865","command":"on","commandArgs":"","x":1370,"y":60,"wires":[[]]},{"id":"3be6c467.532c9c","type":"hubitat command","z":"e55770ba.67ea2","name":"Lamp (K) Off","server":"89a479f5.5c31e8","deviceId":"866","command":"off","commandArgs":"","x":1370,"y":100,"wires":[[]]},{"id":"7ff44669.022038","type":"hubitat command","z":"e55770ba.67ea2","name":"Lamp (S) Off","server":"89a479f5.5c31e8","deviceId":"865","command":"off","commandArgs":"","x":1370,"y":140,"wires":[[]]},{"id":"c13d2d0a.9ddcf","type":"change","z":"e55770ba.67ea2","name":"Send Stop","rules":[{"t":"set","p":"payload","pt":"msg","to":"stop","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":990,"y":100,"wires":[["1cbcdb45.cf2205"]]},{"id":"1cbcdb45.cf2205","type":"stoptimer","z":"e55770ba.67ea2","duration":"2","units":"Millisecond","payloadtype":"num","payloadval":"0","name":"Timer","x":1150,"y":120,"wires":[["3be6c467.532c9c","7ff44669.022038"],[]]},{"id":"54ef2ee0.a7c21","type":"hubitat device","z":"e55770ba.67ea2","name":"Button","server":"89a479f5.5c31e8","deviceId":"257","attribute":"pushed","sendEvent":true,"x":70,"y":300,"wires":[["b8e88932.6511e8"]]},{"id":"442bb1d6.de994","type":"switch","z":"e55770ba.67ea2","name":"1,2 or 3","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"},{"t":"eq","v":"2","vt":"str"},{"t":"eq","v":"3","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":480,"y":300,"wires":[["4984255e.09853c","8832b5c0.9bd6c8"],["dafc6f92.7eed1","d9b85ba7.d33128"],["69048018.08d2a","dafc6f92.7eed1"]]},{"id":"dafc6f92.7eed1","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Lamp (K) Off","server":"89a479f5.5c31e8","deviceId":"866","command":"off","commandArgs":"","x":890,"y":340,"wires":[[]]},{"id":"d9b85ba7.d33128","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Lamp (S) Off","server":"89a479f5.5c31e8","deviceId":"865","command":"off","commandArgs":"","x":890,"y":380,"wires":[[]]},{"id":"4984255e.09853c","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Lamp (K) On 40","server":"89a479f5.5c31e8","deviceId":"866","command":"setLevel","commandArgs":"40","x":900,"y":260,"wires":[[]]},{"id":"8832b5c0.9bd6c8","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Lamp (S) On 40","server":"89a479f5.5c31e8","deviceId":"865","command":"setLevel","commandArgs":"40","x":900,"y":300,"wires":[[]]},{"id":"69048018.08d2a","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Lamp (S) On 15","server":"89a479f5.5c31e8","deviceId":"865","command":"setLevel","commandArgs":"15","x":900,"y":420,"wires":[[]]},{"id":"b8e88932.6511e8","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Virtual Switch","server":"89a479f5.5c31e8","deviceId":"898","command":"on","commandArgs":"","x":270,"y":300,"wires":[["442bb1d6.de994"]]},{"id":"d6aac5e.7b45038","type":"switch","z":"e55770ba.67ea2","name":"","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":870,"y":40,"wires":[["c13d2d0a.9ddcf","a9f67b10.4767f8"]]},{"id":"63ae3a3a.6e7064","type":"hubitat device","z":"e55770ba.67ea2","name":"Master Bedroom Virtual Switch","server":"89a479f5.5c31e8","deviceId":"898","attribute":"switch","sendEvent":false,"x":630,"y":40,"wires":[["d6aac5e.7b45038"]]},{"id":"ca2abbd0.0a6848","type":"bigtimer","z":"e55770ba.67ea2","outtopic":"","outpayload1":"","outpayload2":"","name":"Big Timer","comment":"","lat":"52.699219","lon":"-1.367270","starttime":5001,"endtime":1425,"starttime2":"1200","endtime2":0,"startoff":0,"endoff":0,"startoff2":0,"endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":true,"feb":true,"mar":true,"apr":true,"may":true,"jun":true,"jul":true,"aug":true,"sep":true,"oct":true,"nov":true,"dec":true,"day1":0,"month1":0,"day2":0,"month2":0,"day3":0,"month3":0,"day4":0,"month4":0,"day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":100,"y":420,"wires":[["ab280dee.2a55a"],[],["ab280dee.2a55a"]]},{"id":"ab280dee.2a55a","type":"switch","z":"e55770ba.67ea2","name":"","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":270,"y":420,"wires":[["f7dbdf61.50304"]]},{"id":"f7dbdf61.50304","type":"hubitat command","z":"e55770ba.67ea2","name":"Master Bedroom Virtual Switch","server":"89a479f5.5c31e8","deviceId":"898","command":"off","commandArgs":"","x":540,"y":420,"wires":[[]]},{"id":"10af3a6.41a46c6","type":"switch","z":"e55770ba.67ea2","name":"","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1010,"y":140,"wires":[["1cbcdb45.cf2205"]]},{"id":"1d5f6357.2e3e7d","type":"hubitat device","z":"e55770ba.67ea2","name":"Master Bedroom Virtual Switch","server":"89a479f5.5c31e8","deviceId":"898","attribute":"switch","sendEvent":false,"x":630,"y":140,"wires":[["10af3a6.41a46c6"]]},{"id":"89a479f5.5c31e8","type":"hubitat config","z":"","name":"AVA","usetls":false,"host":"192.168.4.32","port":"80","appId":"966","nodeRedServer":"http://192.168.2.15:1880","webhookPath":"/hubitat/webhook_","autoRefresh":true,"useWebsocket":false}]

1 Like

Excellent idea! Cleaned up the flow by using the batch node and the function now is:

Code
msg.payload = [
    {
        measurement: "download",
        fields: {
            value:msg.payload.speeds.download
        },
        tags:{
            unit:"Mbps"
        },
    },
    {
        measurement: "upload",
        fields: {
            value:msg.payload.speeds.upload
        },
        tags:{
            unit:"Mbps"
        },
    },
    {
        measurement: "ping",
        fields: {
            value:msg.payload.server.ping
        },
        tags:{
            unit:"ms"
        },
    }
];
return msg;
1 Like

So you have to make an empty repo in github and then add that repo's link, either https or ssh, I chose https, as a remote repo in NR, then you make a new remote branch which you can push to.

I did all that I also needed to restart NR and then it worked

1 Like

So how would one go about storing a previous device value in a flow and then restoring it? I.e I have Hue lights that come on in the evening (thanks to the example flows here to get that working); somebody rings the doorbell and I have the hue lights throughout the house turn green for a few minutes before restoring back to the previous state. I've got it working in RM, sort of, but its not consistent (it'll work partially since some of the hue lights will turn the correct color, others won't, and some will restore, while others won't; 'course sometimes it works perfectly...it's those oddball times we end up with a mix of colors that the wife just looks over at me with no comment...)

I've been tinkering with trying to export state to a file and then back in, but of course that doesn't work when the current state would immediately overwrite the previous state...

Thanks in advance; this has been an extremely informative and helpful thread.

Store the device attribute value to a flow variable (using a change node).

Whenever desired, you can set "msg.arguments" to the value of that flow variable (also using a change node) and pass it along to a command node to restore the previous setting for that device attribute.

4 Likes

That's the info I was looking for, thanks!

1 Like

I'm hoping someone can help me with a NR problem not related to Hubitat.
I am using iSpy Agent DVR for my cameras. They have an API that lets me control the cameras. If I use the command http://192.168.4.213:8090/command.cgi?cmd=setProfile&ind=1 directly in my browser, it executes the command properly. However, in NR I can put in a HTTP request and it does nothing. The debug returns an empty payload. Here is the flow. What do I need to change?
image
[{"id":"315c41db.5cdf6e","type":"inject","z":"533c47cf.8888e8","name":"Set Profile","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"command.cgi?cmd=setProfile&ind=1","payloadType":"str","x":180,"y":500,"wires":[["e9daca13.fdb898"]]},{"id":"e9daca13.fdb898","type":"http request","z":"533c47cf.8888e8","name":"","method":"PUT","ret":"txt","paytoqs":"body","url":"http://192.168.4.213:8090/","tls":"","persist":false,"proxy":"","authType":"","x":370,"y":500,"wires":[["417801e8.06fb4"]]},{"id":"417801e8.06fb4","type":"debug","z":"533c47cf.8888e8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":530,"y":500,"wires":[]}]

You can use context variables. There are 3 levels of these; node, flow, and global level (the last two of which are like local/rule based and global variables in HE respectively). These are also persistent across a Node-RED restart.

https://nodered.org/docs/user-guide/context

2 Likes

When you open that through the browser, do you have to log in?

Also, have you tried a POST vs PUT?

Actually, maybe a GET is what they are looking for since it's all URL parameters and not a payload.

No authorization needed.
Tried POST, PUT, and GET.

Anyway, found another way to make it work using HubitatPublic/httpGetSwitch.groovy at master · hubitat/HubitatPublic · GitHub

Try this?

[{"id":"ea790395.75feb","type":"inject","z":"bf2927e5.5af798","name":"Set Profile","props":[{"p":"cmd","v":"setProfile","vt":"str"},{"p":"ind","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":1000,"y":580,"wires":[["56af21d.9b4c4e"]]},{"id":"56af21d.9b4c4e","type":"http request","z":"bf2927e5.5af798","name":"","method":"GET","ret":"txt","paytoqs":"query","url":"http://192.168.4.213:8090/command.cgi","tls":"","persist":false,"proxy":"","authType":"","x":1190,"y":580,"wires":[["da69786b.1b9358"]]},{"id":"da69786b.1b9358","type":"debug","z":"bf2927e5.5af798","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1350,"y":580,"wires":[]}]

or this (with the command as part of the payload object):

[{"id":"ea790395.75feb","type":"inject","z":"bf2927e5.5af798","name":"Set Profile","props":[{"p":"payload.cmd","v":"setProfile","vt":"str"},{"p":"payload.ind","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":1000,"y":580,"wires":[["ea882e9c.07a1e","56af21d.9b4c4e"]]},{"id":"56af21d.9b4c4e","type":"http request","z":"bf2927e5.5af798","name":"","method":"GET","ret":"txt","paytoqs":"query","url":"http://192.168.4.213:8090/command.cgi","tls":"","persist":false,"proxy":"","authType":"","x":1190,"y":580,"wires":[["da69786b.1b9358"]]},{"id":"da69786b.1b9358","type":"debug","z":"bf2927e5.5af798","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1350,"y":580,"wires":[]}]

Does anyone have a flow that monitors systems names/IPs on a local network where notifications would be sent to Pushover on a down state? I've seen a few out there with dashboards, and while it's neat it's completely not needed in my case. I could easily create separate flows that monitors a single Name/IP but I'm just having an issue wrapping my head around a single flow that could monitor many Names/IPs and send notifications with the correct Name/IP.

Title Log Proxmox data to influxDB

Summary -
A very simple flow to log CPU utilization, Memory usage and disk usage for a proxmox server

Flow

[
{
"id": "c91fde37.9e188",
"type": "tab",
"label": "Flow 1",
"disabled": false,
"info": ""
},
{
"id": "2b9b14aa.15da2c",
"type": "group",
"z": "c91fde37.9e188",
"name": "Log Proxmox",
"style": {
"fill": "#bfdbef",
"label": true,
"color": "#0070c0"
},
"nodes": [
"d8ac4a74.7936f8",
"78d57918.4be748",
"5169f3e2.cfb74c",
"9457217c.43276"
],
"x": 34,
"y": 139,
"w": 852,
"h": 82
},
{
"id": "d8ac4a74.7936f8",
"type": "proxmox-api",
"z": "c91fde37.9e188",
"g": "2b9b14aa.15da2c",
"name": "",
"path": "/nodes",
"method": "GET",
"payload": "",
"server": "7baaadb4.455784",
"x": 410,
"y": 180,
"wires": [
[
"78d57918.4be748"
]
]
},
{
"id": "78d57918.4be748",
"type": "function",
"z": "c91fde37.9e188",
"g": "2b9b14aa.15da2c",
"name": "prep data",
"func": "msg.payload = [\n {\n measurement: "CPU",\n fields: {\n value:msg.payload[0].cpu \n },\n tags:{\n unit:"%",\n host:msg.payload[0].node\n },\n },\n {\n measurement: "Memory",\n fields: {\n value:msg.payload[0].mem / 1000000000\n },\n tags:{\n unit:"Gb",\n host:msg.payload[0].node\n },\n },\n {\n measurement: "Disk",\n fields: {\n value:msg.payload[0].disk / 1000000000\n },\n tags:{\n unit:"Gb",\n host:msg.payload[0].node\n },\n }\n];\nreturn msg;\n",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"x": 600,
"y": 180,
"wires": [
[
"5169f3e2.cfb74c"
]
]
},
{
"id": "5169f3e2.cfb74c",
"type": "influxdb batch",
"z": "c91fde37.9e188",
"g": "2b9b14aa.15da2c",
"influxdb": "4bcce287.69402c",
"precision": "",
"retentionPolicy": "",
"name": "Load influx",
"x": 790,
"y": 180,
"wires": []
},
{
"id": "9457217c.43276",
"type": "cronplus",
"z": "c91fde37.9e188",
"g": "2b9b14aa.15da2c",
"name": "Every MInute",
"outputField": "payload",
"timeZone": "America/New_York",
"persistDynamic": false,
"commandResponseMsgOutput": "output1",
"outputs": 1,
"options": [
{
"name": "schedule1",
"topic": "schedule1",
"payloadType": "str",
"payload": "start",
"expressionType": "cron",
"expression": "0 * * * * *",
"location": "",
"offset": "0",
"solarType": "all",
"solarEvents": "sunrise,sunset"
}
],
"x": 150,
"y": 180,
"wires": [
[
"d8ac4a74.7936f8"
]
]
},
{
"id": "7baaadb4.455784",
"type": "proxmox-server",
"z": "",
"host": "192.168.1.32",
"port": "8006"
},
{
"id": "4bcce287.69402c",
"type": "influxdb",
"z": "",
"hostname": "192.168.1.183",
"port": "8086",
"protocol": "http",
"database": "hubitat",
"name": "",
"usetls": false,
"tls": ""
}
]

2 Likes

Title: Control lights specific to room with Alexa using same phrase

Summary: This allows you to use a single command to any Alexa and she will turn on lights based on which Alexa you are speaking.

Details: This flow allows for me to say "Illuminate" (Wesley Snipes in The Demolition Man); "Lumos Maxima" (Harry Potter), or "Make it light" to any Alexa and she will turn on the lights specific to the Alexa that I am speaking. With the node-red-contrib-alexa-remote2 node palette, there is a node that listens and msg.payload.description.summary is a summary of what she heard. The 1st Switch Node determines if she heard one of the phrases and acts appropriately. The Listening Node also provides msg.payload.deviceSerialNumber which is specific to each of the Alexas. The 2nd Switch Node determines which device to send command(s) based on Serial Number of device

I have a second flow that turns lights off to "Deluminate"; "Make it Dark" or "Lumos Minima". My third one will turn on appropriate fan to low when I say "It is hot in here".

I know this is not a complicated flow but the Listening Node in alexa-remote2 palette is powerful in this way and I thought some that installed it might not realize all of the information that it generates into a debug node. I recommend setting up the Listening Node and a Debug node (showing complete message object) and looking closely at the result in the debug window when you speak to Alexa. You might be surprised.

Note: You MUST also create a Routine in Alexa app with same name as the word/phrase you are using in flow and make it perform a 5 second wait. Otherwise, Alexa will try on her own to figure out what you mean and go looking out on the "interwebs". The 5 second wait won't affect the speed of your flow.

EDIT 9 MONTHS LATER: Instead of creating a bunch of dummy routines, you should be able to instead create an Alexa Q&A Blueprint and all of the phrase variations can all be in that one skill, thereby eliminating all of the dummy routines. See my post #461 below.

[{"id":"1dd953c7.b02acc","type":"alexa-remote-event","z":"f7404a38.ee3e88","name":"","account":"f3ed7c17.a3729","event":"ws-device-activity","x":170,"y":1700,"wires":[["3b54ccd6.116214"]]},{"id":"3b54ccd6.116214","type":"switch","z":"f7404a38.ee3e88","name":"Light It Up; Illuminate: or Lumos Maxima","property":"payload.description.summary","propertyType":"msg","rules":[{"t":"cont","v":"light it up","vt":"str"},{"t":"cont","v":"illuminate","vt":"str"},{"t":"cont","v":"lumos maxima","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":460,"y":1700,"wires":[["1c465de.e0a58a2"],["1c465de.e0a58a2"],["1c465de.e0a58a2"]]},{"id":"5abca6ca.45a228","type":"hubitat command","z":"f7404a38.ee3e88","name":"Ainsleys Fan Bulb ON","server":"e2175bd0.e82808","deviceId":"681","command":"on","commandArgs":"","x":1200,"y":1740,"wires":[[]]},{"id":"678d6870.abe8e8","type":"hubitat command","z":"f7404a38.ee3e88","name":"Declans Fan Bulb ON","server":"e2175bd0.e82808","deviceId":"347","command":"on","commandArgs":"","x":1160,"y":1880,"wires":[[]]},{"id":"9228e75e.a045d8","type":"hubitat command","z":"f7404a38.ee3e88","name":"Living Room ON","server":"e2175bd0.e82808","deviceId":"2185","command":"on","commandArgs":"","x":1100,"y":1440,"wires":[[]]},{"id":"401d936c.30afcc","type":"hubitat command","z":"f7404a38.ee3e88","name":"Master Bedroom Bulb ON","server":"e2175bd0.e82808","deviceId":"582","command":"on","commandArgs":"","x":1210,"y":1580,"wires":[[]]},{"id":"68d93176.6f7f6","type":"hubitat command","z":"f7404a38.ee3e88","name":"Kitchen ON","server":"e2175bd0.e82808","deviceId":"485","command":"on","commandArgs":"","x":1110,"y":1480,"wires":[[]]},{"id":"a8df8300.8d8b4","type":"hubitat command","z":"f7404a38.ee3e88","name":"Dining Room ON","server":"e2175bd0.e82808","deviceId":"37","command":"on","commandArgs":"","x":1150,"y":1520,"wires":[[]]},{"id":"de322c3c.8bca9","type":"hubitat command","z":"f7404a38.ee3e88","name":"Reading Nook ON","server":"e2175bd0.e82808","deviceId":"3142","command":"on","commandArgs":"","x":1190,"y":1620,"wires":[[]]},{"id":"ab9685bb.4a8cf8","type":"hubitat command","z":"f7404a38.ee3e88","name":"Master Lamp ON","server":"e2175bd0.e82808","deviceId":"967","command":"on","commandArgs":"","x":1190,"y":1660,"wires":[[]]},{"id":"84f133e3.265","type":"hubitat command","z":"f7404a38.ee3e88","name":"Ainsleys Lamp ON","server":"e2175bd0.e82808","deviceId":"852","command":"on","commandArgs":"","x":1190,"y":1780,"wires":[[]]},{"id":"f974442.d233cb8","type":"hubitat command","z":"f7404a38.ee3e88","name":"Ainsleys Night Light ON","server":"e2175bd0.e82808","deviceId":"851","command":"on","commandArgs":"","x":1210,"y":1820,"wires":[[]]},{"id":"3b8d1b62.9ac5c4","type":"hubitat command","z":"f7404a38.ee3e88","name":"Declans Lamp ON","server":"e2175bd0.e82808","deviceId":"40","command":"on","commandArgs":"","x":1130,"y":1920,"wires":[[]]},{"id":"11ade24c.5da0ee","type":"hubitat command","z":"f7404a38.ee3e88","name":"Declans Night Light ON","server":"e2175bd0.e82808","deviceId":"329","command":"on","commandArgs":"","x":1130,"y":1960,"wires":[[]]},{"id":"1c465de.e0a58a2","type":"switch","z":"f7404a38.ee3e88","name":"Which Device?","property":"payload.deviceSerialNumber","propertyType":"msg","rules":[{"t":"eq","v":"G000MW0474520JG4","vt":"str"},{"t":"eq","v":"90F0071863140022","vt":"str"},{"t":"eq","v":"G0014B05949214EG","vt":"str"},{"t":"eq","v":"G090LF1073240EBM","vt":"str"},{"t":"eq","v":"G090LF11822302U5","vt":"str"}],"checkall":"true","repair":false,"outputs":5,"x":740,"y":1700,"wires":[["9228e75e.a045d8","68d93176.6f7f6","a8df8300.8d8b4"],["401d936c.30afcc","de322c3c.8bca9","ab9685bb.4a8cf8"],["401d936c.30afcc","de322c3c.8bca9","ab9685bb.4a8cf8"],["5abca6ca.45a228","84f133e3.265","f974442.d233cb8"],["11ade24c.5da0ee","3b8d1b62.9ac5c4","678d6870.abe8e8"]],"outputLabels":["LIVING ROOM","MASTER BEDROOM","ANTIQUE RADIO ECHO FLEX","AINSLEYS BEDROOM","DECLANS DOT"]},{"id":"f3ed7c17.a3729","type":"alexa-remote-account","z":"","name":"ALEXA-192.168.68.139","authMethod":"proxy","proxyOwnIp":"192.168.68.139","proxyPort":"3456","cookieFile":"authFile","refreshInterval":"3","alexaServiceHost":"pitangui.amazon.com","amazonPage":"amazon.com","acceptLanguage":"en-US","userAgent":"","useWsMqtt":"on","autoInit":"on"},{"id":"e2175bd0.e82808","type":"hubitat config","z":"","name":"HUBITAT HUB","usetls":false,"host":"192.168.68.124","port":"80","appId":"2569","nodeRedServer":"http://192.168.68.139:1880","webhookPath":"/hubitat/webhook","autoRefresh":false}]

EDIT: Since posting this originally, issues have arisen with the alexa2-remote palette. Instead, please use node-red-contrib-alexa-applestrudel which was forked from alexa2-remote.

11 Likes