POST/hotelinfo/

Get Hotel Proximities

Get hotel proximities

Implementation Notes

This API call returns the basic details of hotels available in our AI hotel database.

In case the hotel you search for is not displayed in our database, please send a request to events@aggregateintelligence.in. We will try to make it available within the next 24 hours.

Search Criteria:

  • Any parameter (single or in any combination).
  • If lat and lng are chosen, then proximity must also be provided.

Field Formats:

  • proximity:
    Format: Should be numeric and in miles
    Example: "proximity": 2

  • hotelCode:

    • A unique ID assigned to a hotel in the AI hotel database.
    • If the user knows the hotel code, they can fetch the basic hotel details by calling this method.

Example 1:


{ "hotelCode": 0, "hotelCodes": [], "hotelName": "", "address": "", "city": "", "state": "", "zip": "", "country": "", "rating": "1", "lat": "", "lng": "", "proximity": 0 }

Example 2:


{ "hotelCode": 0, "hotelCodes": [5991590,5993989], "hotelName": "", "address": "", "city": "", "state": "", "zip": "", "country": "", "rating": "1", "lat": "", "lng": "", "proximity": 0 }

Example 3:


{ "hotelCode": 0, "hotelCodes": [], "hotelName": "", "address": "", "city": "", "state": "", "zip": "", "country": "", "rating": "1", "lat": "41.8913913", "lng": "-87.6054344", "proximity": 5 }

POST/hotelinfo/

Parameter Details

NameInTypeRequiredDescription
hotelsinfoPerPagequeryintegerOptionalThe number of items to display in a page
pageNumberqueryintegerOptionalIndicates the current page number
bodybodyobjectRequirednone
» hotelCodebodyintegerOptionalUnique ID assigned to a hotel in the database.
» hotelCodesbody[integer]OptionalList of hotel codes to fetch multiple hotels.
» hotelNamebodystringOptionalnone
» addressbodystringOptionalnone
» citybodystringOptionalnone
» statebodystringOptionalnone
» zipbodystringOptionalnone
» countrybodystringOptionalnone
» ratingbodystringOptionalnone
» latbodystringOptionalLatitude coordinate of the hotel.
» lngbodystringOptionalLongitude coordinate of the hotel.
» proximitybodyintegerOptionalSearch radius in miles.

Responses

StatusMeaningDescriptionSchema
200OKOK
400Bad RequestBad RequestNone
401UnauthorizedUnauthorizedNone
429Too Many RequestsToo Many RequestsNone
500Internal Server ErrorInternal Server ErrorNone

Example Request

# You can also use wget
curl -X POST https://api.events.example.com/api/v1/hotelinfo/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

Example responses

200 Response
{
"hotelCode": 0,
"hotelCodes": [],
"hotelName": "",
"address": "",
"city": "",
"state": "",
"zip": "",
"country": "",
"rating": "1",
"lat": "",
"lng": "",
"proximity": 0
}

Body parameter

{
  "hotelCode": 0,
  "hotelCodes": [],
  "hotelName": "",
  "address": "",
  "city": "",
  "state": "",
  "zip": "",
  "country": "",
  "rating": "",
  "lat": "",
  "lng": "",
  "proximity": 0
}

Example responses

200 Response
{
  "pageInfo": {
    "totalRecords": 533411,
    "fetchedRecords": 1,
    "totalPages": 533411,
    "currentPage": 1,
    "pageSize": 1
  },
  "hotels": [
    {
      "hotelCode": 2,
      "hotelName": "Gwynn's Island RV Resort",
      "address": "551 Buckchase Road",
      "city": "Gwynn",
      "state": "Virginia",
      "zip": "23066",
      "country": "United States",
      "latitude": "37.4909",
      "longitude": "-76.2745",
      "rating": "4.00"
    }
  ]
}

Need Support?

Our team is here to help you integrate and make the most of our APIs. Get in touch for technical support, custom solutions, or any questions.