If you want to have seperate alert tones for the 'doorbell' and 'motion alerts', you will probably need something like this;
[
{
"id": "82ae385.23acfc8",
"type": "function",
"z": "6eb37a1d.ee8f34",
"name": "Ring or motion?",
"func": "if (msg.topic == \"ring event\") {\n var kind = (msg.payload.kind); \n if (kind == \"ding\") {\n return [ msg, null ];\n }\n else if (kind == \"motion\") {\n return [ null, msg ];\n }\n}\nreturn msg;",
"outputs": 2,
"noerr": 0,
"x": 710,
"y": 630,
"wires": [
[
"a1483470.abcbb8"
],
[
"86781f7b.6a76b"
]
]
},
{
"id": "e210d4e5.3c2648",
"type": "ring doorbell",
"z": "6eb37a1d.ee8f34",
"testmode": "N",
"verbose": "N",
"topic": "",
"name": "",
"x": 530,
"y": 630,
"wires": [
[
"82ae385.23acfc8"
]
]
},
{
"id": "a1483470.abcbb8",
"type": "chromecast-play",
"z": "6eb37a1d.ee8f34",
"name": "Google Home - Ring",
"url": "http://yoursite/ring.mp3",
"contentType": "audio/mp3",
"ip": "192.168.1.6",
"x": 920,
"y": 610,
"wires": [
[]
]
},
{
"id": "86781f7b.6a76b",
"type": "chromecast-play",
"z": "6eb37a1d.ee8f34",
"name": "Google Home - Motion",
"url": "http://yoursite/motion.mp3",
"contentType": "audio/mp3",
"ip": "192.168.1.6",
"x": 920,
"y": 650,
"wires": [
[]
]
}
]