Images

You can use this method to fetch images for a given hotel using hotel_code.

Method URL
GET api/v3/hotels/<hcode>/images
  • <hcode> refers to the ‘hotel_code’ returned in the search response.
  • N.B: All image paths should be prefixed with the base url https://cdn.grnconnect.com/
  • Example : https://cdn.grnconnect.com/hotels/images/fa/67/fa67573977698e4442dd4c301168a20c9bd411b4.jpg

Response

Attribute Type Description
images object An object of image paths grouped by size.

Images

Attribute Type Description
regular array Contains the list of image paths
small array Contains the list of image paths
large array Contains the list of image paths

Error Codes

HTTP Status Code Error Code Description
200 1507 Invalid hotel code
404 5002 Hotel not found
200 5137 No images found for the hotel

Sample Response

{
  "images": {
    "regular": [
      {
        "path":  "hotels/images/fa/67/fa67573977698e4442dd4c301168a20c9bd411b4.jpg"
      },
      {
        "path": "hotels/images/e4/14/e414d4545fe00cd16336ab91af20ccdc4ccdec31.jpg"
      }
    ]
    "small": [
      {
        "path": "hotels/images/ff/e7/ffe7d4545fe00cd16336ab91af20ccdc4ccdec31.jpg"
      }
    ],
    "large": [
      {
        "path": "hotels/images/07/1d/071dd4545fe00cd16336ab91af20ccdc4ccdec31.jpg"
      }
    ]
}