Ask Your Question

Querying Media resource by MLSNum

asked 2020-07-02 10:41:55 -0600

We want to switch from downloading the photos for GALMLS to just using the Media URLs, but it seems like the Media resource is missing data. For example, MLS# 879663 has 30 photos, but when I query the Media data I get nothing back:

Why is that?


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2020-07-02 11:46:44 -0600

Looks like your account profile is only configured to allow Media for Active listings.
That particular listing is Pending so you wouldn't be able to see Media for it.
You will need to contact the MLS directly to request access.

edit flag offensive delete link more


But that makes no sense, with our account we can download Pending, Contingent, and Coming soon listings. This sounds like a mistake. Can you fix it?

Separately, we see that very often the media urls are temporarily unavailable. They seem flaky. Likewise, our multipart GetObject photo downloads frequently encounter timeouts downloading photos. It's a persistent issue that's well documented in our logs. Are you aware of these problems?

jflaig gravatar imagejflaig ( 2020-07-02 11:52:43 -0600 )edit

I looked and several other similar feeds have the same Media settings.
You will need to contact the MLS directly on this.
When using GETOBJECT I always recommend using Location=1 to return the URLs.
If you need the actual images, you can download them using the URL returned.
This is much more efficient than downloading multiple large image files using GETOBJECT.
When done this way, it takes into account image caching schemes.

bwolven gravatar imagebwolven ( 2020-07-02 12:14:38 -0600 )edit

Ok, we will contact the MLS, as for the rest I am familier with that, but it doesn't address the consistent performance issues we have getting the photo files and with the Media URLs sometimes producing 404s.

jflaig gravatar imagejflaig ( 2020-07-02 12:16:40 -0600 )edit

Here's an example, one of many many dozens, where we get errors trying to get photos. MLS# 854398 has a photocount of 28, but we can only get 26 photos. Attempting to get the 27th photos, for instance, returns this:

<rets replycode="20409" replytext="Object Unavailable [854398:27]." &gt;="" <="" rets="">

jflaig gravatar imagejflaig ( 2020-07-06 07:51:35 -0600 )edit

I cleaned up the images. Hopefully this will be much better now.
There can always be issues where the image may not present though.
Users can leave gaps in the image order or be in the process of maintaining them when you pull.
You should allow for missing images in your code and handle it gracefully.

bwolven gravatar imagebwolven ( 2020-07-06 11:53:26 -0600 )edit

So as a rule of thumb if the object is unavailable we should essentially ignore it and our process should not try to re download it ever?

jflaig gravatar imagejflaig ( 2020-07-06 11:55:31 -0600 )edit

I wouldn't try to download it again unless Last_Photo_updt changes signifying images changed.
It could only be a temporary situation, such as when images are being reordered.
But that process should update the Last_Photo_updt when completed.

bwolven gravatar imagebwolven ( 2020-07-06 12:01:41 -0600 )edit

so in this scenario the photo count in the listing data cannot always really be relied on to be accurate, correct? If our process compares the photo count to what we have and sees a difference it will try and get the missing pics, but you're saying sometimes there may be gaps, but the gaps aren't accounted for in the photo count. Isn't that a bug?

jflaig gravatar imagejflaig ( 2020-07-06 12:39:54 -0600 )edit
Login/Signup to Answer

Question Tools



Asked: 2020-07-02 10:41:55 -0600

Seen: 278 times

Last updated: Jul 02 '20