Hello,
So i was able to setup the Dasshio using guidance provided on its GitHub page.
I was now trying to trigger multiple action on a single button press, which are
1 . Multiple HA service calls. (with domain, service, service_data)
2. Combination of a HA service and URL ( url, body, headers)
I tried to write the code the following way for 2 services call
{
"timeout": 20,
"buttons": [
{
"name": "AmazonBasic",
"address": "B4:7C:9C:00:9C:D2",
"domain": "light",
"service": "toggle",
"service_data": "{\"entity_id\": \"light.computer_desk\"}"
},
{
"name": "AmazonBasic",
"address": "B4:7C:9C:00:9C:D2",
"domain": "light",
"service": "toggle",
"service_data": "{\"entity_id\": \"light.smart_bulb\"}"
}
]
}
EDIT
Ok Found the solution for above scenario, simply add a comma “,” and enter all entities ID within the same block of quote to have action performed on multiple entities, so the correct way should be:
{
"timeout": 20,
"buttons": [
{
"name": "AmazonBasic",
"address": "B4:7C:9C:00:9C:D2",
"domain": "light",
"service": "toggle",
"service_data": "{\"entity_id\": \"light.computer_desk,light.smart_bulb\"}"
}
]
}
Similarly I tried to add an action, to trigger a HA service call by toggling the light bulb on/off and triggering a URL on IFTTT webhooks to send a mobile notification on the IFTTT mobile app. Something like below
{
"timeout": 20,
"buttons": [
{
"name": "AmazonBasic",
"address": "B4:7C:9C:00:9C:D2",
"domain": "light",
"service": "toggle",
"service_data": "{\"entity_id\": \"light.computer_desk\"}"
},
{
"name": "AmazonBasic",
"address": "B4:7C:9C:00:9C:D2",
"url": "https://maker.ifttt.com/trigger/Light_Desk/with/key/XXXXXXXXXXXX",
"headers": "{}",
"body": "{}"
}
]
}
Even in that case only the HA service is executed , that is light bulb is toggled, however the URL is never triggered, hence no notification on the mobile. If I try to run URL action separately then it is correctly fired and I receive the webhook triggered notification.
Can anyone please guide an/or correct the code above, to be able to combine multiple entities/actions/action types with a single button press.
Thanks for your help