Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to link to the iTunes store from iPhone app?

I am trying to set up an application in which users will be able to stream music. When the user is streaming a MP3, I'd like to set up a link to the iTunes store to buy the MP3.

How can I do that? I feel like there should be some simple way of doing so using the song title and artist name, am I mistaking?

Thanks

like image 528
marcgg Avatar asked May 21 '09 15:05

marcgg


3 Answers

You can experiment with the iTMS Link Maker that Apple provides and see how the links are formed. In addition, here is the iTMS Link Maker FAQ.

See this blog post about how to query the iTMS Link Maker automatically. Basically, you can query the iTMS Link Maker and get an XML document back that your application can process.

like image 183
Naaff Avatar answered Sep 21 '22 17:09

Naaff


The iTunes Store Web Service Search API (pdf), although old and incomplete, documents how to search for content in the iTunes store and returns a JSON string with results.

The iTunes Store Web Service Search API allows you to place search fields in your website to search for content within the iTunes Store. You can search for a variety of iTunes Store content; including movies, podcasts, music, music videos, audiobooks, and TV shows. You can also call an ID-based lookup request to create mappings between your content library and the iTunes Store content library.

Queries are sent to base url:

http://ax.phobos.apple.com.edgesuite.net/WebObjects/MZStoreServices.woa/wa/wsSearch?parameterkeyvalue

Where parameterkeyvalue can be one or more parameter key and value pairs indicating the details of your query.

like image 32
prendio2 Avatar answered Sep 19 '22 17:09

prendio2


Ok, I had this same problem and the answers here did not give me enough info. So I asked this question again with different wording, and continued to search for an answer. I ended up answering my own question in the other question, and have posted the code to do this over there.

You can find the question at:

Opening iTunes Store to specific song

It contains all the code you will need to open the iTunes Store to the specific song specified by song name and song artist.

I hope this helps someone.

like image 28
MajorHavoc Avatar answered Sep 18 '22 17:09

MajorHavoc