if ($response->{channel}->{error}->{errorid} == "") { # ... my $resultid = $response->{channel}->{result}->{resultid};\ # ... };