Ajax error message - need to get more information

Ajax error message - need to get more information

There is an AJAX error on my page. Below is the code and error message. I need to extract more information about the error. How would I do that?

CODE:
  1. $(document).ajaxError( function (event, jqXHR, ajaxSettings, thrownError) {
  2.          alert('[event:' + event + '], [jqXHR:' + jqXHR + '], [ajaxSettings:' + ajaxSettings + '], [thrownError:' + thrownError + '])');


ERROR MESSAGE:
[event:[object Object]], [jqXHR:[object Object]], [ajaxSettings:[object Object]], [thrownError:Internal Server Error])