in reply to LWP::UserAgent error responce

From the Perl & LWP (O'Reilly) book:
Check the status of the response:
$response->is_success() $response->is_error() $response->is_redirect() $response->is_info() (probably not used much...)
And if it is not a success it has some nice functions to figure out what the problem is:
$response->code() (numeric code returned, error or not) $response->message(); (text status code) $response->status_line() (both numeric and string error codes)
Or as above you can get error_as_HTML and use that.