- Previous: Keyword Queries
- Up: Documentation Version 2
- Next: Author Queries
Photo Queries
Photos
The API provides a way to programmatically access all the photos that are part of the World Bank Photo Library - more than 12,000 photos on development.
The following information is captured about each photo:
Photo ID
Title
Description
Thumb URL
owRes URL
HighRes URL
Year
Topic ID
Topic Name
Keyword ID
Keyword Name
Author ID
Author Name/photos
Lists all photos
For example, the following query returns information about photo #187.
http://open.worldbank.org/photos/187?api_key=xxxx
And this is the xml returned:
<wb:photo id="187">
<wb:title>0782-16</wb:title>
<wb:description>Agadir Outskirts women in traditional costume at rural bus stop</wb:description>
<wb:country id="MAR">Morocco</wb:country>
<wb:thumbURL>http://secure.worldbank.org/photolibrary/shared/SiteResources/PhotoLibrary/Images/0782-16.gif</wb:thumbURL>
<wb:lowResURL>http://secure.worldbank.org/photolibrary/shared/SiteResources/PhotoLibrary/Images/secure/LowRes/0782-16.jpg</wb:lowResURL>
<wb:highResURL>http://secure.worldbank.org/photolibrary/shared/SiteResources/PhotoLibrary/Images/secure/HighRes/0782-16.tif</wb:highResURL>
<w:year>2002</wb:year>
<wb:topics>
<wb:topic id="644303">Transport </wb:topic>
</wb:topics>
<wb:keywords>
<wb:keyword id="Bus">Bus</wb:keyword>
<wb:keyword id="Development">Development </wb:keyword>
<wb:keyword id="Rural">Rural</wb:keyword>
<wb:keyword id="Women">Women</wb:keyword>
</wb:keywords>
<wb:authors>
<wb:author id="47">Julio Etchart</wb:author>
</wb:authors>
</wb:photo>
Sample Calls
URL-based queries
http://open.worldbank.org/countries/br/photos?api_key=xxxx
Returns all photos associated with the country Brazil (also accepts ISO3 code)
http://open.worldbank.org/topics/Education;Gender/photos?api_key=xxxx
Displays all photos that are associated with either Education or Gender topic.
http://open.worldbank.org/keywords/class;art/photos?api_key=xxxx
Returns all photos tagged with either class or art keywords
http://open.worldbank.org/keywords/class,art/photos?api_key=xxxx
Returns all photos tagged with both class and art keywords
http://open.worldbank.org/photos/2345?api_key=xxxx
Returns specific photo by unique ID
http://open.worldbank.org/authors/Alan Gignoux/photos/?api_key=xxxx
Returns all photos by a specific author (identified by name)
http://open.worldbank.org/authors/1/photos/?api_key=xxxx
Returns all photos by a specific author (identified by author_id)
Argument-based queries
http://open.worldbank.org/photos/?countries=us;ge&keywords=birds?api_key=xxxx
Returns all photos from either the country United States (us) or Georgia (ge) that are tagged with keyword: birds
http://open.worldbank.org/photos/?regions=ECA&keywords=class?api_key=xxxx
Returns all photos from the region: ECA (Europe and Central Asia) and tagged with keyword: class
http://open.worldbank.org/photos?authors=Alan Gignoux?api_key=xxxx
Returns all photos by a specific author (identified by name)
http://open.worldbank.org/photos?authors=1?api_key=xxxx
Returns all photos by a specific author (identified by author_id)
- Previous: Keyword Queries
- Up: Documentation Version 2
- Next: Author Queries


Comments
Please sign in to post a comment.