Perl Module WebService::Viddler on CPAN

| | | |

Back in March I outlined an idea for a Perl module for accessing the video service Viddler. As I noted, at the time, while there was plenty of support for the Viddler Application Programming Interface via PHP, the support for Perl was quite anemic.

To help rectify the situation, in my "copious" free time I've been working on an Perl module that wraps around Viddler's API. The goal being to provide a quick method for integrating Perl-based applications with Viddler.

Today, I'm happy to announce the first working release of my effort, WebService::Viddler, which can be found at CPAN (Comprehensive Perl Archive Network).

As I mentioned, at the heart of things, WebService::Viddler is an object-oriented encapsulation of the Viddler video platform providing a Perl specific focus for access via their public API, which itself is documented at:

Currently this module is, at best, beta quality code and only supports version 1 of the Viddler API. Moreover, while it handles most of the v1 API methods, it currently lacks support for the two commenting related methods, videos-comments-add and videos-comments-remove (a more complete To Do list can be found in the provided README file.

Of course the advantage of the module is that it makes including Viddler in a Perl-based application, dead simple:

#!/usr/bin/perl -T

use strict;
use warnings;

use WebService::Viddler;
use Data::Dumper;

# Create our object and establish a session
my $videos = new WebService::Viddler( 
                         apiKey => '123456ABCDEF',
                         username => $username,
                         password => $password,

# Get and print the API version is use
print "API Version: " .$videos->api_getInfo(). "\n";

# Upload a video providing required information such as the 
# title, tag and description
                         "A little video clip of...", 

# Get the details of the given video and
# use Data::Dumper help print out the values in the list results
print Dumper( $videos->videos_getDetailsByUrl( 
              "" ));

# Get a list of videos by the given tag and
# use Dumper to help print out the values in the list results
print Dumper( $videos->videos_getByTag( "moon" ));

Questions, bugs and code suggestions are of course welcomed!

Leave a comment

About the Author

Paul is a technologist and all around nice guy for technology oriented organizations and parties. Besides maintaining this blog and website you can follow Paul's particular pontifications on the Life Universe and Everything on Twitter.


Add to Google Reader or Homepage
Add to My AOL

Add to netvibes
Subscribe in Bloglines
Add to Technorati Favorites

Movable Type Pro