Informații despre hotel
Datele care alimentează elementele fixe ale paginilor motorului de rezervări: date de contact și localizare, linkuri către rețelele sociale, texte de subsol (texte legale, despre hotel, fragmente de cod Analytics/Ads) și setările SMTP pentru e-mailurile de confirmare.
GET
/external/hotel/{hotelID}/contact/infoDate de contactGET/external/online/social/mediaLinkuri către rețelele socialeGET/external/online/footerTexte de subsolGET/external/online/mail/hostSetările serverului de e-mailDate de contact#
GET
/external/hotel/{hotelID}/contact/infoAutentificare: Authorization: Bearer
Parametri de cale
hotelIDintegerobligatoriuID-ul hotelului.
Răspuns
200 Succes.
Răspunsuri de eroare
- 404 Hotelul nu a fost găsit.
curl "https://test.hms.gen.tr/external/hotel/1000/contact/info" \
-H "Authorization: Bearer $HMS_TOKEN"const res = await fetch("https://test.hms.gen.tr/external/hotel/1000/contact/info", {
headers: {
"Authorization": `Bearer ${process.env.HMS_TOKEN}`
}
});
const data = await res.json();$ch = curl_init('https://test.hms.gen.tr/external/hotel/1000/contact/info');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('HMS_TOKEN'),
],
]);
$data = json_decode(curl_exec($ch), true);{
"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"
}Setările serverului de e-mail#
GET
/external/online/mail/hostAutentificare: Authorization: Bearer
Returnează setările SMTP configurate de hotel pentru e-mailurile de confirmare a rezervărilor online. Conține o parolă; folosiți-le exclusiv pe server.
Parametri de interogare
hotelIDintegerobligatoriuID-ul hotelului.
Răspuns
200 Succes.
Răspunsuri de eroare
- 200
mail_host_is_not_found— niciun server SMTP configurat;hotel_id_is_not_found.
curl "https://test.hms.gen.tr/external/online/mail/host?hotelID=1000" \
-H "Authorization: Bearer $HMS_TOKEN"const res = await fetch("https://test.hms.gen.tr/external/online/mail/host?hotelID=1000", {
headers: {
"Authorization": `Bearer ${process.env.HMS_TOKEN}`
}
});
const data = await res.json();$ch = curl_init('https://test.hms.gen.tr/external/online/mail/host?hotelID=1000');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('HMS_TOKEN'),
],
]);
$data = json_decode(curl_exec($ch), true);{
"success": true,
"data": {
"transport": "smtp",
"encryption": "tls",
"port": 587,
"host": "smtp.demootel.com",
"user": "[email protected]",
"password": "********"
}
}
Linkuri către rețelele sociale#
/external/online/social/mediaAutentificare:
Authorization: BearerParametri de interogare
hotelIDintegerobligatoriulimitintegerimplicit:20pageintegerimplicit:1orderstringidsau-id.Răspuns
200 Succes.