hanneshapke/pyzillow

get updated property details error

rohitjawle opened this issue · 8 comments

I am able to get the zillow ID, but when I try to get property information using get_updated_property_details, I am getting this error.

raise ZillowError(int(response.findall('message/code')[0].text))
pyzillow.pyzillowerrors.ZillowError: <exception str() failed>

+1

Gents,

I am getting the same error. Looks like it may be a permission issue:

<?xml version="1.0" encoding="utf-8"?><UpdatedPropertyDetails:updatedPropertyDetails xmlns:UpdatedPropertyDetails="http://www.zillow.com/static/xsd/UpdatedPropertyDetails.xsd" xsi:schemaLocation="http://www.zillow.com/static/xsd/UpdatedPropertyDetails.xsd https://www.zillowstatic.com/vstatic/18f7df5/static/xsd/UpdatedPropertyDetails.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><request><zpid>XXXXXXXXX</zpid></request> <message> **<text>Error: protected data is unavailable through API</text>** <code>501</code></message></UpdatedPropertyDetails:updatedPropertyDetails><!-- H:045 T:68ms S:115 R:Thu Oct 04 02:58:10 PDT 2018 B:5.0.56507-master.b1a7600~delivery_ready.3a146c7 -->

Checking my account permissions. Will let you know if I figure it out.

+1
did anyone figure this out?

I am having this same issue:

from pyzillow.pyzillow import ZillowWrapper, GetDeepSearchResults, GetUpdatedPropertyDetails

#My Address Details
address = '155 Demar Blvd, Canonsburg, PA'
zipcode = '15317'

#My API Key Details
zillow_data = ZillowWrapper('X1-**************_*****')

#Getting the Zillow ID for my property (runs correctly, returns correct ID)
deep_search_response = zillow_data.get_deep_search_results(address,zipcode)
result = GetDeepSearchResults(deep_search_response)
print(result.zillow_id)
print(type(result.zillow_id)) #Checked the type to verify "result.zillow" was same type as "zillow_id" below

Zillow_id = result.zillow_id
print(Zillow_id)
print(type(Zillow_id))

#Section does not run --> returns a UnicodeEncodeError...
updated_property_details_response = zillow_data.get_updated_property_details(Zillow_id)
resultPropDetail = GetUpdatedPropertyDetails(updated_property_details_response)
print(resultPropDetail.property_size)

This results in the following output (note that the Zillow ID is being returned and I'm getting verification that this isn't a type error. Also note, the ID being returned is the correct one for the property I'm pining):

/System/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7 "/Users/jeremypepper/Desktop/Pepperidge Code/SqFtGet.py"
49785503
<type 'str'>
49785503
<type 'str'>
Traceback (most recent call last):
  File "/Users/jeremypepper/Desktop/Pepperidge Code/SqFtGet.py", line 21, in <module>
    updated_property_details_response = zillow_data.get_updated_property_details(Zillow_id)
  File "/Library/Python/2.7/site-packages/pyzillow/pyzillow.py", line 43, in get_updated_property_details
    return self.get_data(url, params)
  File "/Library/Python/2.7/site-packages/pyzillow/pyzillow.py", line 72, in get_data
    response = ElementTree.fromstring(request.text)
  File "<string>", line 124, in XML
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2026' in position 3355: ordinal not in range(128)

Process finished with exit code 1

if someone finds a fix to this please let me know in detail. would be a big help

i was able to solve this problem by using this exact link https://www.zillow.com/webservice/GetUpdatedPropertyDetails.htm

you need to go into the pyzillow.py file itself and change the url in the (def get_updated_property_details) function

I changed the URL as recommended but still receive the error.

Thanks!

send your code for the pyzillow.py file and where you are running it (i.e. ur testing file)