Ruby Weekly is a weekly newsletter covering the latest Ruby and Rails news.

Yahoo! Video Library for Ruby Released

By Peter Cooper / December 5, 2006

Walter Korman has released the first version of a Yahoo! Video library for Ruby. All it takes is a gem install yahoo-video and some simple code like this:

require 'rubygems'
require 'yahoo-video'

# your application id for use with the yahoo search services.  you can
# get one at http://api.search.yahoo.com/webservices/register_application.
APP_ID = YOUR_APP_ID_HERE

query = ARGV[0]
print "Running a video search for '#{query}'...\n"

client = YahooVideo::Client.new APP_ID
request = YahooVideo::SearchRequest.new :query => query
response = client.search request

As Walter points out, this gives Ruby the distinct honor of supporting the trifecta of video search services: Yahoo! Video, Google Video, and YouTube.

Comments

  1. Pingback: AdSense Money Maker

Other Posts to Enjoy

Twitter Mentions