Attempt to gracefully handle hard errors in API endpoint