Music Store/Spec: Difference between revisions
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
You have a script that runs over your database periodically, OR whenever you add new tracks. this script exports your entire database as an xml file (the "Music Store.xml" file). The XML file can be in whatever format/style is convenient for you, but there are | You have a script that runs over your database periodically, OR whenever you add new tracks. this script exports your entire database as an xml or JSON file (the "Music Store.xml" file). The XML file can be in whatever format/style is convenient for you, but there are some formats that are particularly easy for me to accept: excel-export, JSON, and Apple's plist (used by kJams directly), contact me for more info. Plist files can easily be created even on windows, using Python. The file must be encoded in UTF-8, and it includes every bit of meta-data you have for each song eg:<br> | ||
<pre> | <pre> | ||
name | name | ||
Revision as of 19:38, 11 October 2012
You have a script that runs over your database periodically, OR whenever you add new tracks. this script exports your entire database as an xml or JSON file (the "Music Store.xml" file). The XML file can be in whatever format/style is convenient for you, but there are some formats that are particularly easy for me to accept: excel-export, JSON, and Apple's plist (used by kJams directly), contact me for more info. Plist files can easily be created even on windows, using Python. The file must be encoded in UTF-8, and it includes every bit of meta-data you have for each song eg:
name artist publisher if you have more than one (eg: sunfly, zoom, legends, chartbuster, etc) price (USD) (if purchaseable) if the song is streamable if the song is multiplex if you have a tiered service, what tier this song belongs in unique song ID (supplied by you, i use this to reference the song to you when requesting a purchase) a URL (or just the last component) for playing a sample of the song (hosted on your server, typically 15-30 seconds of the song in m4v format) genre duration media format type (MP3+G, mov, avi, mpg) url to icon (if any) song key (eg: "Key of Gm") if it's a duet date added to library any and all other meta data you have
Many meta-datum are optional, but the more you have, the more the user can search and filter on. Here's a list of the meta data that kJams supports. Note: it is trivial for me to add more meta data columns, if you have data that I do NOT support, just tell me and i'll add support for it.
For URLs, you can save space in the xml by only including the last component of the URL, and just tell me what the first part is, or put it in a header section.
it's important that each song have a "date added" field. users will sort by "date added" to see the new additions when they get a new copy of your library index.
it's important you have a web site where the buyer can see / hear preview samples of your songs (typically 30 seconds or so). Each song should be at a unique url. The previews do NOT play within kJams, but are played directly on your web site
The meta data xml file is published to a known URL at your site, optionally zipped for download speed. My software, periodically, checks this file for updates. if it is newer than last time (ie: the "Last-Modified" header HTTP header is changed) then i re-download, parse, and display the newly updated store list.
the user can then search and filter your song store from within kJams.
For stream subscription customers, they purchase a streaming subscription on your web store (or provide HTTP API for it and i'll put a GUI on it), and receive a "subscription ID". You will provide an API such that kJams can send the ID to your server and get back an XML that lists it's attributes such as: whether the ID is valid, what tier (if any), when it expires.
For bulk purchase code customers, they purchase bulk credits from you on your web site (or again you provide an HTTP API) and receive a "bulk purchase (credit) code". You will provide an API such that kJams can send the ID to your server and get back an XML that lists it's attributes such as: whether the ID is valid, how many credits are left. If you are totally awesome, you can use the same ID for bulk credit AND subscriptions.
when the user clicks the buy song button, i send an HTTPS request url to your server in one of 2 forms: 1) full credit card credentials of the user plus the song ID 2) "bulk purchase (credit) code" credentials plus song ID
when the user streams a song, i send an HTTPS request url to your server in this form: 3) "subscription ID" credentials plus song ID
for 1) i send, within the URL, the user's (buyer's) name, address, email, credit card, my affiliate ID, and song ID, and whatever else you'd require for 2 and 3) i send, within the URL, the code (credit or subscription), my affiliate ID, and song ID, and whatever else you'd require
upon successful processing of the credit card / bulk purchase (credit) code / subscription ID (which is handled by your site), the result URL sent back to me is the actual download link for the purchased song. (for streaming Audio+CDG files, i will encrypt the download as it lands on the hard drive, so it can not be extracted and used) For purchases, simultaneously you will send a receipt to the buyer (since you got their email address as part of the purchase request), this receipt would ALSO include the download URL, in case something went wrong. this URL may expire in a set number of days if you wish. Note I require the "Content-Length" http header field on this download. if this is not possible due to some technical reason, then you must include the size of the download within the meta data of the "Music Store.xml" file.
you price the songs and/or subscriptions however you wish, and for each song/subscription sold i would simply get an affiliate commission, eg: 15% to %25, we can discuss that. you may cut checks whenever it is fiscally reasonable to do so (eg: when i make more than say $100 or something, or just quarterly or bi-anually or whatever) or just use paypal to pay me (preferred).
i think you'd also want a download link for kJams on your website. users can use the free version to get to your music store. the ONLY limit on the free version is they can't make a playlist with more than 3 songs, can't export more than 10 songs to iPod, and can't rip from CD more than the first 2 songs on any disc. other than that it is fully functional. Note the "playlst size limit" does not affect the actual "Library" playlist, they can add as many songs as they want to that, nor does it affect the size of the music stores. i've got more than 20,000 kJams users that are using the free version (unregistered), i've purposely made it very useful and functional even when used in "Tryout" mode.
the Tricerasoft, KaraokeLocker and Chartbuster (streaming) stores are functioning now. go ahead and download kJams and give it a try, in your 1 click settings, enter 4111111111111111 as your credit card number, make up the rest except do use your real email address. and you'll be able to test the store (you'll always get a bon jovi song) so you can see just how dead simple it makes purchasing songs. it's impulse purchase at it's finest.
Summary
-> client asks for song list (Music Store.xml) eg:
http://karaoke.kjams.com/music_store/kJams.xml
<- server returns download URL link of xml or zipped xml file of song list including all meta data
later:
-> client requests preview song eg:
http://karaoke.kjams.com/music_store/previews/kJ00001.m4v
<- server responds by serving up the file / page with song preview on it
-> client sends purchase request (SSL) eg:
POST /cgi-bin/KaraokeDownloads/purchasexmlcc.asp?CCNUM=xxxxxxxxxxxxxxxx&EXPMM=01&EXPYYYY=2012&CVV=123&COUNTRY=US&FIRSTNAME=David%2520M.&LASTNAME=Cotter&STREET=20413%252012th%2520Place%2520West&CITY=Lynnwood&STATE=WA&ZIP=98036&EMAIL=me@davecotter.com&SONG_CODE=THM-C0707-04&RESELLER_CODE=KJ HTTP/1.1
or for a bulk purchase "gift card":
POST /cgi-bin/KaraokeDownloads/purchasexmlgift.asp?GIFTCODE=GP200809166545101VV720&FIRSTNAME=David&LASTNAME=Cotter&EMAIL=dave@kjams.com&SONG_CODE=MM6086-02&RESELLER_CODE=KJ HTTP/1.1
or for a stream request:
POST /cgi-bin/KaraokeDownloads/stream.asp?SUBSCRIPTION_CODE=479183471&FIRSTNAME=David&LASTNAME=Cotter&EMAIL=dave@kjams.com&SONG_CODE=MM6086-02&RESELLER_CODE=KJ HTTP/1.1
<- server performs financial transaction / gift code / customer code verification, and succeeds
<- server responds to client with new unique URL to download or stream song eg:
http://karaoke.kjams.com/music_store/songs/kJ00001.zip
<- if purchase: server emails user directly with receipt including (optionally expiring) download URL
-> if purchase: client downloads purchased song and installs into user's library
-> if stream: client downloads song and installs encrypted into temp folder (expiring), ready to play