refindlyllc / rets

A thin RETS client
MIT License
69 stars 26 forks source link

RETS Error 20203: Invalid Query Type #228

Open naranqode opened 2 years ago

naranqode commented 2 years ago

Hi! I try to execute this code: search_results = rets_client.search(resource='Property', resource_class='RES', limit=1, dmql_query='(ListPrice=150000+)') for result in search_results: print(result)

While trying to execute this code I'm getting an error, here is an error rets.exceptions.RETSException: RETS Error 20203: Invalid Query Type

Any idea? Any help would be appreciated. Thanks

AlSaltAlBahri commented 1 year ago

I think it is an issue with the value you passed for resource_class. Instead of 'RES' try 'RESI'

ghost commented 1 year ago

same issue! any luck ? :(

naranqode commented 1 year ago

Same issue! any luck? :(

Yes, this is how it works for me: property = rets_client.search('Property', resource_class, search_filter={})

In the resource class you can use: CondoProperty or ResidentialProperty