Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the Flickr API for downloading a picture or URL to the picture

Tags:

oauth

flickr

I wanted to download a picture from the Flickr using the flicker API. I am using OAuth for authentication.

When I searched on the site, I got an API called flickr.photos.getInfo. But it only gives the path to the page where the picture belongs.

Can anyone tell me where I can get an API to get the actual path to an image?

like image 787
Harikrishnan Avatar asked Feb 02 '13 07:02

Harikrishnan


People also ask

What is Flickr API?

Flickr API's methods construct an endpoint (an url) which returns data in XML or JSON format. Once that is done, you may decode that data using many programming languages and present that to your users. Every Flickr API method has got several arguments to be passed, Some required and some optional.

Does Flickr have an API?

The Flickr API is available for non-commercial use by outside developers. Commercial use is possible by prior arrangement.


2 Answers

Oh I got the answer.

The API function is called flickr.photos.getSizes.

Very confusing names.

like image 185
Harikrishnan Avatar answered Sep 19 '22 20:09

Harikrishnan


You can get the urls by requesting them in the extras fields in the appropriate get methods, listed as part of the documentation for each getter method.

For a sample search, use this form http://www.flickr.com/services/api/explore/flickr.photos.getRecent with the extras field set to:

url_sq, url_t, url_s, url_q, url_m, url_n, url_z, url_c, url_l, url_o

PS. I would include the direct links but am currently limited to one link per post.

like image 41
Chris Conover Avatar answered Sep 21 '22 20:09

Chris Conover