no strict 'refs';
*{"main::getlinkstats"} = *{"WWW::Shorten::Googl::getlinkstats"};
}
use JSON::Any;
use Carp;
use constant API_URL => 'https://www.googleapis.com/urlshortener/v1/url';
use co
my $url = shift or croak 'No URL passed to makeashorterlink';
my $json = JSON::Any->new;
my $content = $json->objToJson( { longUrl => $url, } );
my $res = _request( 'post', API_URL, Con
on/json';
my $resp = $ua->$method( $url, %headers, @args );
die "Request failed - " . $resp->status_line unless $resp->is_success;
my $json = JSON::Any->new;
my $obj = $json->jsonTo