A few days ago, Nikolaj Hald Nielsen emailed me to let me know that he'd managed to embedded the magnatune catalog into the Linux media player amaroK. A picture of his work is above.
He also asked if there was a way for amaroK to purchase and download the music entirely within amaroK, much like how iTunes music store works.
To enable applications to order music from Magnatune, I've made a REST/XML api that any application can call to order a downloadable album via credit card.
Any application or person is welcome to enable their application or web site to purchase music directly from Magnatune. Instructions are available at: http://magnatune.com/info/api#purchase
The current instructions for doing this are copied below (but consult the above URL, in case the spec changes slightly)
Embedded Music Purchasing
This url procedure allows your software to purchase music directly from magnatune, and receive all the download information back as an XML document. This is useful if you are embedding the Magnatune catalog inside your application, and would like to let people purchase music directly from within your application. If you so wish, your application can also download the purchased music on the person's behalf.
Point your web browser toward:
http://magnatune.com/buy/buy_dl_cc_xml
or if you can support https: in your application:
https://magnatune.com/buy/buy_dl_cc_xml
an instruction document in XML will appear, displaying this help:
The following fields are required:
Awesome. So awesome. John, you and your business rock.
Posted by: Ryan Sawhill | June 09, 2006 at 07:51 AM
Just to be clear, this isn't in Amarok and its kind of unclear whether and when it will put in. The screenshots certainly look awesome though. And I like the sound of the "partner id". :)
Isn't providing a unsecured method at all a bad idea?
Posted by: Ian Monroe | June 09, 2006 at 03:45 PM
Yes, that's right, it isn't embedded in the amarok that ships, but is an additional thing one can install and add.
-john
Posted by: John Buckman | June 09, 2006 at 11:57 PM
Some followon questions I've received:
how does the username/password to access the download location work? Is it simply http authentication, or is it more complicated?
It is http-auth (ie, simple web authentication).
I can't find any information on how it responds. Specifically, what xml tags, etc. does the page return when you've successfully purchased an album? What about if the credit card gets declined, or the information is wrong?
I do need to document that, but I think you'll find it extremely self-evident. Errors cause an tag and error description to come back, otherwise on success you get fairly obvious fields cleanly separated by <fieldname>XML descriptors</fieldname>.
Is there a URL I could eventually test it with (i.e. dummy album sku or something)?
In my reply email to you, if you ask for a partner ID, I'll give you a test credit card number you can use to test purchasing anything you like.
Posted by: John Buckman | June 19, 2006 at 01:52 PM