Echo Devices (Alexa) as Media Player - Testers Needed

does this means i have alexapy missing? Is that the reason routines are not working? And why does my notify works? Are those two different things? or do they both use alexapy?

logger: is another section

logger:
  default: error
  logs:
    alexapy: debug
    custom_components.alexa_media: debug  # optional

ok , now it accepts.
Thx woody4165
Now i test my routine and then i can find these logs…where…?

In /config/homeassistant.log or click on the circled i in the web interface

dining_light:
  sequence:
    - service: media_player.play_media
      data:
        entity_id: media_player.myechodot
        media_content_id: "light"
        media_content_type: "routine"

this is my routine btw ,i have this routine enabled in alexa app and i can start it true voice command directly on alexa

is it written exactly as in Alexa app (maybe also capital letter counts) ?

in the “i” section it doesnt show anything , in the file it shows :

2019-03-24 11:14:09 DEBUG (SyncWorker_0) [custom_components.alexa_media.media_player] GinosEchoDot: Last_called check: self: G************TXF reported: G************TXF
2019-03-24 11:14:20 DEBUG (SyncWorker_10) [alexapy.alexaapi] No routine found for light 

so i guessthere is something wrong to find my routines , becausein the alexa app it exists…
should i do something extra to be able to find my routines?
i read something about the sequence and a way to find them inthe wiki , should i do this or not to find my routines ?

Try to use the Services in Developer Tools (on the bottom left of the screen) and call there the media_player.play_media using the parameters you’re using in the script or automation

{
  "entity_id": "media_player.ginosechodot",
  "media_content_id": "light",
  "media_content_type": "routine"
}

gives the same:

2019-03-24 11:43:31 DEBUG (SyncWorker_3) [alexapy.alexaapi] No routine found for light

{
  "entity_id": "media_player.ginosechodot",
  "media_content_id": "tv off",
  "media_content_type": "routine"
}

i simply tried this routine i had set up a long time ago , using my broadlink to switch my tv off , and this works , could it be it takes some time before new routines get discovered by the alexapy?
So it is working , just not with the new routines i created…

So ,
here is an update:
as i use the livolo zigbee controlled switches for my lights they were set up in alexa as switches ,
-i changed them to lights , no succes controlling them true routines…
-i created a new routine with end action to let alexa say a phrase…this works true routines
-i created added the light to the routine with the phrase…and she controls the light and says the phrase…
-deleted the phrase from the routine…and it works to control the light withoutthe phrase…
strange…but it works… i can controlmy lights true routines…
Now i want to create switches in home assistant to control these scripts… i guess i will be back with more questions… thx everyone for the help!!! REALY apreciate it!!!

edit:
i was able to set it up for one switch… then it seems that routines are not found again… no matter all the above i tried before… my one switch on and off scripts are still working , but all the other ones i created dont… is the amount of routines you can import restricted? or why itconnects one routine and another it doesnt?

Has anybody got this working as a media player for Pandora? I have been trying media_player.play_media in the service dev tool.
Is the media_content_type “PANDORA” ?

Please DM me the results from going to this url (fix the domain as appropriate). Please clean out the serial numbers/user ids (e.g., customerId and deviceSerialNumber) but do not modify the JSON structure. That is the file we are checking to identify routines. You may want to verify you’re seeing all your routines in there (search for utterance and consider using an online json parser to review).

Ok , i will try to do that one of these upcoming days… As its quite a list and a lot of clean up will be needed… I managed to get my second light working also by editing a routine that was in the list and wich i didnt use a lot… So its strange that not all routines get showen… I will look to send you the stuff next week… How do i dm them to you?

Hello, I can not get my alexa media player to work again. I had it working for the longest time until i upgraded from 0.74 to 0.85

I had HA in a Python venv running 0.74 and then i reinstalled it on a HyperV VM as 0.85.1, and now i am on 0.90.1 and trying to get my alexa working again.

alexa.py version 0.9.5

media_player:
  - platform: alexa
    email: !secret amazon_login
    password: !secret amazon_password
    url: amazon.com    #also tried this WITH quotes

For HA > 0.88 you need to upgrade to v.1.2.3…

https://github.com/keatontaylor/alexa_media_player/wiki

Hi,
I feel like a dweeb.
I can’t seem to get this to show up when I add this to the add-on store…


Help!

Thanks.

Its not an “add-on”. Its a custom component. In that link you posted, it says to click the wiki for documentation. Once in the wiki, see the menu on the right which includes configuration.

1 Like

Yes. Sorry about that. I tried to delete my post right after figuring that out.

Now I’m not able to reboot hassio with it added. I added the files into the appropriate directory like it said and added the below to my configuration.yaml file:


#amazon
alexa_media:
accounts:
- email: emailaddress
password: password
url: www.amazon.ca


Getting this in the log:

2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.components.hassio.handler] /homeassistant/check return code 500.
2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.components.hassio] Error on Hass.io API:
2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.core] Error executing service <ServiceCall homeassistant.restart (c:cdc16ea84eb64ed9b4a064d31df20415)>
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/homeassistant/core.py”, line 1142, in _safe_execute await self._execute_service(handler, service_call)
File “/usr/local/lib/python3.7/site-packages/homeassistant/core.py”, line 1155, in _execute_service await handler.func(service_call)
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/hassio/init.py”, line 262, in async_handle_core_service error = await async_check_config(hass)
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/hassio/init.py”, line 142, in async_check_config raise HomeAssistantError() from None homeassistant.exceptions.HomeAssistantError
2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.components.hassio.handler] /homeassistant/check return code 500.
2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.components.hassio] Error on Hass.io API:
2019-03-25 21:38:20 ERROR (MainThread) [homeassistant.core] Error executing service <ServiceCall homeassistant.restart (c:a680ca8e59a34ab3b10c6e75b9c74cba)>
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/homeassistant/core.py”, line 1142, in _safe_execute await self._execute_service(handler, service_call)
File “/usr/local/lib/python3.7/site-packages/homeassistant/core.py”, line 1155, in _execute_service await handler.func(service_call)
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/hassio/init.py”, line 262, in async_handle_core_service error = await async_check_config(hass)
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/hassio/init.py”, line 142, in async_check_config raise HomeAssistantError() from None
homeassistant.exceptions.HomeAssistantError
2019-03-25 21:38:34 ERROR (MainThread) [homeassistant.components.hassio] Testing configuration at /config
ERROR:homeassistant.scripts.check_config:BURB
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/homeassistant/scripts/check_config.py”, line 204, in check res[‘components’] = check_ha_config_file(hass)
File “/usr/local/lib/python3.7/site-packages/homeassistant/scripts/check_config.py”, line 332, in check_ha_config_file component = loader.get_component(hass, domain)
File “/usr/local/lib/python3.7/site-packages/homeassistant/loader.py”, line 131, in get_component comp = _load_file(hass, comp_or_platform, LOOKUP_PATHS)
File “/usr/local/lib/python3.7/site-packages/homeassistant/loader.py”, line 166, in _load_file module = importlib.import_module(path)
File “/usr/local/lib/python3.7/importlib/init.py”, line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level)
File “<frozen importlib._bootstrap>”, line 1006, in _gcd_import
File “<frozen importlib._bootstrap>”, line 983, in _find_and_load File “<frozen importlib._bootstrap>”, line 967, in _find_and_load_unlocked File “<frozen importlib._bootstrap>”, line 677, in _load_unlocked
File “<frozen importlib._bootstrap_external>”, line 724, in exec_module
File “<frozen importlib._bootstrap_external>”, line 860, in get_code
File “<frozen importlib._bootstrap_external>”, line 791, in source_to_code
File “<frozen importlib._bootstrap>”, line 219, in _call_with_frames_removed
File “/config/custom_components/alexa_media/init.py”, line 7 <!DOCTYPE html>
^
SyntaxError: invalid syntax
Fatal error while loading config: invalid syntax (init.py, line 7)
Failed config General Errors: - invalid syntax (init.py, line 7)
Successful config (partial)

ewww.

Sorry, how to copy/paste from log?