Ask Your Question

Query By Status To Obtain List of On-Market Listing In Order to Remove Off-Market Listings. [closed]

asked 2022-12-07 13:26:18 -0600

updated 2022-12-07 16:25:42 -0600

As this feed is only providing on-market + sold status listings, we will need to regularly pull down lists of on-market listings in order to clean the off-market listings out of our on-market data. To facilitate this, we must query by status. As this MLS has seen feed to not populate StandardStatus and only consistently populates the MlsStatus field, we must query against MlsStatus.

There are two formats for doing this in RESO API, using a chained OR statement, or using an “IN ()” statement. However, both method fail with a “500 Internal Server Error” being returned.

Version 1: MlsStatus in ()

post_data = {:$filter=>"MlsStatus in ('(10) Active - Active','(11) Active - Active Under Contract','(30) Pending - Pending')", :$select=>"ListingId,ModificationTimestamp,MlsStatus", :$count=>"true", :$top=>1000} URL Request:

Version 2: MlsStatus eq <val1> or MlsStatus eq <val2> …

post_data = {:$filter=>"MlsStatus eq '(10) Active - Active' or MlsStatus eq '(11) Active - Active Under Contract' or MlsStatus eq '(30) Pending - Pending')", :$select=>"ListingId,ModificationTimestamp,MlsStatus", :$count=>"true", :$top=>1000} URL Request: +Pending%27%29&%24select=ListingId%2CModificationTimestamp%2CMlsStatus&%24top=1000

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by BKFS_Customer_Care
close date 2022-12-12 10:59:09.000330

1 Answer

Sort by » oldest newest most voted

answered 2022-12-07 14:37:09 -0600

This seems to work correctly but there are two spaces after the number in parenthesis on each status:
((MlsStatus eq '(10) Active - Active') or (MlsStatus eq '(11) Active - Active Under Contract') or (MlsStatus eq '(30) Pending - Pending'))

edit flag offensive delete link more


I ended up doing a ne with the sold one.

JF gravatar imageJF ( 2022-12-08 08:31:52 -0600 )edit

Question Tools

1 follower


Asked: 2022-12-07 13:26:18 -0600

Seen: 25 times

Last updated: Dec 07 '22