Official Alexa Smart Home Skill for openHAB 2

Tags: #<Tag:0x00007f1829a86a68> #<Tag:0x00007f1829a86928> #<Tag:0x00007f1829a86798>

(Dan Cunningham) #21

Unfortunately this is not supported using the current Home Skill API. If it does become possible I would love to add it.

(Dan Cunningham) #22

I take that back, I guess Amazon added that into the API while we were in review ( 3 months!!!), this should be trivial to introduce, i’ll open a bug.

(Paul Hansen) #23

This will make me very happy if it’s introduced. Being able to ask the house what temp various rooms are will make my wife happy when she’s worrying about the kids room temps.

The rest of this skill is fantastic to see and will certainly come in useful. Thanks for all the hard work.

(Dan Cunningham) #24

FYI this looks to be US only, so we can put it in, but German and possibly UK users may have to wait until Amazon adds this update to their regions.

(John Cocula) #25

Or at the openHAB Documentation site:

(Dan Cunningham) #26

Right, thats a better place to go. I have updated the original post. Thanks :slight_smile:

(Michael Aschenborn) #27

This works great for me. Thank you.

As many others I’m waiting for support for rollershutter-items.
If I tag them as “Lighting” it works a little bit with quirky sentenses… What is your best practice for the moment?

And only the Label of the item is recognized as triggerword for alexa.
Is it possible to add different variations for a single item?
(In our house one person calls it “Library”, the other “Music Room” and the third says “Piano Room” for the same light.)

And last but not least: Is it possible to redirect Strings via Alexa to openHAB?
I would like to say “start scene decoration” and get ‘decoration’ as new state to an item.

(Dan Cunningham) #28

Roller shutter support has been added, its just not deployed yet. I hope to push that out in the next few days after we get some usage on the code. This would work like a dimmer, so on/off, increase decrease, or set it to a percent like “Alexa set window to 80%”

No this is not possible with the Alexa Smart Home api, only off/on, +/-, % and temperature control.

OpenHAB Alexa Skill doesn't show any items
(SiHui) #29

As a workaround use a dimmer item and a rule:


Rollershutter your_shutter_item ...
Dimmer your_shutter_item_Alexa "shutter" ["Lighting"]


rule "Shutter Alexa" 

	Item your_shutter_item_Alexa received update

Switch representing a Rollershutter for Alexa
(Henning Treu) #30

Please vote for rollershutter/blinds support in Alexa Smart Home Skills:

(Jens) #31

Finally!!! Giving it a shot soon, since it is a missing link up until now. Even my wife asked me a couple days why this isn’t possible… here we go!

(Michael Aschenborn) #32

At the moment the smart home commands are only remote-control-commands.
"Switch on light x"
I would like so see another kind of voice-commands like
"Switch off light x at midnight"
"Close roof-window in 20 minutes"
I think, it would be ok to use the alexa internal timer functions.
Is this combination of Alexa-functions possible or are the apis separated from each other?

(Thomas) #33

Any hint why the command lasts so long from saying to doing? I say “Light Living Room Off” and about 1 minute later the light is off. But not always as it doesn’t seem to understand me all the time. With the hue emulation it worked better and about immediately.

(Tom) #34

And only the Label of the item is recognized as triggerword for alexa.
Is it possible to add different variations for a single item?
(In our house one person calls it “Library”, the other “Music Room” and the third says “Piano Room” for the same light.)

Yes, I’ve done this. Create an item for each name variant.

Switch  lamp1 "Music room lamp"  [ "Lighting" ]
Switch  lamp2 "Library lamp"  [ "Lighting" ]
Switch  lamp3 "Piano room lamp"  [ "Lighting" ]

Alexa will discover the three above.

and another item for the actual lamp:

Switch lamp "lamp" { .........}

Create a rule for each of the above so that when they change state, they turn the lamp item on and another rule to turn it off. Six rules in all. Here are the first two:

rule "lamp ON"

	Item  lamp1 changed from OFF to ON
  	 	sendCommand(lamp, ON)


    rule "lamp OFF"

    	Item  lamp1 changed from ON to OFF
      	 	sendCommand(lamp, OFF)

There’s probably a better way to do it though!

(Andrey) #35

Thanks, this works!

(Andrey) #36

I’m not sure I understand the way Alexa recognizes devices. I’ve created item groups in the Alexa app for different rooms and added the corresponding light switches to each group. My Alexa is set to German, so something like “Wohnzimmer Licht an” works, while “Living room lights on” doesn’t. Also, I added a group “Aquarium” which contains a switched outlet controlling the light. All my items are tagged as “Lighting”. Unfortunately, it doesn’t recognize any commands regarding the aquarium…

Do I need groups, or can it go by the item labels displayed in the Alexa app? It doesn’t seem to recognize any of the (English) labels on my items.

Does Alexa only work with one language at a time?

(Tom) #37

Does Alexa only work with one language at a time?

Yes, that would appear to be the case. You need to chose on or the other.

(Rob Pope) #38

Alexa isn’t finding my devices, which I’m sure is something I’m doing wrong.

I’ve installed the OpenHAB Cloud Service via PaperUI, signed up for and can see my items in and have tagged an item as such:

Switch          onkyoPower      "Power"         { channel="onkyo:onkyoUnsupported:1bb0a221-68a2-21b9-e2ab-210968b961d8:zone1#power" } ["Lighting"]

Where have I gone wrong? Do I need the Homekit binding too?

EDIT: I moved my tag to before the thing {GUID} and that seemed to work. I confirmed that I could see the tags in the myOpenHAB rest test and they were discovered.

My girlfriend gave me a funny look when I started getting giddy as it worked

(Andrew) #39

Try putting the tag before the binding information, that worked for me.

(Rob Pope) #40

That was exactly the issue :slight_smile: