NAME

Net::GitHub::V2::Organizations - GitHub Organizations API

SYNOPSIS

use Net::GitHub::V2::Organizations;

my $organization = Net::GitHub::V2::Organizations->new(
    owner => 'fayland'
);

DESCRIPTION

http://develop.github.com/p/orgs.html

For those (authentication required) below, you must set login and token (in https://github.com/account)

my $user = Net::GitHub::V2::Organizations->new(
    owner => 'fayland',
    login => 'fayland', token => '54b5197d7f92f52abc5c7149b313cf51', # faked
);

METHODS

organizations
my $o = $organization->organizations('github');
my $o_arrayref = $organization->organizations; # my organizations
update
$organization->update('PerlChina', blog => 'http://planet.perlchina.org/', location => 'China');
user_organizations
my $o_arrayref = $organization->user_organizations('technoweenie');
repositories
my $repositories = $organization->repositories;
public_repositories
my $repositories = $organization->public_repositories('github');
public_members
my $users = $organization->public_members('github');
teams
my $teams = $organization->teams('github');
create_team
$organization->create_team('PerlChina',
    name => 'test',
    permission => 'admin',
    repo_names => ['PerlChina/sandbox']
);
update_team
$organization->update_team($team_id,
    name => 'test',
    permission => 'push',
    repo_names => ['PerlChina/sandbox']
);
delete_team
$organization->delete_team($team_id);
team_members
my $users = $organization->team_members($team_id);
add_team_member
$organization->add_team_member($team_id, $user);
remove_team_member
$organization->remove_team_member($team_id, $user);
team_repositories
my $team_repositories = $organization->team_repositories($team_id);
add_team_repositories
$organization->add_team_repositories($team_id, "$org/$respo");
remove_team_repositories
$organization->remove_team_repositories($team_id, "$org/$respo");

AUTHOR

Fayland Lam, <fayland at gmail.com>

COPYRIGHT & LICENSE

Copyright 2009 Fayland Lam, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.