The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

WWW::Vimeo::Simple::Channel - Channel requests for the Vimeo Simple API

VERSION

version 0.08

SYNOPSIS

This module is a full object-oriented implementation of the Vimeo Simple API. The specifications are available at http://vimeo.com/api/docs/simple-api.

Channel requests implementation.

    use feature 'say';
    use WWW::Vimeo::Simple::Channel;

    my $channel_id = 'staffpicks';

    # create a new channel object
    my $channel = WWW::Vimeo::Simple::Channel -> new(name => $channel_id);

    # retrieve channel's information
    $channel -> info;

    # print channel's information
    say $channel -> name;
    say $channel -> description;
    say $channel -> url;

    # retrieve channel's videos
    my $videos = $channel -> videos;

    foreach my $video (@$videos) {
      say $video -> title;
      say $video -> description;
      say $video -> url;

METHODS

new( name => $channel_name, id => $id )

Create a WWW::Vimeo::Simple::Channel object using the given channel ID or name.

A Channel object has the following attributes:

  • id

    Channel ID

  • name

    Channel name

  • description

    Channel description

  • logo

    Channel logo (header)

  • url

    URL for the channel page

  • rss

    RSS feed for the channel's videos

  • created_on

    Date the channel was created

  • creator_id

    User ID of the channel creator

  • creator_display_name

    Name of the User who created the channel

  • creator_url

    The URL to the channel creator's profile

  • total_videos

    Total # of videos posted in the channel

  • total_subscribers

    Total # of users subscribed

info

Fetch channel info for the specified channel.

videos( $page )

Fetch videos in that channel, page optional (default 1). This method returns an array reference of WWW::Vimeo::Simple::Video objects.

INTERNAL SUBROUTINES

_make_url( $request )

Build a Vimeo Simple API url

AUTHOR

Alessandro Ghedini <alexbio@cpan.org>

LICENSE AND COPYRIGHT

Copyright 2011 Alessandro Ghedini.

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.