For the following Google Assistant Home automation sync request, my backend responses for certain accounts works. But some accounts it fails and I have no clue whatsoever.
{
"requestId": "XXXXXXXXXXXX",
"inputs": [{
"intent": "action.devices.SYNC"
}]
}
How do I debug why a SYNC request has failed? Is there a console or log where I can see what went wrong.
Everything looks just fine. Similar response for some other accounts of my user base works, where as for this user's response it always doesn't work.
Not working Response:
In this instance, its failing for the following SYNC response.
[{
"payload": {
"devices": [{
"id": "7e-f2-ca-ab-40-34-34-95:1:1",
"name": {
"name": "Air Conditioner"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.OUTLET",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:2:1",
"name": {
"name": "Office Hooter"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:5:1",
"name": {
"name": "Office Motion"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:11:1",
"name": {
"name": "Buzzer"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:11:2",
"name": {
"name": "DOOR SENSOR"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:11:4",
"name": {
"name": "Presence Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:14:1",
"name": {
"name": "Blue Lamp"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:14:2",
"name": {
"name": "Green Lamp"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:14:3",
"name": {
"name": "Side Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:15:1",
"name": {
"name": "Front Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:15:2",
"name": {
"name": "Outdoor Lights"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:15:3",
"name": {
"name": "Front Dimmer"
},
"traits": ["action.devices.traits.OnOff", "action.devices.traits.Brightness"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:17:1",
"name": {
"name": "Extra Lights"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:17:2",
"name": {
"name": "Central Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:17:3",
"name": {
"name": "Fan"
},
"traits": ["action.devices.traits.OnOff", "action.devices.traits.Brightness"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:19:1",
"name": {
"name": "Key Ring"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:19:2",
"name": {
"name": "Office Door"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:19:4",
"name": {
"name": "Presence Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:6:1",
"name": {
"name": "Blue LED"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:6:2",
"name": {
"name": "Work Lights"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:6:3",
"name": {
"name": "Dimmer Back"
},
"traits": ["action.devices.traits.OnOff", "action.devices.traits.Brightness"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:4:1",
"name": {
"name": "Buzzer"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:4:2",
"name": {
"name": "Door Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:4:4",
"name": {
"name": "Presence Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:3:1",
"name": {
"name": "Plug"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.OUTLET",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:7:1",
"name": {
"name": "Curtain Up"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:7:2",
"name": {
"name": "Curtain Down"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "7e-f2-ca-ab-40-34-34-95:7:3",
"name": {
"name": "Regulator"
},
"traits": ["action.devices.traits.OnOff", "action.devices.traits.Brightness"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "27465191118001134545448968013",
"name": {
"name": "Darkness"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}, {
"id": "27465189752942073090942148334",
"name": {
"name": "Everything"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}, {
"id": "27507709627159036391184182205",
"name": {
"name": "Mood Lights"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}, {
"id": "27514704337364024105847592198",
"name": {
"name": "White Lights"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}, {
"id": "27576295525515559712639822299",
"name": {
"name": "Office Lights"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}]
},
"requestId": "4881304563722779302"
}]
Whereas for the following SYNC response, it works.
[{
"payload": {
"devices": [{
"id": "21-0b-c9-87-db-70-b6-83:1:1",
"name": {
"name": "Serial Lights"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.OUTLET",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:2:1",
"name": {
"name": "Water Heater"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.OUTLET",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:10:1",
"name": {
"name": "Panic Alarm"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:11:1",
"name": {
"name": "Hall Motion Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:16:1",
"name": {
"name": "Buzzer"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:16:2",
"name": {
"name": "Primary Door"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:16:4",
"name": {},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:6:1",
"name": {
"name": "Car Keys"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:6:2",
"name": {
"name": "Door Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:6:4",
"name": {
"name": "Presence Sensor"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:3:1",
"name": {
"name": "Dummy"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:3:2",
"name": {
"name": "All Out"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:3:3",
"name": {
"name": "Bed Room Fan"
},
"traits": ["action.devices.traits.OnOff", "action.devices.traits.Brightness"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:5:1",
"name": {
"name": "Hall Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:5:2",
"name": {
"name": "Night Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:5:3",
"name": {
"name": "Fan"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:8:1",
"name": {
"name": "Exhaust"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:8:2",
"name": {
"name": "kitchen Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"id": "21-0b-c9-87-db-70-b6-83:8:3",
"name": {
"name": "Balcony Light"
},
"traits": ["action.devices.traits.OnOff"],
"type": "action.devices.types.SWITCH",
"willReportState": false
}, {
"name": {
"name": "Good Night"
},
"traits": ["action.devices.traits.Scene"],
"type": "action.devices.types.SCENE",
"willReportState": false
}]
},
"requestId": "13733611394224717847"
}]