8tracks Developers API
Richard Caetano
8tracks.com/arsy
caetano@gmail.com
8tracks
• Simple way for people to share and
discover music
• A mix is a short playlist contains at least 8
tracks
• Liste...
Stratus
• Stratus is an API management service
• Front end to API (auth, security,
monitoring, etc)
• Recently launched
API
• Search and Play mixes
• Simple XML or JSON
• Register for a key at developer.8tracks.com
• Documentation available
Authentication
• Use your Access Key and Secret Key from
Stratus
• HTTP Basic Authentication
require 'Base64'
creds = "{ac...
Search for mixes
http://api.8tracks.com/mixes.xml?q=miles+davis
<?xml version="1.0" encoding="UTF-8"?>
<response>
<logged-...
Mix Information
http://api.8tracks.com/mixes/47967.xml
<mix>
<description>Ten tracks including music by Charles Mingus, Ch...
Playback
• Get a Play Token
• Call Play mix
• Play the media (mp3)
• Call Next or Skip
Play Token
http://api.8tracks.com/sets/new.xml
<?xml version="1.0" encoding="UTF-8"?>
<response>
<logged-in type="boolean"...
Play Mix
http://api.8tracks.com/sets/570329908/play.xml?mix_id=47067
<track>
<djName>jaguarshark9</djName>
<is-fav type="b...
Next or Skip
http://api.8tracks.com/sets/570329908/next.xml?mix_id=47067
http://api.8tracks.com/sets/570329908/skip.xml?mi...
Ideas
• SoundManager Javascript
• Twitter Player
• Genre Player / Music Stations
• Firefox Player
iPhone Demo
Upcoming SlideShare
Loading in …5
×

8tracks API presentation

2,151 views

Published on

Presentation of the 8tracks playback API by Rich Caetano at Music Hack Day on Nov 21st, 2009.

1 Comment
1 Like
Statistics
Notes
No Downloads
Views
Total views
2,151
On SlideShare
0
From Embeds
0
Number of Embeds
143
Actions
Shares
0
Downloads
11
Comments
1
Likes
1
Embeds 0
No embeds

No notes for slide

8tracks API presentation

  1. 1. 8tracks Developers API Richard Caetano 8tracks.com/arsy caetano@gmail.com
  2. 2. 8tracks • Simple way for people to share and discover music • A mix is a short playlist contains at least 8 tracks • Listeners can stream the mix in a legal radio style manner
  3. 3. Stratus • Stratus is an API management service • Front end to API (auth, security, monitoring, etc) • Recently launched
  4. 4. API • Search and Play mixes • Simple XML or JSON • Register for a key at developer.8tracks.com • Documentation available
  5. 5. Authentication • Use your Access Key and Secret Key from Stratus • HTTP Basic Authentication require 'Base64' creds = "{accesskey}" + ':' + "{secretkey}" puts 'Authorization: Basic ' + Base64::encode64(creds)
  6. 6. Search for mixes http://api.8tracks.com/mixes.xml?q=miles+davis <?xml version="1.0" encoding="UTF-8"?> <response> <logged-in type="boolean">false</logged-in> <status>200 OK</status> <errors nil="true"></errors> <notices nil="true"></notices> <mixes type="array"> <mix> <description>Ten tracks including music by Charles Mingus, Charlie Parker and Dave Brubeck Quartet.</description> <first-published-at type="datetime">2009-09-17T21:36:33Z</first-published-at> <flagged-for-review type="boolean">false</flagged-for-review> <id type="integer">47967</id> <name>Consider me Miles Davis</name> ...
  7. 7. Mix Information http://api.8tracks.com/mixes/47967.xml <mix> <description>Ten tracks including music by Charles Mingus, Charlie Parker and Dave Brubeck Quartet.</description> <first-published-at type="datetime">2009-09-17T21:36:33Z</first-published-at> <flagged-for-review type="boolean">false</flagged-for-review> <id type="integer">47967</id> <name>Consider me Miles Davis</name> <plays-count type="integer">46</plays-count> <published type="boolean">true</published> <slug>consider-me-miles-davis</slug> <tag-list-cache>jazz</tag-list-cache> ...
  8. 8. Playback • Get a Play Token • Call Play mix • Play the media (mp3) • Call Next or Skip
  9. 9. Play Token http://api.8tracks.com/sets/new.xml <?xml version="1.0" encoding="UTF-8"?> <response> <logged-in type="boolean">false</logged-in> <status>200 OK</status> <play-token>570329908</play-token> <errors nil="true"></errors> <notices nil="true"></notices> </response>
  10. 10. Play Mix http://api.8tracks.com/sets/570329908/play.xml?mix_id=47067 <track> <djName>jaguarshark9</djName> <is-fav type="boolean">false</is-fav> <item>http://8tracks.s3.amazonaws.com/tf/000/003/020/01_So_What_54122904b931a7814659.mp3</item> <mixName>Consider me Miles Davis</mixName> <album>Kind of Blue</album> <year type="integer">1959</year> <duration type="integer">0</duration> <title>So What</title> <mixDescription>Ten tracks including music by Charles Mingus,...</mixDescription> <trackId type="integer">3020</trackId> <price></price> <referenceUrl>http://8tracks.com/jaguarshark9/consider-me-miles-davis</referenceUrl> <contributor>Miles Davis</contributor> <photo>http://cf3.8tracks.us/mix_covers/000/047/967/6983186934.sq56.jpg</photo> <allowSkip>true</allowSkip> </track>
  11. 11. Next or Skip http://api.8tracks.com/sets/570329908/next.xml?mix_id=47067 http://api.8tracks.com/sets/570329908/skip.xml?mix_id=47067
  12. 12. Ideas • SoundManager Javascript • Twitter Player • Genre Player / Music Stations • Firefox Player
  13. 13. iPhone Demo

×