Get Image Gallery

This operation retrieves any extra images for a specific project. When requesting full <project> information, the <imageGallerySize> indicates the number of images available. If this number is greater than zero you can access the extra images using this operation. This is a non-secure request as indicated by the '/public/' element in the URL path, therefore, an access token (authentication) is not required.

HTTP Method:

GET

Content Type:

xml, json

Accept Type:

xml, json

Path:

https://api.globalgiving.org/api/public/projectservice/projects/{projectid}/imagegallery

Path Parameters:

{projectid} the numeric identifier for a project, replace with actual value, required

Query String Parameters:

&api_key described in the API Key section, required

Query String Example:

/api/public/projectservice/projects/4381/imagegallery?api_key=YOUR_API_KEY

HTTP GET Request using cURL:

curl -H "Accept: application/xml" -H "Content-Type: application/xml" -X GET "https://api.globalgiving.org/api/public/projectservice/projects/4381/imagegallery?api_key=YOUR_API_KEY"

XML Response:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<images>
   <image id="123">
      <title>Image Title<title>
      <imagelink  size="small">
         <url>https://www.globalgiving.org/pfil/4381/pict_grid1.jpg</url>
       </imagelink>
      <imagelink size="thumbnail">
         <url>https://www.globalgiving.org/pfil/4381/pict.jpg</url>
      </imagelink>
      <imagelink size="medium">
         <url>https://www.globalgiving.org/pfil/4381/pict_med.jpg</url>
      </imagelink>
      <imagelink size="large">
         <url>https://www.globalgiving.org/pfil/4381/pict_grid7.jpg</url>
      </imagelink>
      <imagelink size="extraLarge">
         <url>https://www.globalgiving.org/pfil/4381/pict_large.jpg</url>
      </imagelink>
      <imagelink size="original">
         <url>https://www.globalgiving.org/pfil/4381/pict.jpg</url>
      </imagelink>
   </image>
   <image id="124">
      <imagelink size="small">
         <url>https://www.globalgiving.org/pfil/4381/ph_grid1_4381_15669.jpg</url>
      </imagelink>
      <imagelink size="thumbnail">
         <url>https://www.globalgiving.org/pfil/4381/th_4381_15669.jpg</url>
      </imagelink>
      <imagelink size="medium">
         <url>https://www.globalgiving.org/pfil/4381/ph_med_4381_15669.jpg</url>
      </imagelink>
      <imagelink size="large">
         <url>https://www.globalgiving.org/pfil/4381/ph_grid7_4381_15669.jpg</url>
      </imagelink>
      <imagelink size="extraLarge">
         <url>https://www.globalgiving.org/pfil/4381/ph_4381_15669.jpg</url>
      </imagelink>
      <imagelink size="original">
         <url>https://www.globalgiving.org/pfil/4381/ph_4381_15669.jpg</url>
      </imagelink>
      <title>Another Image title</title>
   </image>
   ...
   <image id="...">
      <imagelink size="...">
         <url>...</url>
      </imagelink>
      ...
      <title>...</title>
   </image>
</images>

NOTE: The <image> element is repeating.

Get Image Gallery Response Structure

images
image [zero or more]

id (attribute) int
title string
imagelink [one or more]

size (attribute) string
url string

Element Definitions for Get Image Gallery Response

Element Mandatory Description
image -> id required a unique id within the set identifying the image
image -> title optional the image title (if available)
image -> imagelink -> size required Size (WxH in pixels) that the image is available in. Possible values:
small: Maximum dimensions of 75x75 - best fit, may be smaller in one dimension.
thumbnail: Fixed size of 80x52.
medium: Maximum dimensions of 300x220 - best fit, may be smaller in one dimension.
large: Maximum dimensions 540x405 - best fit, may be smaller in one dimension.
extraLarge: Maximum dimensions 1024x1024 - may be smaller in either or both dimensions. Will fit larger images to 1024 on one side. Smaller images are not scaled up.
original: The original image file that was uploaded to GlobalGiving and was used to generate the other versions.
image -> imagelink -> url required URI to project's image for specified size.
WARNING: Javascript is currently disabled or is not available in your browser. GlobalGiving makes extensive use of Javascript and will not function properly with Javascript disabled. Please enable Javascript and refresh this page.