# Fetch Single Image

API call format

GET /images/image/{guid}              //Use token autorization

Description

Returns a direct URL to the image

Precondition:

  • Authorization token is needed.
  • Mandatory elements (should be specified):
  • Optional elements:
    • w - Desired width of the image in pixels. Example format: 320
    • h - Desired height of the image in pixels. Example format: 160
    • e - Extract a region of the image format in px (left,top,width,height). Example format: 20,200,10,100; Extraction will be executed before resizing
    • f - Format of the image. If non specified default image format will be returned. Allowed values: jpeg, jpg, png, tiff, webp
    • d - Desired dimension of the image in pixels. Example format: 320x160
    • q - Quality of the image (between 1 and 100)

Postcondition

  • On success response code should be 200
  • On success returns a direct URL to the image.
  • On failure an error will be returned with the right error code and description.

Example:

[Request] GET https://<base_api_url>/images/image/<image_guid>                //use GET /images to find a specific image guid
[Request Headers] {"Content-Type":"application/json","Accept":"application/json","Authorization":"<IdToken>"}
[Response] 200
[Response Headers] {"Content-Type":["application/json"],"Content-Length":["..."],"Connection":["keep-alive"],"Date":["..... GMT"],"x-amzn-RequestId":["....."],....]}
[Response] 
<Image URL>