Very quick post because I am no longer in the mood of writing anything, but I just wanted to share this with the world :)
You can find everything you need in http://users.telenet.be/narcose/yt/ . Most interesting is probably the json response you can use to get more data out of the queries.
(Important, you will need to upload the html to a webserver because otherwise some callbacks from flash won't work as they would be redirected to local files and this is not allowed for some reason. Also, my code only seems to work in Safari/Firefox!)