Skip to content
This repository has been archived by the owner on Jan 22, 2022. It is now read-only.

Support creating instant mixes #45

Open
ghost opened this issue Sep 2, 2012 · 9 comments
Open

Support creating instant mixes #45

ghost opened this issue Sep 2, 2012 · 9 comments

Comments

@ghost
Copy link

ghost commented Sep 2, 2012

Hi,
Is it possible to add functionality for getting the Instant Mixes that Google throws together? I don't mind writing it myself, but I was just wondering if you knew the particular call of the top of your head or something.

Charles

@simon-weber
Copy link
Owner

Off the top of my head, I think it's just a single call. I don't remember what exactly, though. Pull requests are always welcome!

@danielmj
Copy link

I too would love this call if you can find it! This is the one piece that im missing.

@simon-weber
Copy link
Owner

Sure thing; I'll look into it.

@simon-weber
Copy link
Owner

Sorry for the delay!

The call is made to services/getmixentries and looks like:

[["<newstyle session id>",1],[[["<song id>",null,1,[],[]]]]]

the response is totally gross, and seems to include song dictionary information, eg:

[[0]
,[[[["<requested song id>",["","",,,,,,,,,,,,0,,,,,,,,1,0,-1,0,0]
,1,[]
,[]
]
,[["55e3f0ab-5bac-33c4-8b97-e249cc34f68c","Empty","//lh4.googleusercontent.com/K010mLNMkp5O_nPFYFlOfZ4vj5qTbK-WgpqVdxchGM58xDrMNl2KV0MMZhzzVA","Anathema","Alternative 4","","empty","anathema","alternative 4","","","Metal","metal",178984,3,14,1,1,1998,0,,,0,0,1361551889038581,1361999919506480,,,"Tzdwbkhcuvxx4kiiwrpsbcftctm",6,"",,,"A2bajq3munahcdk3imjx3ozow64",256,1361551927496000]
,["00816850-42dc-32ca-b1d2-e628f246edb6","Destiny","//lh4.googleusercontent.com/K010mLNMkp5O_nPFYFlOfZ4vj5qTbK-WgpqVdxchGM58xDrMNl2KV0MMZhzzVA","Anathema","Alternative 4","","destiny","anathema","alternative 4","","","Metal","metal",131950,10,14,1,1,1998,0,,,0,0,1361550760940101,1361678466297239,,,"Tvnrtx54rw62ttivl6wwchg2p2y",6,"",,,"A2bajq3munahcdk3imjx3ozow64",321,1361550760939000]
,["45f4551a-151d-311d-8ef8-4a118c7c26ec","Shroud of False","//lh3.googleusercontent.com/ybp5z7Ij3QK4keTXpT-wqeV17yBdCZHDFwhuP-zGTERyxamga3Z911qcFzsp","Anathema","Alternative 4","Anathema","shroud of false","anathema","alternative 4","anathema","","Metal","metal",96803,1,14,1,1,1998,0,,,0,0,1361574609659231,1361678822612695,,,"Tiv7yqfjda6at7gwn3rvd2rxzpy",2,"",,,"A2bajq3munahcdk3imjx3ozow64",256,1361574665145000]
]
]
]
]
]

I've seen a lot of requests/responses that look like this recently. It seems like a trend away from user-readable json objects and towards structs; this could makes things a lot more annoying for us.

I'll probably expose this with something like api.get_related_songs(song_id) and return a list of song ids.

@danielmj
Copy link

danielmj commented Mar 9, 2013

Thanks Simon! Your awesome! I am anxious to see the implementation! Confused however, what is "newstyle session id"? Will this be included in the doumentation somewhere?

@simon-weber
Copy link
Owner

It pops up in most of the calls now, but doesn't seem to be required (yet).

I haven't figured out how it's generated, but it doesn't seem to come from the server.

@askvictor
Copy link

Correct me if I'm wrong, but a quick test seemed to show that create_station creates an instant mix based on the seed track/album/artist. I just tried it without and AA subscription and it returned songs only in my library.

@simon-weber
Copy link
Owner

Oh, cool; thanks for bringing it to my attention.

As a heads up, I don't have a lot of time this week, but I can probably dig into this over the weekend.

@simon-weber
Copy link
Owner

Whew, this is an old issue! This will be handled by #263 when it lands.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants