@SuppressWarnings("unchecked")
    @Override
    public Weather getWeatherData(int zip) throws WeatherServiceException {
        HttpClient httpClient = new DefaultHttpClient();
        try {
            HttpGet httpGet = new HttpGet(new URI(format(urlFormat, apiKey, zip)));
            HttpResponse response = httpClient.execute(httpGet);
            Map<String, Object> respData = new Gson().fromJson(EntityUtils.toString(response.getEntity()), HashMap.class);

            if (((Map) respData.get("response")).containsKey(ERROR_KEY)) {
                if ("querynotfound".equalsIgnoreCase(get(respData, "response", ERROR_KEY, "type").toString())) {
                    throw new WeatherServiceException(ZIP_NOT_FOUND);
                } else throw new WeatherServiceException("Generic Exception: " + respData.get(ERROR_KEY).toString());
            }

            int returnedZip = parseInt(get(respData, CURRENT_OBSERVATION, DISPLAY_LOCATION, "zip").toString());
            String city = get(respData, CURRENT_OBSERVATION, DISPLAY_LOCATION, "city");
            String state = get(respData, CURRENT_OBSERVATION, DISPLAY_LOCATION, "state_name");
            double tempF = get(respData, CURRENT_OBSERVATION, "temp_f");
            return new Weather(returnedZip, city, state, tempF);
        } catch (Exception e) {
            throw new WeatherServiceException(e.getMessage(), e);
        }
    }