# GetHotelImage

This API retrieves information about hotel photos, including their URLs. For the most current information, it is recommended to synchronize this data weekly.
Please note, the images provided by Dida are sourced from its suppliers and direct contracts. Dida does not hold the copyright for these images. If you require access to download hotel and room images from Dida's static content, you are required to sign a Disclaimer Agreement and send it to your API account manager. Once Dida receives the signed agreement, they will grant you access to the images. You can download the Disclaimer Agreement by following the provided URL.
Disclaimer Agreement Download

When "IsGetUrlOnly=true", the "FileType" field supports two file formats for selection: Csv and Zip. (Please note capitalization)

Please note that because Dida's images have anti-hotlinking features, do not directly reference Dida images via the provided addresses, as the images may fail to display. The Dida team recommends that you first download the images to your server and then read the images from your server.

POST
https://apiint.didatravel.com/api/staticdata/GetStaticInformation?$format=json
In the following example, the code parameters inside are modifiable.
Use the following method to test API:
{
    "IsGetUrlOnly": true,
    "Header": {
        "LicenseKey": "TestKey",
        "ClientID": "DidaApiTestID"
    },
    "StaticType": "HotelImage",
    "FileType":"Csv"
}
In the following example, the code parameters inside are modifiable.
Use the following method to test API:
<GetStaticInformationRQ>
  <Header>
    <ClientID>DidaApiTestID</ClientID>
    <LicenseKey>TestKey</LicenseKey>
  </Header>
  <StaticType>HotelImage</StaticType>
  <IsGetUrlOnly>true</IsGetUrlOnly>
  <FileType>Csv</FileType>
</GetStaticInformationRQ>

CSV file field description:

Field Type Mandatory Remarks
HotelID int true Unique hotel identification
ImageCaption string true Image caption
ImageUrl string true Image url
ImageOrder string true Image order
IsDefault bool true Is default
   [
    {
        "name": "Header",
        "description": "Client authentication info",
        "children": [
            {
                "name": "ClientID",
                "description": "Client ID"
            },
            {
                "name": "LicenseKey",
                "description": "Client password"
            }
        ]
    },
    {
        "name": "StaticType",
        "description": "Static information type. For instance: HotelSummary."
    },
    {
        "name": "IsGetUrlOnly",
        "description": "Return download url if true. Need extra code to handle HTTP 302 if it is false."
    },
    {
        "name": "FileType",
        "description": "Optional fields, currently supports two file types: Csv and Zip. (Please note capitalization)"
    }
]
Request Parameters
Header HeaderType
Client authentication infoHeaderType
StaticType GetStaticInformationRQStaticType Static information type. For instance: HotelSummary.GetStaticInformationRQStaticType
IsGetUrlOnly Boolean Return download url if true. Need extra code to handle HTTP 302 if it is false.Boolean
FileType String Optional fields, currently supports two file types: Csv and Zip. (Please note capitalization)String
Request Sample
{
    "Header": {
        "LicenseKey": "TestKey",
        "ClientID": "DidaApiTestID"
    },
    "IsGetUrlOnly": true,
    "StaticType": "HotelImage"
}
Request Sample
<GetStaticInformationRQ>
  <Header>
    <ClientID>DidaApiTestID</ClientID>
    <LicenseKey>TestKey</LicenseKey>
  </Header>
  <StaticType>HotelImage</StaticType>
  <IsGetUrlOnly>true</IsGetUrlOnly>
</GetStaticInformationRQ>
Response Parameters
Url String Static resource URL. If IsGetUrlOnly = false, response will redirect to the resource URL. Redirection needs to be supported by client.String
Response Sample
{
    "Url": "http://static.didatravel.com/Static/2/HotelImage.csv?Expires=1502938618&OSSAccessKeyId=jr9mtwydMaatBmPp&Signature=FPPlGzq6qMik%2BRW8%2FFjVXlEHHB4%3D"
}
Response Sample
<?xml version="1.0"?>
<GetStaticInformationRS>
  <Url>http://static.didatravel.com/Static/2/HotelImage.csv?Expires=1502938618&OSSAccessKeyId=jr9mtwydMaatBmPp&Signature=FPPlGzq6qMik%2BRW8%2FFjVXlEHHB4%3D</Url>
</GetStaticInformationRS>