I wrote a AWS lambda function in Java that returns the following JSON:
{
"event": {
"header": {
"namespace": "Alexa.Discovery",
"name": "Discover.Response",
"messageId": "0559819e-49a3-4a8f-b614-6e8b3c186b71",
"payloadVersion": "3"
},
"payload": {
"endpoints": [
{
"endpointId": "shelly_pm_0",
"manufacturerName": "Shelly",
"description": "Shelly Schalter für Licht der Küchenzeile",
"friendlyName": "Licht der Küchenzeile",
"additionalAttributes": {
"manufacturer": "Shelly",
"model": "Shelly 1PM Mini Gen3",
"serialNumber": "34B7DA91DAEC",
"firmwareVersion": "1.0.0",
"softwareVersion": "1.0.0",
"customIdentifier": "shelly_pm_0"
},
"displayCategories": [
"LIGHT"
],
"cookie": {},
"capabilities": [
{
"type": "AlexaInterface",
"interface": "Alexa.PowerController",
"version": "3",
"properties": {
"supported": [
{
"name": "powerState"
}
],
"proactivelyReported": true,
"retrievable": true
}
},
{
"type": "AlexaInterface",
"interface": "Alexa.EndpointHealth",
"version": "3",
"properties": {
"supported": [
{
"name": "connectivity"
}
],
"proactivelyReported": true,
"retrievable": true
}
},
{
"type": "AlexaInterface",
"interface": "Alexa",
"version": "3"
}
]
}
]
}
}
}
I validated the json from alexa-smarthome repo and the JSON is valid. The cloudWatch logs show no errors and the last thing that is logged is the JSON string before it is returned, so I guess the function works.
Despite all that, when I link the account with the skill in the Alexa (which works as intended), the skill does not find any device.
Can anyone give me a hint on how to debug this or has had similar issues? Thanks for your help!