酒店信息

用于填充预订引擎页面框架的数据:联系方式与位置、社交媒体链接、页脚文本(法律条款、酒店简介、Analytics/Ads 代码片段),以及用于发送确认邮件的 SMTP 设置。

联系方式#

GET/external/hotel/{hotelID}/contact/info

身份验证: Authorization: Bearer

路径参数

hotelIDinteger必填
酒店 ID。

响应

200 成功。

错误响应

  • 404 未找到酒店。
请求
curl "https://test.hms.gen.tr/external/hotel/1000/contact/info" \
  -H "Authorization: Bearer $HMS_TOKEN"
响应 · 200
{
    "title": "Demo Otel",
    "phone": "+90 258 000 00 00",
    "cellPhone": "+90 555 000 00 00",
    "email": "[email protected]",
    "www": "https://www.demootel.com",
    "address": "Kumsal Cad. No: 12",
    "country": "Türkiye",
    "countryIng": "Turkey",
    "city": "Antalya",
    "district": "Muratpaşa",
    "latitude": "36.8841",
    "longitude": "30.7056"
}

社交媒体链接#

GET/external/online/social/media

身份验证: Authorization: Bearer

查询参数

hotelIDinteger必填
酒店 ID。
limitinteger默认值: 20
每页记录数。
pageinteger默认值: 1
页码。
orderstring
id-id

响应

200 成功。

请求
curl "https://test.hms.gen.tr/external/online/social/media?hotelID=1000" \
  -H "Authorization: Bearer $HMS_TOKEN"
响应 · 200
{
    "success": true,
    "count": 2,
    "items": [
        {
            "url": "https://www.instagram.com/demootel",
            "SosyalMedyaKategori": {
                "icon": "fa-instagram",
                "iconsvg": null
            }
        },
        {
            "url": "https://www.facebook.com/demootel",
            "SosyalMedyaKategori": {
                "icon": "fa-facebook",
                "iconsvg": null
            }
        }
    ]
}

邮件服务器设置#

GET/external/online/mail/host

身份验证: Authorization: Bearer

返回酒店为在线预订确认邮件配置的 SMTP 设置。其中包含密码,请仅在服务端使用。

查询参数

hotelIDinteger必填
酒店 ID。

响应

200 成功。

错误响应

  • 200 mail_host_is_not_found — 未配置 SMTP;hotel_id_is_not_found
请求
curl "https://test.hms.gen.tr/external/online/mail/host?hotelID=1000" \
  -H "Authorization: Bearer $HMS_TOKEN"
响应 · 200
{
    "success": true,
    "data": {
        "transport": "smtp",
        "encryption": "tls",
        "port": 587,
        "host": "smtp.demootel.com",
        "user": "[email protected]",
        "password": "********"
    }
}
最后更新: 2026年9月21日发现错误?请告诉我们