2021-12-29 19:52:36.220 [ERROR] [internal.handler.ScriptActionHandler] - Script execution of rule with UID '08f372574e' failed: <eval>:1:26 Missing space after numeric literal
amazonechocontrol:echo:981f76546f:G090LF1180420BT1:textToSpeech.sendCommand("Hello World")
^ in <eval> at line number 1 at column number 26
I have also tried:
LoungeEcho_Speak.sendCommand("Hello World")
And that does this:
2021-12-29 19:52:49.943 [ERROR] [internal.handler.ScriptActionHandler] - Script execution of rule with UID '08f372574e' failed: ReferenceError: "LoungeEcho_Speak" is not defined in <eval> at line number 3
It feels like I am very close, but yet so far. Any pointers to where I am going wrong would be very welcome.
Thanks Jan. Some progress! The configuration type was set to JavaScript rather than vnd.openhab.ds1.rule.
Having fixed that, I am now seeing the rule taking longer to run, presumably as it is “conversing” with Alexa. I then see this in the log:
2021-12-29 20:31:55.310 [INFO ] [control.internal.WebSocketConnection] - Web Socket close 1005. Reason: null
I can also see this in the Event log:
2021-12-29 20:38:06.595 [INFO ] [openhab.event.ItemCommandEvent ] - Item 'LoungeEcho_Speak' received command Hello World
2021-12-29 20:38:06.595 [INFO ] [penhab.event.ItemStatePredictedEvent] - Item 'LoungeEcho_Speak' predicted to become Hello World
2021-12-29 20:38:06.595 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'LoungeEcho_Speak' changed from to Hello World
2021-12-29 20:38:14.463 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'LoungeEcho_Speak' changed from Hello World to
That repeats each time I execute the rule. I’m still not hearing anything from Alexa though - but that feels like it’s going to be an Alexa issue rather than OpenHAB.
Any more thoughts very welcome, but thank you for the pointer that’s got me this far.