Home API State Library of Queensland Photograph Collection API

State Library of Queensland Photograph Collection API


Back in 2013, and then updated in 2015, the State Library of Queensland made around 50,000 copyright-expired images available via a ‘Picture Queensland’ collection. We took the fairly comprehensive CSV and XML data and created our own archive (of pre-1954 photographs) with a full-featured API to browse, search, and retrieve images. While the database is part of another one of our fairly broad projects, the collection in isolation is excellent, and its one we make available to all of our current and former clients. A WordPress plugin available via our client area creates a full library of the images with a search function on your own website.

The Result

Access to data is via the following endpoint: http://api.beliefmedia.com/australia/qld/qld.json. A number of parameters determine what information is returned.


If returning details for a single image, the image itemid is required along with your API Key. If an ID is passed via the URL, all other parameters will be ignored.

type & search

The type can be browse or search. If no type is defined and no id is present in the URL (to return a single result), browse will be used. If the type is search, a search term must be provided.

pg & number

The pg parameter determined the page to be returned. number determines how many results will be shown.

■ ■ ■

The first result shows how our JSON unfolds when searching a specific term or browsing results. A basic search, or simply browsing all paginated results, returns data in a similar manner. Request made was as follows: qld.json?apikey=xxx&pg=1&number=10&search=soldier.

To return details for a single result we provide only our apikey and the itemid. So, qld.json?apikey=xxxx&id=k5 returns the following:

Reference Data

The reference array key provides details of the record as hosted on the SLQLD server. The related array, for example, provides links to related material or ‘see more’ galleries. Other data associated with the image is documented in more details in our client area. The digiviewer value, for example, is associated with the DigiToolViewer used to view high quality scans (http://hdl.handle.net/10462/deriv/{digiviewer}), and the identifier is usually a Negative number.

Image Data

The image links provided by the SLQLD are of reasonable web quality. Linking to the permanent record as described above provides access to the full resolution version.

We’ve copied all images locally, and each image reference on our own server is returned in the JSON data. A zip file containing all the images and thumbnails may be downloaded via our client area (22.45GB). Our image structure is as follows: images/{year}/{itemid.jpg}, and this structure is retained in the download file.

Sample PHP Functions

The following are the most basic of functions necessary to retrieve data. An API Key is provided to all clients and is available to others upon request.

Browsing or Searching Results

Returning Single Result

If the code returns anything other than 200 an error has occurred. The most common error is 404 (not found), and this applies when a request is made for an image record or paginated result that doesn’t exist.


  • A large number of results are geo-tagged. You may search results within a specific radius of a latitude and longitude with the type of geo (type=geo&lat=xxx&lng=xxx). Documentation available in our client area.
  • We’ll be modifying the subject field soon than later (the default field is a little bit of a mess). If you plan on using this data in an application we suggest you hold off for a couple of weeks.

Shortt URL for this post: http://shor.tt/Izi


Please enter your comment!
Please enter your name here