How to use the Alexa announcement command?

I would like to use the Alexa channel command announcement. The docu sais

See in the tutorial section to learn how it’s possible to set the title and turn off the sound.

I would like to send a command in order that Alexa answers with an random announcement for “Good Morning” for example.

How can I do that?

Thank you

You refer to Amazon Echo Control - Bindings | openHAB
but I think what you would like to do is to run the “Good Morning” routine. Just send “Good Morning” to the item that is linked to the startRoutine channel. This then will be have like you would have said “Alexa, Good Morning”.

Not exactly but let me be more clear. On the Alexa app there is under “Action” an entry in “Alexa says” → “Phrase” → “Good Morning” → “Random Answer”

How can I send from OH to Alexa “Good Morning” but WITH a random answer?

On your phone / in the app you define the / a routine.
In this case it is called “Good Morning” resp. you define any other phrase.
Then in the app you define the action that alexa will execute. In this case it is “Random Answer”.

The item is defined as

String Echo_Plus_StartRoutine          "Start Routine"                        (Alexa_Living_Room) {channel="amazonechocontrol:echo:account1:EchoPlus:startRoutine"}

On OH you need to start the routine by sending “Good Morning”
E.g.

Echo_Plus_TTS_StartRoutine.sendCommand( 'Good Morning')

That is correct but in my case I would like to send the “Random Answer” from OH directly WITHOUT creating a routine in the app first.

Is this also possible?

Write a rule (in OH) triggered by the “lastVoiceCommand” channel and send your answer via “textToSpeech” command of the Echo Control Binding from this rule.

Be aware so the “lastVoiceCommand” tends to break due to changes on amazon side and you might need an updated Echo Control Binding from GitHub - smarthomej/addons: SmartHome/J addons for openHAB which is ususally updated before the official AddOn.

Indeed this is a very good idea, thank you!