I want to trigger an Alexa skill from HA

Hi,

I would like to access a skill through the home assistant. I use alexa media player, everything is installed. I saw that there is a code available but I couldn’t understand how to activate it through HA.

- alias: Trigging a skill.
  initial_state: "on"
  trigger:
    platform: state
    entity_id: input_boolean.start_my_car
    to: "on"
  condition: []
  action:
    - service: media_player.play_media
      data:
        media_content_id: <Skill ID>
        media_content_type: skill
      target:
        entity_id: media_player.my_echo_dot

I entered my SKILL ID and I still couldn’t activate it.

II’m trying to activate the skill through node red

Could anyone support me?

As long as you can get Alexa to do the thing you want my saying, “Alexa, blah blah blah,” then you can use this:

service: media_player.play_media
data:
  media_content_id: Blah blah blah
  media_content_type: custom
target:
  entity_id: media_player.my_echo_dot

oohh now i see… i can simulate an call to my alexa… so, how i can catch an WAKE_WORD from alexa to trigger this?

This has the feeling of an XY problem in the making… Can you tell us what your actual goal is?

1 Like

Since there is no voice command, you don’t need a wake word.

1 Like

my idea is to speak the ALEXA command and node red calls my skill. So it will ask me what I want to do…

Just to make sure I understand… you want to give a verbal command to an Alexa device which triggers Node-RED, then Node-RED triggers a skill on the Alexa device?

yes… but I will simply say ALEXA

That’s not going to work… the wake word by itself won’t even update the last_called attribute of the device. The closest option I can think of would be at least a 1 word command after the wake word to trigger an Alexa routine which either triggers the skill directly or, if NR input is needed for the skill, acts on a helper that NR watches.

i see… thanks!

To whom? An echo device?
If you are telling Alexa to tell Node Red to trigger an Alexa Skill, that why don’t you just trigger the Alexa skill from Alexa?

If you want Alexa to treat a command from Home Assistant AS IF you spoke the command into an Echo device, then you make a service call. For example to get Alexa to tell the time on my Echo Dot:

service: media_player.play_media
data:
  media_content_id: "What time is it"
  media_content_type: custom
target:
  entity_id: media_player.my_echo_dot

To do this FROM Node-Red, you use the call_service node:
call-service

yeah! it’s perfect…

I didn’t know I could call my skill through routines. I got it here… thanks for the help