Hello Smart Monks,I am getting 400 bad request in my code.
https://dev.preview.com/oauth2/default/v1/authorize?client_id=xxxxxxxx +xxxxxxxxxxxxx&response_type=code&scope=openid&redirect_uri=http%3A%2F +%2Ftestchandan.com%3A5001&state=1234&nonce=UBGW
I was trying to write below code for constructing above query but getting Bad request but the same query working fine in the browser
I will need to develop the above query. is that possible for your to tell me where i am doing wrong here in my below code?
use strict; #use warning; use JSON; use JSON::WebToken; use LWP::UserAgent; use HTML::Entities; use LWP::Authen::OAuth2; use HTTP::Request; use Data::Dumper; use HTTP::Headers; my $ua = LWP::UserAgent->new(); $ua->proxy([ 'http' ], 'http://proxy.myorg.com:8080'); my $response1 = $ua->get( 'https://dev.preview.com/oauth2/default/v1/authorize?', client_id => '******************', response_type => 'code', scope => 'openid', redirect_uri => 'http%3A%2F%2Ftestchandan.com%3A5001', state => '1234', nonce => 'UBGW' ); print Dumper ($ua); unless($response1->is_success()) { die($response1->code, "\n", $response1->content, "\n"); }
In reply to Need to resolve the API call query by chandantul
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |