I am making a call to an api method that returns an image based on the
parameters I pass. What is the best way to capture the url of the
returned image? Thanks.
Henry Jones wrote:
I am making a call to an api method that returns an image based on the
parameters I pass. What is the best way to capture the url of the
returned image? Thanks.
You have to give more info for us to help you.
I am personally confused because you are calling this api, at a specific
url, right? If it returns an image, isn’t the url that you sent the
request to the url of the image? If so, you should know the url of the
image before you send the request.
Are you getting the binary data as part of an xml response?
Alex W. wrote:
Henry Jones wrote:
I am making a call to an api method that returns an image based on the
parameters I pass. What is the best way to capture the url of the
returned image? Thanks.You have to give more info for us to help you.
I am personally confused because you are calling this api, at a specific
url, right? If it returns an image, isn’t the url that you sent the
request to the url of the image? If so, you should know the url of the
image before you send the request.Are you getting the binary data as part of an xml response?
Sorry to be a little vague. The photo service that I am working with
does have an api, but currently it only provides the url to the full
size image. For what I am doing, this is not optimal since I am loading
many images at once and displaying them at smaller sizes. So as a
temporary fix, they provided me with a url to call and pass in the
desired size. That url then apparently creates and stores the new sized
image, and redirects to that image, which has its own url. I was asked
to make the call to the first url and then for subsequent calls use the
url of the generated image.
So, my question is… how do I grab the url of the image I get back? I
know it is strange, but they say that is all they can do right now.