improved word validation exception handling in case API request fails