# GetFacilities

This API retrieves information about hotel facilities, including amenities provided in the hotel as well as in individual rooms. For the most current information, it is recommended to synchronize this data weekly.
When "IsGetUrlOnly=true", the "FileType" field supports two file formats for selection: Csv and Zip. (Please note capitalization)

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": "Facilities",
    "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>Facilities</StaticType>
  <IsGetUrlOnly>true</IsGetUrlOnly>
  <FileType>Csv</FileType>
</GetStaticInformationRQ>

CSV file field description:

Field Type Mandatory Remarks
HotelID int true Unique hotel identification
Type string true Facilitie type(Hotel facility or Room facility)
Description string true Description
Description_CN string true Description_CN
   [
    {
        "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": "Facilities"
}
Request Sample
<GetStaticInformationRQ>
  <Header>
    <ClientID>DidaApiTestID</ClientID>
    <LicenseKey>TestKey</LicenseKey>
  </Header>
  <StaticType>Facilities</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/Facilities.csv?Expires=1502938618&OSSAccessKeyId=jr9mtwydMaatBmPp&Signature=FPPlGzq6qMik%2BRW8%2FFjVXlEHHB4%3D"
}
Response Sample
<?xml version="1.0"?>
<GetStaticInformationRS>
  <Url>http://static.didatravel.com/Static/2/Facilities.csv?Expires=1502938618&OSSAccessKeyId=jr9mtwydMaatBmPp&Signature=FPPlGzq6qMik%2BRW8%2FFjVXlEHHB4%3D</Url>
</GetStaticInformationRS>