# Отримання результатів пошуку готелів Google за id

**API:** Data API

**Endpoint:** `GET /v1/beta/dataforseo/business_data/google/hotel_searches/task_get/{id}`

**Tags:** DataForSEO

За `id` отримує пошуковий запит Google Hotels із черги. Відповідь обгорнуто в конверт DataForSEO: дані в `tasks[0].result`, результат у `tasks[0].status_code` — відхилений запит усе одно повертає HTTP 200. ⚠️ Розмір відповіді зафіксовано параметром `depth` або лімітом, заданим під час надсилання, і тут його не можна зменшити; якщо він завеликий, надішліть запит заново з меншим значенням, а не гортайте сторінки.

### Довідкові ціни

- Тарифікація: вартість відповіді за даними постачальника.
- Довідкова оцінка запиту: USD 0.012.
- Довідковий множник для клієнта: 1.0. Не застосовуйте його повторно до вже розрахованої суми клієнта.

Лише довідкові метадані, а не котирування для облікового запису, гарантована ціна чи ліміт витрат. Кредити ресурсів — це не кредити Felo. Остаточні списання здійснюються за записами білінгу Felo.

## Related links

- [UUID](<https://en.wikipedia.org/wiki/Universally_unique_identifier>)
- [Hotel Info](<https://docs.dataforseo.com/v3/business_data/google/hotel_info/live/advanced/>)

## Base URL

- `https://openapi.felo.ai`

## Authentication

- `FeloBearerAuth` (http bearer, bearer format Felo API Key)
- `FeloApiKey` (apiKey in header `X-API-Key`)

## Parameters

| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| `id` | path | yes | string | <em>ідентифікатор завдання</em><br><strong>унікальний ідентифікатор завдання в нашій системі у форматі UUID</strong><br>протягом <strong>30 днів</strong> ви зможете будь-коли запросити за ним результати завдання |

## Responses

### 200 — Успішна операція

Headers:
- `X-Request-Id` (string) — Ідентифікатор запиту, який потрібно вказати під час звернення до підтримки Felo.

**application/json**

Schema: object | null

```json
{
  "type": [
    "object",
    "null"
  ],
  "oneOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResponseInfo"
    }
  ]
}
```

### 400 — Не вдалося обробити запит. Перевірте параметри запиту.

### 401 — Потрібен дійсний API-ключ Felo.

### 402 — Запит неможливо виконати: умови білінгу не виконано.

### 403 — Обліковий запис не має дозволу на цю операцію.

### 429 — Досягнуто ліміту запитів або витрат.

### 502 — Служба не змогла виконати запит.

### 503 — API або служба білінгу тимчасово недоступні.

### 504 — Час очікування обробки запиту вичерпано.

### default — Відповідь із помилкою; наскрізні відповіді апстріму можуть використовувати формати постачальника

**application/json**

Schema:

```json
{}
```

## Schema definitions

### Response36Afe1097B20_BaseResponseInfo

`#/components/schemas/Response36Afe1097B20_BaseResponseInfo`

```json
{
  "properties": {
    "version": {
      "type": [
        "string",
        "null"
      ],
      "description": "поточна версія API"
    },
    "status_code": {
      "type": [
        "integer",
        "null"
      ],
      "description": "загальний код стану.\nПовний список кодів відповіді можна знайти тут."
    },
    "status_message": {
      "type": [
        "string",
        "null"
      ],
      "description": "загальне інформаційне повідомлення.\nПовний список загальних інформаційних повідомлень можна знайти тут."
    },
    "time": {
      "type": [
        "string",
        "null"
      ],
      "description": "загальний час виконання, секунди"
    },
    "cost": {
      "type": [
        "number",
        "null"
      ],
      "description": "загальна вартість завдань, USD",
      "format": "double"
    },
    "tasks_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "кількість завдань у масиві tasks",
      "format": "int64"
    },
    "tasks_error": {
      "type": [
        "integer",
        "null"
      ],
      "description": "кількість завдань у масиві tasks, повернутих з помилкою",
      "format": "int64"
    }
  }
}
```

### Response36Afe1097B20_BaseResponseTaskInfo

`#/components/schemas/Response36Afe1097B20_BaseResponseTaskInfo`

```json
{
  "properties": {
    "id": {
      "type": [
        "string",
        "null"
      ],
      "description": "ідентифікатор завдання\nунікальний ідентифікатор завдання в нашій системі у форматі UUID"
    },
    "status_code": {
      "type": [
        "integer",
        "null"
      ],
      "description": "код стану завдання\nформується DataForSEO, може перебувати в діапазоні 10000-60000\nПовний список кодів відповіді можна знайти тут."
    },
    "status_message": {
      "type": [
        "string",
        "null"
      ],
      "description": "інформаційне повідомлення завдання\nПовний список загальних інформаційних повідомлень можна знайти тут."
    },
    "time": {
      "type": [
        "string",
        "null"
      ],
      "description": "час виконання, секунди"
    },
    "cost": {
      "type": [
        "number",
        "null"
      ],
      "description": "загальна вартість завдань, USD",
      "format": "double"
    },
    "result_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "кількість елементів у масиві result",
      "format": "int64"
    },
    "path": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "string",
          "null"
        ]
      },
      "description": "шлях URL"
    },
    "data": {
      "type": [
        "object",
        "null"
      ],
      "additionalProperties": {
        "type": [
          "object",
          "null"
        ]
      },
      "description": "містить ті самі параметри, які ви вказали в POST-запиті"
    }
  }
}
```

### Response36Afe1097B20_BusinessDataGoogleHotelSearchesItem

`#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesItem`

```json
{
  "type": "object",
  "properties": {
    "type": {
      "type": [
        "string",
        "null"
      ],
      "description": "тип елемента"
    },
    "hotel_identifier": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>унікальний ідентифікатор готельної сутності в пошуку Google</em><br>приклад:<br><code>CgoI-KWyzenM_MV3EAE</code>"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>назва готелю</em>"
    },
    "stars": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>класовий рейтинг готелю</em><br>рейтинг класу в діапазоні від 1 до 5 зірок"
    },
    "is_paid": {
      "type": [
        "boolean",
        "null"
      ],
      "description": "<em>указує на платний лістинг готелю</strong></em><br>якщо <code>true</code>, пов'язаний <code>hotel_search_item</code> — платна реклама<br>якщо <code>false</code>, пов'язаний <code>hotel_search_item</code> — органічний лістинг готелю"
    },
    "location": {
      "type": [
        "object",
        "null"
      ],
      "oneOf": [
        {
          "$ref": "#/components/schemas/Response36Afe1097B20_GpsCoordinatesLocationInfo"
        }
      ],
      "description": "<em>GPS-координати місцезнаходження готелю</em>"
    },
    "reviews": {
      "type": [
        "object",
        "null"
      ],
      "oneOf": [
        {
          "$ref": "#/components/schemas/Response36Afe1097B20_HotelReviewInfo"
        }
      ],
      "description": "<em>відгуки про готель та інформація про рейтинг</em>"
    },
    "overview_images": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "string",
          "null"
        ]
      },
      "description": "<em>вибрані зображення для готелю</em>"
    },
    "prices": {
      "type": [
        "object",
        "null"
      ],
      "oneOf": [
        {
          "$ref": "#/components/schemas/Response36Afe1097B20_HotelPriceInfo"
        }
      ],
      "description": "<em>ціна готелю</em>"
    }
  }
}
```

### Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResponseInfo

`#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResponseInfo`

```json
{
  "type": "object",
  "allOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_BaseResponseInfo"
    },
    {
      "type": "object",
      "properties": {
        "tasks": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": [
              "object",
              "null"
            ],
            "oneOf": [
              {
                "$ref": "#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetTaskInfo"
              }
            ]
          },
          "description": "<em>масив завдань</em>"
        }
      }
    }
  ]
}
```

### Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResultInfo

`#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResultInfo`

```json
{
  "type": "object",
  "properties": {
    "keyword": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>ключове слово, отримане в масиві POST</em><br>ключове слово повертається з декодованими %## (символ '+' буде декодовано в пробіл);<br>для отримання точних результатів пошуку назва місцезнаходження автоматично додається до ключового слова"
    },
    "location_code": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>код місцеположення в масиві POST</em>"
    },
    "language_code": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>код мови в масиві POST</em>"
    },
    "check_url": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>прямий URL до результатів пошукової системи</em><br>за його допомогою можна переконатися, що ми надали точні результати"
    },
    "datetime": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>дата й час отримання результату</em><br>у форматі UTC: “yyyy-mm-dd hh-mm-ss +00:00”<br>приклад:<br><code class=\"long-string\">2019-11-15 12:57:46 +00:00</code>"
    },
    "items_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>типи елементів</em><br>кількість елементів у масиві <code>items</code>",
      "format": "int64"
    },
    "items": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesItem"
          }
        ]
      },
      "description": "<em>масив елементів</em><br><strong>примітка:</strong> це поле завжди дорівнює <code>null</code>; використовуйте його, щоб спростити інтеграцію та забезпечити сумісність з ендпоінтом Hotel Info"
    }
  }
}
```

### Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetTaskInfo

`#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetTaskInfo`

```json
{
  "type": "object",
  "allOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_BaseResponseTaskInfo"
    },
    {
      "type": "object",
      "properties": {
        "result": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": [
              "object",
              "null"
            ],
            "oneOf": [
              {
                "$ref": "#/components/schemas/Response36Afe1097B20_BusinessDataGoogleHotelSearchesTaskGetResultInfo"
              }
            ]
          },
          "description": "<em>масив результатів</em>"
        }
      }
    }
  ]
}
```

### Response36Afe1097B20_GpsCoordinatesLocationInfo

`#/components/schemas/Response36Afe1097B20_GpsCoordinatesLocationInfo`

```json
{
  "type": "object",
  "properties": {
    "latitude": {
      "type": [
        "number",
        "null"
      ],
      "description": "<i>координата широти готелю в Google Maps</i><br>приклад:<br><code>\"latitude\": 51.584091</code>"
    },
    "longitude": {
      "type": [
        "number",
        "null"
      ],
      "description": "<i>координата довготи готелю в Google Maps</i><br>приклад:<br><code>\"longitude\": -0.31365919999999997</code>"
    }
  }
}
```

### Response36Afe1097B20_HotelInfoPriceOffer

`#/components/schemas/Response36Afe1097B20_HotelInfoPriceOffer`

```json
{
  "type": "object",
  "properties": {
    "type": {
      "type": [
        "string",
        "null"
      ],
      "description": "тип елемента"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>назва готелю</em>"
    },
    "price": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>ціна за ніч</em>"
    },
    "currency": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>валюта ціни</em><br>за замовчуванням застосовується <code>USD</code>, якщо інше не вказано в масиві POST"
    },
    "url": {
      "type": [
        "string",
        "null"
      ],
      "description": "url цінової пропозиції\nURL сторінки сайту, на якій відображається цінова пропозиція"
    },
    "max_visitors": {
      "type": [
        "integer",
        "null"
      ],
      "description": "максимальна кількість відвідувачів\nмаксимальна кількість відвідувачів, для якої діє цінова пропозиція"
    },
    "offer_images": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "string",
          "null"
        ]
      },
      "description": "зображення цінової пропозиції\nURL зображень, представлених у ціновій пропозиції"
    },
    "free_cancellation_until": {
      "type": [
        "string",
        "null"
      ],
      "description": "дата, до якої доступне безкоштовне скасування\nу форматі UTC: “yyyy-mm-dd hh-mm-ss +00:00”\nдорівнює null, якщо безкоштовне скасування недоступне для вибраних дат"
    }
  },
  "description": "вибрані цінові пропозиції"
}
```

### Response36Afe1097B20_HotelPriceInfo

`#/components/schemas/Response36Afe1097B20_HotelPriceInfo`

```json
{
  "type": "object",
  "properties": {
    "price": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>ціна за ніч</em>"
    },
    "price_without_discount": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>повна ціна за ніч без застосування знижки</em>",
      "format": "int64"
    },
    "currency": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>валюта ціни</em><br>за замовчуванням застосовується <code>USD</code>, якщо інше не вказано в масиві POST"
    },
    "discount_text": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>текст про застосовану знижку</em>"
    },
    "check_in": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>дата й час заїзду</em><br>у форматі UTC: “yyyy-mm-dd hh-mm-ss +00:00”<br>приклад:<br><code>2019-11-15 12:57:46 +00:00</code>"
    },
    "check_out": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>дата й час виїзду</em><br>у форматі UTC: “yyyy-mm-dd hh-mm-ss +00:00”<br>приклад:<br><code>2019-11-15 12:57:46 +00:00</code>"
    },
    "visitors": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>кількість відвідувачів готелю для цієї ціни</em>"
    },
    "items": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_HotelPriceItemInfo"
          }
        ]
      },
      "description": "<em>виявлені типи елементів</em><br>типи результатів пошукової системи, виявлені в масиві <code>items</code>;<br>можливі типи елементів: <code>hotel_search_item</code>"
    },
    "prices_by_dates": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_PricesByDates"
          }
        ]
      }
    }
  }
}
```

### Response36Afe1097B20_HotelPriceItemInfo

`#/components/schemas/Response36Afe1097B20_HotelPriceItemInfo`

```json
{
  "type": "object",
  "properties": {
    "type": {
      "type": [
        "string",
        "null"
      ],
      "description": "тип елемента"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>назва готелю</em>"
    },
    "price": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>ціна за ніч</em>"
    },
    "currency": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>валюта ціни</em><br>за замовчуванням застосовується <code>USD</code>, якщо інше не вказано в масиві POST"
    },
    "url": {
      "type": [
        "string",
        "null"
      ],
      "description": "url сторонньої сторінки\nURL сторінки стороннього сайту з відомостями про ціни"
    },
    "domain": {
      "type": [
        "string",
        "null"
      ],
      "description": "сторонній домен\nдомен сторінки стороннього сайту з відомостями про ціни"
    },
    "is_paid": {
      "type": [
        "boolean",
        "null"
      ],
      "description": "<em>указує на платний лістинг готелю</strong></em><br>якщо <code>true</code>, пов'язаний <code>hotel_search_item</code> — платна реклама<br>якщо <code>false</code>, пов'язаний <code>hotel_search_item</code> — органічний лістинг готелю"
    },
    "official_site": {
      "type": [
        "boolean",
        "null"
      ]
    },
    "free_cancellation_until": {
      "type": [
        "string",
        "null"
      ],
      "description": "дата, до якої доступне безкоштовне скасування\nу форматі UTC: “yyyy-mm-dd hh-mm-ss +00:00”\nдорівнює null, якщо безкоштовне скасування недоступне для вибраних дат"
    },
    "offers": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_HotelInfoPriceOffer"
          }
        ]
      }
    }
  }
}
```

### Response36Afe1097B20_HotelReviewInfo

`#/components/schemas/Response36Afe1097B20_HotelReviewInfo`

```json
{
  "type": "object",
  "properties": {
    "value": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>загальний рейтинг готелю на основі голосів клієнтів</em>"
    },
    "votes_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>кількість голосів клієнтів</em><br>кількість голосів клієнтів, урахованих під час розрахунку рейтингу готелю",
      "format": "int64"
    },
    "mentions": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_ReviewMentionInfo"
          }
        ]
      },
      "description": "<em>згадки про готель</em><br>інформація про відгуки про готель за критеріями"
    },
    "rating_distribution": {
      "type": [
        "object",
        "null"
      ],
      "additionalProperties": {
        "type": [
          "integer",
          "null"
        ],
        "format": "Int64"
      },
      "description": "<em>розподіл оцінок за голосами</em><br>розподіл голосів за рейтингом у діапазоні від 1 до 5"
    },
    "other_sites_reviews": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "object",
          "null"
        ],
        "oneOf": [
          {
            "$ref": "#/components/schemas/Response36Afe1097B20_OtherSitesReviewsInfo"
          }
        ]
      },
      "description": "<em>відгуки на сторонніх сайтах</em><br>відгуки із сторонніх сайтів"
    }
  }
}
```

### Response36Afe1097B20_OtherSitesReviewsInfo

`#/components/schemas/Response36Afe1097B20_OtherSitesReviewsInfo`

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>заголовок відгуку</em><br>містить назву стороннього сайту, де відгук було вперше опубліковано"
    },
    "url": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>URL відгуку</em><br>URL стороннього сайту, де відгук було вперше опубліковано"
    },
    "review_text": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>текст відгуку</em><br>текст відгуку"
    },
    "rating": {
      "type": [
        "object",
        "null"
      ],
      "oneOf": [
        {
          "$ref": "#/components/schemas/Response36Afe1097B20_RatingInfo"
        }
      ],
      "description": "<em>рейтинг у відгуку</em><br>інформація про рейтинг, що міститься у відгуку на сторонньому сайті"
    }
  }
}
```

### Response36Afe1097B20_PricesByDates

`#/components/schemas/Response36Afe1097B20_PricesByDates`

```json
{
  "type": "object",
  "properties": {
    "price": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>ціна за ніч</em>"
    },
    "currency": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>валюта ціни</em><br>за замовчуванням застосовується <code>USD</code>, якщо інше не вказано в масиві POST"
    },
    "check_in_date": {
      "type": [
        "string",
        "null"
      ]
    },
    "check_out_date": {
      "type": [
        "string",
        "null"
      ]
    }
  }
}
```

### Response36Afe1097B20_RatingInfo

`#/components/schemas/Response36Afe1097B20_RatingInfo`

```json
{
  "properties": {
    "rating_type": {
      "type": [
        "string",
        "null"
      ],
      "description": "тип рейтингу\nтут можна знайти такі елементи: Max5, Percents, CustomMax"
    },
    "value": {
      "type": [
        "number",
        "null"
      ],
      "description": "значення рейтингу",
      "format": "double"
    },
    "votes_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "кількість відгуків",
      "format": "int64"
    },
    "rating_max": {
      "type": [
        "integer",
        "null"
      ],
      "description": "максимальне значення для rating_type"
    }
  }
}
```

### Response36Afe1097B20_ReviewMentionInfo

`#/components/schemas/Response36Afe1097B20_ReviewMentionInfo`

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "<em>заголовок оцінюваного критерію</em>"
    },
    "positive_score": {
      "type": [
        "number",
        "null"
      ],
      "description": "<em>позитивна оцінка за критерієм</em>"
    },
    "positive_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>кількість позитивних відгуків за критерієм</em>",
      "format": "int64"
    },
    "negative_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>кількість негативних відгуків за критерієм</em>",
      "format": "int64"
    },
    "total_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "<em>кількість усіх відгуків за критерієм</em>",
      "format": "int64"
    },
    "visible_by_default": {
      "type": [
        "boolean",
        "null"
      ],
      "description": "<em>елемент видимий за замовчуванням</em><br>указує, чи видимий елемент відгуку за замовчуванням"
    }
  }
}
```
