Google music in HA

There:

How do I confirm I have a media player called media_player.chromecast ?

It can see my chromecast in GUI bt how can i confirm the name?

The username and password are correct because I can see the playlists i have…

ERROR (Thread-5) [custom_components.switch.gmusic] media_player.chromecast is not a valid media player.

My configs:

input_select:
  music:
    name: Thumbs up
    options:
     - " "   # Should be empty
    icon: mdi:music-note
  media_player:
    name: Media player
    options: # entity_ids of your media players
     - "media_player.chromecast"
    icon: mdi:music-note


switch:
 - platform: gmusic
   user: [email protected]
   password: pass
   device_id: ios0CD34363-3EB1-42AC-902C-0999F5439E75 # http://unofficial-google-music-api.readthedocs.io/en/latest/reference/mobileclient.html#gmusicapi.clients.Mobileclient.l$
   media_player: media_player # entity id of the input select used for mediaplayer
   playlist: music # entity id of the input select used for playlist

Look in your states page (<> icon in the dev panel) for the name of the media player.

When you find it change only the line

- "media_player.chromecast"

to match the entity_id.

Very strange, its named media_player.chromecast

and still:

ERROR (Thread-4) [custom_components.switch.gmusic] media_player.chromecast is not a valid media player.

This is a chromecast audio we’re taking about?

Not audio, original chromecast

And here endeth the lesson in what this custom component is for :joy::joy:

you’re joking right? LOL, you’ve got to be kidding me, RIGHT?

This wont work on the original? nor google home???

This component is for multiroom audio on networked cca’s. Works great, like Sonos at 10% of the price. But it’s no good if you don’t have the right kit.

Ok what about an Onkyo receiver with chromecast built in???

Dunno, you’ll have to try it and see :sunglasses:

FU**!!

NONE is working, a JBL with home assistant, a home assistant, a chromecast and an onkyo receiver with chromecast built in, NONE is working!!

I’m SURE there is something wrong, can’t be not working on all those chromecasts! that’s ridiculous!

Works fine here on 5 cca’s, that’s about as much as I can tell you unless anyone else can chime in.

can you paste here your code for adding the cca devices?

In my hardware package I just have

media_player:
  - platform: cast

… Which configures all the cca’s I have, including the virtual groups.

Then my music player package is here…

link removed

1 Like

In the <> page
where it has the entity name, next to it there is Attributes, what do you have there next to one of your cca?

I’ve just realised…
Change your input select code to this:

input_select:
  music:
    name: Thumbs up
    options:
     - " "   # Should be empty
    icon: mdi:music-note
  media_player:
    name: Media player
    options: # entity_ids of your media players
     - chromecast
    icon: mdi:music-note

Keeping everything else how I put it last time.

(note that the media player is now just chromecast, without media_player on the front as this gets added by the switch)

PROGRESS!!!

ERROR (Thread-12) [custom_components.switch.gmusic] Failed to get track (GetStreamUrl: 403 Client Error: Forbidden for url: https://mclients.googleapis.com/music/mplay?opt=hi&dv=0&tier=fr&pt=e&net=mob&sig=Nj7xqB6nmx5vZaULldsrQA6AVVU&hl=en_US&songid=ef357053-569f-3f6d-8e8f-cae7bf66afda&slt=1518834365894
(requests kwargs: {‘url’: ‘https://mclients.googleapis.com/music/mplay’, ‘allow_redirects’: False, ‘params’: {‘opt’: ‘hi’, ‘dv’: 0, ‘tier’: ‘fr’, ‘pt’: ‘e’, ‘net’: ‘mob’, ‘sig’: b’Nj7xqB6nmx5vZaULldsrQA6AVVU’, ‘hl’: ‘en_US’, ‘songid’: ‘ef357053-569f-3f6d-8e8f-cae7bf66afda’, ‘slt’: ‘1518834365894’}, ‘headers’: {‘Authorization’: ‘’, ‘X-Device-ID’: ‘ios0CD34363-3EB1-42AC-902C-0999F5439E75’}, ‘method’: ‘GET’})
(response was: ‘\n\nForbidden\n\n\n

Forbidden

\n

Error 403

\n\n\n’))

How did you get the device id?

First i inputted it wrong, then it gave me 3 others, i inputted each of them separately none is working…

any easy way to get them again?