added support for oauth2 responses in send_request