Smart Ordering Image

This endpoint allows you to enable or disable smart ordering for images of a hotel. The request must include the hotel_id, channel_hotel_id, and smart_ordering (must be either 0 or 1).

When smart ordering is enabled for a property, the sequence in which photos are displayed on the property page is determined by Booking.com's machine learning algorithm. This algorithm takes various factors into account to present the images in an order that optimally engages guests.

NOTE

Smart ordering is enabled by default for all properties.


Endpoint

POST

https://connect-sandbox.su-api.com/SUAPI/jservice/bdc/photo/imageSmartOrder
-app-id: YOUR_APP_ID
Authorization: YOUR_API_KEY
Content-Type:application/json
Header
Type
Required
Description

app-id

string

Yes

Your application ID. Required for authentication.

Authorization

string

Yes

Your API key. for authorization. Required for authentication.

Content-Type

string

Yes

Must be set to application/json.


Attributes


hotel_id string (Required)

The unique property ID as assigned by the provider upon creation of the property.


channel_hotel_id string (Required)

The unique id for the hotel on the specific channel.


smart_ordering boolean (Required)

Indicates whether smart ordering is enabled (1) or disabled (0).

Smart ordering refers to a predetermined sequence for displaying images based on specific parameters. This feature can be toggled on or off by providing the following allowable values:

  • Enable: 1

  • Disable: 0


Sample Request

{
   "hotel_id": "NT7",
   "channel_hotel_id": "12837615",
   "smart_ordering": 1
}

Response

Sample Success Response

{
   "Status": "Success",
   "Data": [],
   "Message": "Image Smart-Order Updated Successfully"
}

Success Response Body Elements

Status string

Indicates the result of the API call.

Will be "Success" for successful operations.


Data array

An array of image objects containing details of each retrieved image.


Message string

A message indicating the result of the operation.

Errors

Sample Error Response 1

{
   "Errors": [
       {
           "Code": "400",
           "ShortText": "HotelCode: Invalid HotelCode ('NT711')"
       }
   ],
   "Status": "Fail"
}

Sample Error Response 2

{
   "Errors": [
       {
           "Code": "573",
           "ShortText": "channel-mapping not found for this property!"
       }
   ],
   "Status": "Fail"
}

Sample Error Response 3

{
   "Errors": [
       {
           "Code": "582",
           "ShortText": "smart_ordering: is required, should be one of 1 or 0"
       }
   ],
   "Status": "Fail"
}

Error Response Body Elements

Status string

Indicates the result of the API call, which will be always "Fail" in case of an error response.


Error array

Array that contains details about any errors that occurred during the API call. Each object in the Errors array contains the following properties:

Code string

Specific error code that helps identify the type of error.

For example: "400" indicates a bad request.

ShortText string

A short description of the error.


Message string

A message providing more information about the error.

Last updated

Was this helpful?