Improve API error messages
Improve HTTP error handling
Fix empty response when making queries