Net::G...:OAuth(3pm)
π Net::GitHub::V3::OAuth π
okay bestie, gather round, because we're looking at Net::GitHub::V3::OAuth β the GitHub OAuth API module, straight out of the User Contributed Perl Documentation, and she is serving. π
β¨ NAME β¨
Net::GitHub::V3::OAuth β it's the GitHub OAuth API, periodt. π
πΈ SYNOPSIS πΈ
the vibe check, in code form:
use Net::GitHub::V3;
my $gh = Net::GitHub::V3->new; # read L<Net::GitHub::V3> to set right authentication info
my $oauth = $gh->oauth;
so you spin up a Net::GitHub::V3 object, and btw read Net::GitHub::V3 to set the right authentication info, don't skip that part. then $gh->oauth hands you your very own OAuth object. iconic. β¨
π¦ DESCRIPTION π¦
so here's the tea:
- for the Web Application Flow, the suggestion is literally to use
Net::OAuth. π«Ά - for the Non-Web Application Flow, go read the
Net::GitHubFAQ. no cap.
π METHODS π
π OAuth
the docs live here, bestie: <http://developer.github.com/v3/oauth/>
π authorizations
my @authorizations = $oauth->authorizations();
boom, you get a whole list of authorizations back. slay.
π authorization
my $authorization = $oauth->authorization($authorization_id);
hand it an $authorization_id and it gives you back the one authorization. just the one. main character behavior. π
β create_authorization
β update_authorization
these two are besties so they're chilling together:
my $oauth = $oauth->create_authorization( {
scopes => ['public_repo'],
note => 'admin script',
} );
my $oauth = $oauth->update_authorization( $authorization_id, $new_authorization_data );
create it with some scopes and a note, or update an existing one by passing the $authorization_id plus your $new_authorization_data. obsessed. π₯
π§ delete
my $is_deleted = $oauth->delete_authorization($authorization_id);
give it the $authorization_id and it tells you whether it's deleted. bye bestie π
π AUTHOR & COPYRIGHT & LICENSE π
just go Refer Net::GitHub. iykyk. π
and that's the whole page, gorgeous β this was written against perl v5.36.0, dated 2022-10-08, and it's the Net::GitHub::V3::OAuth(3pm) manual page, so now you know exactly where it came from. mwah, go forth and OAuth responsibly. ππ
β¨
π¦ where this page comes from
- ubuntu noble: libnet-github-perl 1.05-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libnet-github-perl 1.05-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libnet-github-perl 1.05-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms