OAuth:...ameter(3pm)

πŸ“¦
version 0.11 Β· 2 versions
, in debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ NAME ✨

okay so bestie, meet OAuth::Lite2::ParamMethod::URIQueryParameter β€” she's the builder and parser for the OAuth 2.0 uri-query type of parameter πŸ’… and yes she's from the User Contributed Perl Documentation (section 3pm), she's that girl πŸŽ€


🌸 SYNOPSIS 🌸

my $meth = OAuth::Lite2::ParamMethod::URIQueryParameter->new;

# server side
if ($meth->match( $plack_request )) {
    my ($token, $params) = $meth->parse( $plack_request );
}

# client side
my $http_req = $meth->request_builder(...);

πŸ¦‹ DESCRIPTION πŸ¦‹

no cap, she's literally the builder/parser for OAuth 2.0 uri-query type of parameter. that's the whole vibe. she builds, she parses, she slays 🫢


πŸ‘‘ METHODS πŸ‘‘

πŸ’– new

Constructor ✨ (she's born, she's iconic)

🌈 match( $plack_request )

returns true if the Plack::Request object you passed in is matched for the type of this method πŸ‘€

if ( $meth->match( $plack_request ) ) {
    ...
}

πŸŽ€ parse( $plack_request )

parses the Plack::Request, and hands you back the access token and the oauth parameters πŸ’

my ($token, $params) = $meth->parse( $plack_request );

⭐ build_request( %params )

builds an HTTP::Request object πŸ› οΈβœ¨

my $req = $meth->build_request(
    url          => $url,
    method       => $http_method,
    token        => $access_token,
    oauth_params => $oauth_params,
    params       => $params,
    content      => $content,
    headers      => $headers,
);

🧚 is_legacy( $plack_request )

returns true if the Plack::Request object you passed is based on draft version 10 πŸ•°οΈ (yes, a legacy era, we respect the elders)

if ( $meth->is_legacy( $plack_request ) ) {
    ...
}

πŸ’œ SEE ALSO πŸ’œ

  • OAuth::Lite2::ParamMethods
  • OAuth::Lite2::ParamMethod
  • OAuth::Lite2::ParamMethod::AuthHeader
  • OAuth::Lite2::ParamMethod::FormEncodedBody

(the whole friend group, go say hi 🫢)


🌟 AUTHOR 🌟

Lyo Kato, <lyo.kato@gmail.com> β€” the mastermind, the main character πŸ‘‘


Copyright (C) 2010 by Lyo Kato

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

fr fr, read the license, it's giving generous but it's still a license πŸ’€

okay that's the whole page bestie, mwah πŸ’‹ this was perl v5.36.0, dated 2023-07-01, and she ate, no crumbs left πŸŒΈπŸŽ€πŸ’–

πŸ“¦ where this page comes from