my $Msg;
my $resp = $ua->request($req);
if ($resp->is_success) {
my $Rep = JSON::XS->new->decode ($resp->decoded_content);
$Msg = $Rep->{data}->{error_message};
}
else {
print "", $resp->decoded_content, "n";
}
print "Error: $Msg\n";
####
{ "status": "fail", "data": { "error_message": "Cannot withdraw funds without Network Fee of 0.00000000 BTC. Maximum withdrawable balance is 0.00000000 BTC.", "available_balance": "0.00000000", "max_withdrawal_available": "0.00000000", "minimum_balance_needed": "0.00053590", "coin_fee": "0.00000000", "estimated_network_fee": "0.00000000", "estimated_min_custom_network_fee": "0.00000000", "estimated_max_custom_network_fee": "0.00000000" } }nError:
####
$Msg = $Rep->{data}->{error_message};