keywordstring
Search query.
https://api.sandbase.ai/v1/api/dataforseo/v3/business_data/google/hotel_searches/live/advancedReturns detailed Google Hotel search results and business data for target locations. Provides hotel listings, guest ratings, and business attributes directly from Google.
[
{
"cost": 0,
"status_code": 20000,
"status_message": "Ok.",
"tasks": [
{
"cost": 0,
"data": {
"api": "business_data",
"function": "hotel_searches",
"se": "google",
"se_type": "hotel_searches"
},
"id": "09291343-2190-0293-0000-ffaaa04d8dce",
"path": [
"v3",
"business_data",
"google",
"… 2 more items in the full response"
],
"result": null,
"result_count": 0,
"status_code": 40503,
"status_message": "POST Data Is Invalid.",
"time": "0 sec."
}
],
"tasks_count": 1,
"tasks_error": 1,
"time": "0.0324 sec.",
"version": "0.1.20260917"
}
]Chọn một ví dụ để nạp đầu vào và kết quả của nó vào playground.
Returns a list of hotels that Google Hotels shows for a search query in a given location and language. Each hotel has a title, star class, coordinates, a nightly price and a guest rating. You send a keyword, a location_code and a language_code.
latitude and longitude and compare ratings by area.curl -X POST "https://api.sandbase.ai/v1/api/dataforseo/v3/business_data/google/hotel_searches/live/advanced" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"keyword": "hotels in new york", "location_code": 2840, "language_code": "en"}'
The result is returned in outputs[0].
| Name | Type | Required | Description |
|---|---|---|---|
keyword | string | No | Search query. |
language_code | string | No | Language code, e.g. "en". |
location_code | integer | No | Location code, e.g. 2840 for the United States. |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"status_code": 20000,
"status_message": "Ok.",
"tasks": [
{
"data": {
"api": "business_data",
"device": "desktop",
"function": "hotel_searches",
"keyword": "hotels in new york",
"language_code": "en",
"location_code": 2840,
"os": "windows",
"se": "google"
},
"id": "11030828-2190-0293-0000-c13ead85f48b",
"path": [
"v3"
],
"result": [
{
"check_url": "https://www.google.com/travel/search?q=hotels+in+new+york%2c+United+States&hl=en…",
"datetime": "2026-11-03 08:28:51 +00:00",
"items": [
{
"hotel_identifier": "ChoImOTyzeuCzrykARoNL2cvMTF2cGw0bnIzYhAB",
"is_paid": false,
"location": {
"latitude": 40.7835127,
"longitude": -73.8408876
},
"overview_images": [
"https://lh3.googleusercontent.com/grass-cs/AABkmLf8BlMpA-fjlDIOeCxbGUyJzy_nQ51AE…"
],
"prices": {
"check_in": "2026-11-04 00:00:00 +00:00",
"check_out": "2026-11-05 00:00:00 +00:00",
"currency": "USD",
"discount_text": "17% less than usual",
"items": null,
"price": 125,
"price_without_discount": null,
"prices_by_dates": null
},
"reviews": {
"mentions": null,
"other_sites_reviews": null,
"rating_distribution": null,
"value": 4.3,
"votes_count": 615
},
"stars": 2,
"title": "LY New York Hotel"
}
],
"items_count": 18,
"keyword": "hotels in new york, United States",
"language_code": "en",
"location_code": 2840
}
],
"result_count": 1,
"status_code": 20000,
"status_message": "Ok.",
"time": "5.0342 sec."
}
],
"tasks_count": 1,
"tasks_error": 0,
"time": "5.0432 sec.",
"version": "0.1.20261022"
}
| Field | Meaning |
|---|---|
tasks[].result[].items[].title | Hotel name as shown in Google Hotels. |
tasks[].result[].items[].hotel_identifier | Google's ID for the hotel. Use it to look up one hotel in detail. |
tasks[].result[].items[].stars | Star class of the hotel. |
tasks[].result[].items[].prices.price / tasks[].result[].items[].prices.currency | Listed price for the stay and its currency code, such as USD. |
tasks[].result[].items[].prices.check_in / tasks[].result[].items[].prices.check_out | Dates the price applies to. They use the format YYYY-MM-DD HH:MM:SS +00:00. |
tasks[].result[].items[].prices.discount_text | Discount label such as "17% less than usual". It is null when Google shows none. |
tasks[].result[].items[].reviews.value / tasks[].result[].items[].reviews.votes_count | Average guest rating and the number of ratings behind it. |
tasks[].result[].items[].location.latitude / tasks[].result[].items[].location.longitude | Coordinates of the hotel. |
tasks[].result[].items[].overview_images[] | URLs of hotel photos. |
tasks[].result[].items_count | Number of hotels in the result. |
location_code from the DataForSEO location list. The example uses 2840 for the United States.keyword with the country added, for example hotels in new york, United States. check_url links to the matching Google Hotels page.prices.items, prices.prices_by_dates and reviews.rating_distribution were null in this response.hotel_identifier to DataForSEO Google Hotel Details.Billed at the actual cost of each call, about $0.004 for the request above. Failed calls are not charged.
Bắt đầu xây dựng
Endpoint API của nền tảng với xác thực và theo dõi mức sử dụng thống nhất.
curl -X POST "https://api.sandbase.ai/v1/api/dataforseo/v3/business_data/google/hotel_searches/live/advanced" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"keyword": "hotels in new york",
"language_code": "en",
"location_code": 2840
}'Đặt SandBase API key của bạn trong môi trường máy chủ. Các request sử dụng xác thực Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Giữ key của bạn trên máy chủ. Không hiển thị trong mã chạy trên trình duyệt.
keywordstringSearch query.
location_codeintegerLocation code, e.g. 2840 for the United States.
language_codestringLanguage code, e.g. "en".
Đây là phản hồi ví dụ đã lưu cho API này; không có request thực nào được gửi khi xem mục này.
[
{
"cost": 0,
"status_code": 20000,
"status_message": "Ok.",
"tasks": [
{
"cost": 0,
"data": {
"api": "business_data",
"function": "hotel_searches",
"se": "google",
"se_type": "hotel_searches"
},
"id": "09291343-2190-0293-0000-ffaaa04d8dce",
"path": [
"v3",
"business_data",
"google",
"… 2 more items in the full response"
],
"result": null,
"result_count": 0,
"status_code": 40503,
"status_message": "POST Data Is Invalid.",
"time": "0 sec."
}
],
"tasks_count": 1,
"tasks_error": 1,
"time": "0.0324 sec.",
"version": "0.1.20260917"
}
]Khám phá thêm
| API | Giá | Phản hồi |
|---|---|---|
DataForSEO | Từ $0.004 mỗi lần gọi | JSON |
DataForSEO | Từ $0.0102 mỗi lần gọi | JSON |
DataForSEO | Từ $0.000724 mỗi lần gọi | JSON |
DataForSEO | $0.004 mỗi lần gọi | JSON |
DataForSEO | Từ $0.00162 mỗi lần gọi | JSON |
DataForSEO | Từ $0.001105 mỗi lần gọi | JSON |
Câu hỏi
Gửi yêu cầu POST đến https://api.sandbase.ai/v1/api/dataforseo/v3/business_data/google/hotel_searches/live/advanced với khóa API SandBase của bạn trong tiêu đề Authorization (Bearer) và các tham số trong phần thân JSON. Bạn cũng có thể thử trực tiếp trong Playground trên trang này mà không cần viết code.
Từ $0.004 mỗi lần gọi, được tính từ số dư SandBase của bạn. Bạn chỉ bị tính phí cho các lần gọi bạn thực hiện; không có gói đăng ký.
Không có tham số bắt buộc. Tùy chọn: keyword (string), location_code (integer) và language_code (string). Bảng Parameters và Playground trên trang này liệt kê mọi trường.
Phản hồi JSON được trả về trong cùng một yêu cầu HTTP (đồng bộ). README trên trang này có ví dụ phản hồi.
Không. DataForSEO Google Hotel Search Advanced chạy thông qua SandBase, nên chỉ cần một API key SandBase là đủ cho endpoint này và mọi API cùng model khác trong danh mục. Bạn không cần đăng ký riêng để có quyền truy cập API của DataForSEO.