The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Pikeo::API::User - Abstraction of a pikeo user/person

SYNOPSIS

    use Pikeo::API;
    use Pikeo::API::User;

    # create an API object to maintain you session
    # trough out the diferent calls
    my $api = Pikeo::API->new({api_secret=>'asd', api_key=>'asdas'});
    
    # Get a user by id...
    my $user1 = Pikeo::API::User->new({ api => $api, id=>1 });

    # .. or get a user by username
    my $user2 = Pikeo::API::User->new({ api => $api, username=>'foo' });

    #get the public photos
    my $photos = $user2->getPublicPhotos();

FUNCTIONS

CONSTRUCTORS

new( \%args )

Returns a Pikeo::API::User object.

Required args are:

  • api

    Pikeo::API object

  • username or id

    Id or username of the user.

INSTANCE METHODS

getPublicPhotos(\%args)

Return a list of Pikeo::API::Photo owned by the user and marked as public.

getContactsPublicPhotos(\%args)

Return a list of Pikeo::API::Photo owned by contacts of the user and marked as public

getUserPhotos(\%args)

Return a list of Pikeo::API::Photo containing all the photos of the user.

getAlbumsList()

Return a list of Pikeo::API::Album owned by the user

username()

Returns the user username

profile_url()

Returns the user profile url

avatar_url()

Returns the user avatar url

location()

Returns the user location

id()

Returns the user id