OAuth::Lite2::ParamMethods3pm
Store of builders/parsers for oauth 2.0 parameters
Usage
use OAuth::Lite2::ParamMethods qw(AUTH_HEADER FORM_BODY URI_QUERY);# client sidemy $builder = OAuth::Lite2::ParamMethods->get_request_builder( AUTH_HEADER );my $req = $builder->build_request(...);# server sidemy $parser = OAuth::Lite2::ParamMethods->get_param_parser( $plack_request )or $app->error("This is not OAuth 2.0 request");my ($token, $params) = $parser->parse( $plack_request );
Overview
Store of builders/parsers for OAuth 2.0 parameters
Constants
- AUTH_HEADER
- FORM_BODY
- URI_QUERY
Methods
get_param_parser( $plack_request )
Pass a Plack::Request object and proper parser for the request.
my $parser = OAuth::Lite2::ParamMethods->get_param_parser( $plack_request )or $app->error("This is not OAuth 2.0 request");my ($token, $params) = $parser->parse( $plack_request );
get_request_builder( $type )
Returns proper HTTP request builder for the passed $type.
my $builder = OAuth::Lite2::ParamMethods->get_request_builder( AUTH_HEADER );my $req = $builder->build_request(...);
Copyright and license
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.
Releases
2 releases since Debian 12 (Bookworm); the text changed 1 time.