Informations de l’hôtel
Données qui alimentent l’habillage des pages du moteur de réservation : coordonnées et localisation, liens vers les réseaux sociaux, textes de pied de page (mentions légales, présentation, extraits Analytics/Ads) et paramètres SMTP des e-mails de confirmation.
GET
/external/hotel/{hotelID}/contact/infoCoordonnéesGET/external/online/social/mediaLiens vers les réseaux sociauxGET/external/online/footerTextes de pied de pageGET/external/online/mail/hostParamètres du serveur de messagerieCoordonnées#
GET
/external/hotel/{hotelID}/contact/infoAuthentification: Authorization: Bearer
Paramètres de chemin
hotelIDintegerobligatoireIdentifiant de l’hôtel.
Réponse
200 Succès.
Réponses d’erreur
- 404 Hôtel introuvable.
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"
}Paramètres du serveur de messagerie#
GET
/external/online/mail/hostAuthentification: Authorization: Bearer
Renvoie les paramètres SMTP configurés par l’hôtel pour les e-mails de confirmation des réservations en ligne. Contient un mot de passe : à utiliser uniquement côté serveur.
Paramètres de requête
hotelIDintegerobligatoireIdentifiant de l’hôtel.
Réponse
200 Succès.
Réponses d’erreur
- 200
mail_host_is_not_found— aucun SMTP configuré ;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": "********"
}
}
Liens vers les réseaux sociaux#
/external/online/social/mediaAuthentification:
Authorization: BearerParamètres de requête
hotelIDintegerobligatoirelimitintegerpar défaut:20pageintegerpar défaut:1orderstringidou-id.Réponse
200 Succès.