Dump error & response codes for failed API requests

Change-Id: I729c0f7c9e20faa74ef8fdf3fe141cbbacb55d78
Merge "Dump error & response codes for failed API requests"