Open
Description
Shouldn't it be more obvious from the documentation that the $args
for oauth2.auth_url
and oauth2.get_token_p
are actually the same?
This is very important when one uses OpenID Connect and response_type=code
is not automatically added to the authorize_url
. Then the provider may give an error because response_type
is missing.
It is not obvious from the documentation that one can do
$args = {
authorize_query => {
response_type => 'code',
},
...
};
and then use
$promise = $c->oauth2->get_token_p($provider_name => $args)
->then(sub { my $provider_res = shift })
->catch(sub { my $err = shift; });
took me quite a while to figure that one out.
Alternatively, since get_token_p
expects the code
parameter in the response, perhaps response_type => 'code'
ought to be hard coded into _auth_url
.
Metadata
Metadata
Assignees
Labels
No labels