Added OEmbed and Embeddable Player to twaud.io
26 MAY
I’ve just added OEmbed to twaud.io for fun and profit. I’d not really looked into it until Dustin and Russ pointed out and I really like the idea although it seems a bit under done at the moment (You can only have ‘image’, ‘video’ or ‘rich’ as media types. What about audio?). I’ve been meaning to implement an embeddable player for twaud.io for a long time so I decided to add them in.
The OEmbed endpoint is:
http://twaud.io/oembed.{format}
It supports JSON, XML and JSON-P (if you provide a callback parameter to a json request). For example:
http://twaud.io/oembed.json?url=http%3A%2F%2Ftwaud.io%2FYf&callback=myCallback
Returns this:
myCallback({
"height":"65",
"provider_url":"http://twaud.io",
"title":"Little mix of all the dubstep tunes I've been listening to lately: WRONG BEAT",
"type":"rich",
"html":"<iframe allowtransparency='true' frameborder='0' scrolling='no' src='http://twaud.io/embed/Yf' style='width: 395px; height: 65px; border: none;'></iframe>\n",
"audio_type":"audio/mpeg",
"audio_url":"http://twaud.io/audio/Yf",
"width":"395",
"author_name":"danwrong",
"version":"1.0",
"author_url":"http://twitter.com/danwrong",
"provider_name":"twaud.io"
});
The HTML property contains a snippet of HTML that renders the player:
All very beta at the moment but give it a try. Also, check the short dubstep mix I did a while back. Will post a longer one soon.
5 Comments (Closed)
It looks very cool, I like it very much, I’ll add OEmbed to my site now. Thanks for share.
Tomx at 03.06.10 / 15PM
hey hey hey… It’s very nice player! Many thanks for share this post.
Werbeagentur at 11.06.10 / 19PM
I like the embeded player, it’s very nice :D
Michael Internetagentur at 27.06.10 / 22PM
Thanks a lot for adding the OEmbed. I will keep exploring this site, maybe there are more good stuff here.
fox news at 16.07.10 / 22PM
I will add this player in my website. Thanks for share it – it looks so nice
Denison Hydraulics at 04.08.10 / 08AM
About This Article
- Posted on: 26.05.10 / 06AM
- Categories: JavaScript , Projects , Rails
- Tags: experiments, javascript, oembed, rails, twaudio
- Tweet