First time here? Check out the FAQ!

Error "Could not get URL" Pulling Images


Recently when my application is trying to update all the data including images I always got the error on my server: "ExceptionType":"librets.RetsHttpExceptionNative","ExceptionMessage":"Could not get URL [] when it was trying to get either thumbnails or photos from you. I was thinking if there are issues with the Rets Session here.

The rets version is 1.7.2. My account name is NTPV16641 and librets version is 1.6.1.

So wondering if there's session time our or something that's causing the issue?

aven's avatar
asked 2015-09-24 11:16:18 -0500
bwolven's avatar
updated 2015-09-30 14:18:57 -0500
edit flag offensive 0 remove flag close merge delete


The session should not be a problem unless your application is idle for a period of time. Do you receive any other information about the error? Does it always fail on the same request?

mdean's avatar mdean (2015-09-28 14:47:03 -0500) edit

That's the only issue I'm having right now. I changed the timeout to be 1 hour on the server, now it just kept processing without doing anything now.

aven's avatar aven (2015-09-29 08:48:30 -0500) edit

I tested getobject for Property and I was able to get photo URLs from that site without issue. Are you pulling individual photos or all photos for a listing or listings?

bwolven's avatar bwolven (2015-09-29 09:05:19 -0500) edit

Are you still having issues with this. I see successful getobject requests from your account for Property Photo, Agent Photo and OfficeLogo?

bwolven's avatar bwolven (2015-09-30 10:47:09 -0500) edit

Yeh, for some reason I managed to update all photos since last night. And I'll do a bit more testing on it. Thank you very much!

aven's avatar aven (2015-09-30 10:50:48 -0500) edit
add a comment see more comments

1 Answer


I see from the logs that you are requesting the actual photo binary data. It would be more efficient and less prone to timeouts if you requested photos using Location=1 which will return the URLs for the photos. It would also greatly reduce server load. Even if you needed local copies of the photos you could download them using the URL returned which would make more effective use of our image caching. It also looks like your librets must be set to rets version 1.5 not 1.7.2 from what we are showing in our logs.

You set the RETS version using SetRetsVersion() in the librets.RetsSession object.

You set Location=1 by using the GetObjectRequest object, method SetLocation (true).

To retrieve the URL use the ObjectDescriptor object, method GetObjectLocation() instead of getting the stream and writing the file to your storage. You should also check the reply code for the object by using method GetRetsReplyCode() to make sure it is a valid object.

Here is the librets help URL:

bwolven's avatar
answered 2015-09-30 10:56:48 -0500, updated 2015-09-30 13:42:56 -0500
edit flag offensive 0 remove flag delete link


add a comment see more comments

Your Answer

Login/Signup to Answer