This would be fantastic to have as an integration.
Very interested in this to connect Apple Music to Home Assistant and then play/group with Sonos speakers…
Won’t help anything until Home Assistant supports Apple Music.
It would be great if this can be integrated into HA.
I REALLY hope this feature will be integrated soon.
I ended up getting a Sonos speaker which supports Apple Music, then if you add playlists etc to your favourites in the Sonos app they then become available in HA. Works perfect for me!
If you just want to launch a specific Playlist, you can use the following workaround:
- create a Boolean switch in HA
- make the switch turn auto-off after a few seconds
- expose Boolean switch to HomeKit
- create Automation in HomeKit - if switch is turned on, launch playlist X in Apple Music on Speaker Y
I’ve done this for several radio stations. But there isn’t a solution yet to launch specific songs on a dashboard. That’s what I want Apple Music for. And I want to keep my HomePods.
This
Even when you use an iPad as a dashboard, that’s not a proper solution, because the iPad should be in Guided Access mode. And then you can’t switch to the Music app (and back) anymore.
Second this. There is literally NOTHING to connect apple music to HA, so an official integration, or any integration really is more then welcome.
What’s the actual ask here?
Do you want to be able to view your AM library in HA? Play music in HA from AM? Play music from AM to another non-Apple device via HA?
My ask would be to view my AM libary in HA and play it (through Airplay?) to my Sonos speakers, just like I can play Spotify or Sonos playlists through my speakers.
That makes sense to me.
We won’t be able to stream a M3U8 directly to the Sonos as the media stream data itself is protected by WideVine DRM.
Can you play direct to your Sonos today by calling the service Media player: Play media
and specifying the Content ID (maybe an AM URL)?
This doesn’t work for me with a HomePod and I cannot figure it out. If we can work this out, I think it’s feasible.
So I grabbed a URL from AM and used this method to push to a SONOS speaker and it worked. Homepods aren’t exactly open so I appreciate this may not work for those speakers.
Hey, I just tested this and does indeed work. But then I went to Sonos app and removed my Apple Music account from there and tried again calling the service in Home Assistant with the exact same media that worked before, resulting in an 800 error.
Added the Apple Music account back into the Sonos app, pressed the ‘call service’ button again and worked again.
We still need to mess with Sonos app for authentication, but having AM integrated into HA would remove the need from having to do the extra job of adding to Sonos the playlists from AM.
I’m not sure about other plaforms different from Sonos, tho.
Is an interesting project that can access apple music, spotify, plex, youtube and more. I’m not a programmer, but maybe there is a way to incorporate into homeassistant?
Maybe there’s also something goin’ on @MusicAisstant → Add Apple Music Support · music-assistant · Discussion #389 · GitHub
Thanks, I’ll add a note in the MusicAssistant thread you linked.
not quite an integration but Apple Music is available now as a source for music in the Music Assistant Beta 2.1.0b1