# Booking Hotel Scraper (`api-ninja/booking-hotel-scraper`) Actor

- **URL**: https://apify.com/api-ninja/booking-hotel-scraper.md
- **Developed by:** [API ninja](https://apify.com/api-ninja) (community)
- **Stats:** 6 total users, 5 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### 🏨 What is Booking.com Hotel Search Scraper?

**Booking.com Hotel Search Scraper** extracts hotel search results from Booking.com, including **stay prices, guest review scores, star ratings, locations, room information, photos, and property links**. Paste a Booking.com search URL, choose how many hotels to collect, and start the Actor. You can also build a search using a destination and manual filters.

Use the results to compare accommodation, research destinations, monitor prices for a specific stay, or build travel datasets. Each hotel is saved as a structured record that you can browse in Apify Console or download for further analysis.

#### ✨ Main features

- **🔗 Search by URL:** reuse the destination, dates, guests, filters, language, and currency from a Booking.com search results URL.
- **🛠️ Manual search:** enter a location or a known Booking destination ID, then choose your stay and hotel filters.
- **📄 Automatic pagination:** collect your requested number of unique hotels or enable **Scrape all** to continue until the API returns an empty results array.
- **⭐ Useful comparison data:** see prices, star ratings, guest scores, review counts, and distance from the center together.
- **📋 Two table views:** start with Hotel details or switch to the compact Hotel overview.
- **💾 Original records:** retain the endpoint's nested hotel data, including null values and listing flags.

Apify also provides [scheduled runs](https://docs.apify.com/actors/running/schedules), run logs, dataset downloads, and [integrations](https://docs.apify.com/integrations) for connecting results to your other tools.

### 🚀 How to scrape Booking.com hotels

1. Open the Actor in Apify Console and select **🔗 Booking.com search URL** as the search mode.
2. Paste a URL from a Booking.com search results page, such as `https://www.booking.com/searchresults.html?ss=New%20York`.
3. Set **Desired number of hotels**. Start with 25 for a small trial run, or enable **Scrape all** to collect every available page.
4. Optionally expand **🛠️ Manual search & filters** to override dates, guests, prices, ratings, language, or currency.
5. Start the run, follow its progress in the logs, and open the **Output** tab to browse or download your results.

**API access:** the Actor requires a valid RapidAPI subscription/key for its Booking search endpoint. For your own deployment, configure the key as the `RAPID_API_KEY` environment variable before running. It is separate from your Apify API token and is not an input field. A deployment without a configured key will stop with an authentication configuration error.

#### 🔗 URL search example

This example searches New York for two adults and children aged 5 and 12. Without dates in the URL or manual overrides, the endpoint defaults to tomorrow for a one-night stay.

```json
{
    "searchMode": "url",
    "url": "https://www.booking.com/searchresults.html?ss=New%20York&group_adults=2&group_children=2&age=5&age=12",
    "maxResults": 100,
    "scrapeAll": false
}
```

#### 🛠️ Manual search example

Choose manual mode to search without a Booking.com URL. This example looks for New York accommodation with three, four, or five stars and a guest score of at least 7, displaying prices in USD.

```json
{
    "searchMode": "manual",
    "query": "New York",
    "maxResults": 100,
    "scrapeAll": false,
    "adults": 2,
    "children_ages": "5,12",
    "rooms": 1,
    "stars": "3,4,5",
    "min_review_score": "7",
    "locale": "en-us",
    "currency": "USD"
}
```

#### ♾️ Scrape all available results

```json
{
    "searchMode": "url",
    "url": "https://www.booking.com/searchresults.html?ss=New%20York",
    "scrapeAll": true
}
```

With `scrapeAll` enabled, `maxResults` is ignored. The Actor keeps requesting pages until the API returns `results: []`. There is no fixed page or result cap. Duplicate hotels are skipped, and a page containing only duplicates does not end the search.

### ⚙️ Input settings

#### Search and result limits

| Field        | What to enter                                                    | Default / behavior                                                                                         |
| ------------ | ---------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- |
| `searchMode` | `"url"` or `"manual"`.                                           | Defaults to `"url"`. Set `"manual"` explicitly for manual searches through the API.                        |
| `url`        | A `booking.com/searchresults.html` URL containing a destination. | Required in URL mode. You can supply a destination override through `query` or a destination ID/type pair. |
| `maxResults` | Integer of at least 25.                                          | Defaults to 100. Maximum unique hotels to save; ignored when `scrapeAll` is true.                          |
| `scrapeAll`  | `true` or `false`.                                               | Defaults to `false`. Enable to fetch pages until the API returns an empty results array.                   |

Pagination is handled automatically. There is no `page` input. Each new search starts at page 1, and page/offset hints in a pasted URL are removed.

#### Destination

| Field       | What to enter                                              | Behavior                                                                                 |
| ----------- | ---------------------------------------------------------- | ---------------------------------------------------------------------------------------- |
| `query`     | A location, such as `"New York"` or `"Berlin"`.            | Resolves to the first matching destination. Overrides the URL destination when supplied. |
| `dest_id`   | A Booking destination ID, as a string.                     | Use together with `dest_type` instead of `query`.                                        |
| `dest_type` | The destination type paired with the ID, such as `"city"`. | Copy the value associated with your destination ID from Autocomplete.                    |

In manual mode, provide **either a query or both destination ID and type**. Do not supply a query and a destination ID/type pair together. A URL entered in manual mode is ignored.

#### Stay and guests

| Field           | What to enter                                        | When left blank                                             |
| --------------- | ---------------------------------------------------- | ----------------------------------------------------------- |
| `checkin`       | A date in `YYYY-MM-DD` format, today or later.       | Uses the valid URL date, otherwise tomorrow.                |
| `checkout`      | A date in `YYYY-MM-DD` format, after check-in.       | Uses the valid URL date, otherwise check-in plus one night. |
| `adults`        | Integer from 1 to 30.                                | Uses the URL value, otherwise 2.                            |
| `children_ages` | Comma-separated ages from 0 to 17, such as `"5,12"`. | Keeps URL ages, otherwise no children.                      |
| `rooms`         | Integer from 1 to 30.                                | Uses the URL value, otherwise 1.                            |

To remove children from a URL-based search, remove the URL's `age` and `group_children` parameters. Leaving `children_ages` blank preserves the URL values.

#### Hotel filters, language, and currency

| Field              | What to enter                                                         | When left blank                                                   |
| ------------------ | --------------------------------------------------------------------- | ----------------------------------------------------------------- |
| `sort_by`          | A supported order code. The selector suggests common choices.         | Uses the URL order, otherwise Booking's top picks (`popularity`). |
| `price_min`        | Nonnegative integer: minimum total stay price.                        | Keeps the URL filter, otherwise no minimum.                       |
| `price_max`        | Nonnegative integer: maximum total stay price, at least `price_min`.  | Keeps the URL filter, otherwise no maximum.                       |
| `stars`            | Comma-separated ratings from 1 to 5, such as `"4,5"`.                 | Keeps URL filters, otherwise all star ratings.                    |
| `min_review_score` | `"6"` (Pleasant), `"7"` (Good), `"8"` (Very good), or `"9"` (Superb). | Keeps the URL filter, otherwise no minimum.                       |
| `locale`           | A Booking language code, such as `"en-us"`, `"de"`, or `"fr"`.        | Uses the URL language, otherwise `en-us`.                         |
| `currency`         | A three-letter currency code, such as `"USD"`, `"EUR"`, or `"GBP"`.   | Uses the URL currency, otherwise `USD`.                           |

Booking's website sort codes, including `bayesian_review_score`, `price_from_high_to_low`, `distance_from_search`, and `upsort_bh`, are accepted as aliases.

#### How URL values and manual filters interact

**Any explicitly passed parameter overrides its URL counterpart; invalid URL hints (past dates, unknown codes) are ignored rather than rejected.** Leave optional filters blank to keep your URL settings or use the endpoint defaults.

For example, a URL with `group_adults=4` keeps four adults when `adults` is blank. Setting `adults` to `2` overrides it. Explicitly entered manual values are validated: a past manual check-in date, an invalid child age, or a maximum price below the minimum will stop the run.

Both price filters refer to the **total stay price in the selected currency**, rather than a nightly budget.

### 📊 Output and example data

The default dataset contains **one record per unique hotel**, with the original nested structure preserved. Depending on the search, Booking may also return other accommodation types, such as apartments.

The Output tab offers:

- **📋 Hotel details — default:** all 33 documented fields, with location, price, rating, and room information expanded into columns.
- **🏨 Hotel overview — compact:** photo, name, Booking.com link, city, total stay price, currency, stars, guest score, review summary/count, distance from the center, and sold-out status.

Apify's built-in raw data view and the dataset API retain the original records. The custom tables change presentation, not stored data. Download results as JSON, CSV, or Excel from the dataset export options; JSON preserves nested objects.

#### What data is included?

| Data group        | Included information                                                                                                            |
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| Property          | Hotel ID, name, Booking.com link, page name, accommodation type/type ID, and image URL.                                         |
| Location          | Address, city, country code, latitude, longitude, distance from the center, nearby public transport, and central-location flag. |
| Reviews and stars | Guest score, review count, localized review summary, star rating, and raw star symbol.                                          |
| Room / unit       | Unit name, number of beds, and number of bedrooms, when supplied.                                                               |
| Price             | Currency, total stay price, nightly price, price before discount, and taxes/charges information, when supplied.                 |
| Listing flags     | Preferred, sponsored, new, sold out, and sustainability flags.                                                                  |

The following is an illustrative record from a New York search. Your hotel's availability, order, and prices depend on the dates and guests you choose.

```json
{
    "id": 1424666,
    "name": "Holiday Inn New York City - Times Square by IHG",
    "link": "https://www.booking.com/hotel/us/holiday-inn-new-york-times-square-south.html",
    "page_name": "holiday-inn-new-york-times-square-south",
    "accommodation_type": "hotel",
    "accommodation_type_id": 204,
    "image": "https://cf.bstatic.com/xdata/images/hotel/square600/234143597.webp?k=7b099bf5edd5f41533f10215acf0c6ef6c22b8fc7b358ca496757b235f08d9c3&o=",
    "location": {
        "address": "585 8th Avenue",
        "city": "New York (New York)",
        "country_code": "us",
        "latitude": 40.755131,
        "longitude": -73.99134,
        "distance_from_center": "1 miles from downtown",
        "nearest_public_transport": "42nd Street-Port Authority Bus Terminal station is within 350 yards",
        "is_centrally_located": true
    },
    "rating": {
        "score": 7.9,
        "count": 3190,
        "word": "Good",
        "stars": 3,
        "stars_symbol": "NONE"
    },
    "unit": {
        "name": null,
        "beds": 2,
        "bedrooms": 0
    },
    "price": {
        "currency": "USD",
        "total": 431.12,
        "per_night": null,
        "before_discount": 634,
        "charges_info": null
    },
    "is_preferred": true,
    "is_sponsored": false,
    "is_new": false,
    "is_sold_out": false,
    "is_sustainable": false
}
```

**Prices and missing values:** `price.total` is the total price returned for the searched stay. Taxes and fee inclusion are not inferred; consult `charges_info` when available and verify the offer on Booking.com. A `null` nightly price or room name means that value was not supplied. The Actor does not replace missing prices with zero or calculate missing nightly prices.

Search-level metadata, such as destination resolution, stay dates, and pagination counts, is not added to individual hotel rows. Keep the search input with your exported dataset when comparing runs.

### 💰 Pricing and controlling costs

This Actor uses **pay-per-event pricing**, effective **October 12, 2026**. You pay for the Actor start and each result saved to the default dataset. **Apify platform usage costs for the run are included**, so there is no separate platform usage charge for running this Actor.

| Event                                             | Standard price           | Bronze, Silver, or Gold price |
| ------------------------------------------------- | ------------------------ | ----------------------------- |
| Actor start (`apify-actor-start`)                 | $0.01 per run            | $0.01 per run                 |
| Saved hotel result (`apify-default-dataset-item`) | $10.00 per 1,000 results | $1.00 per 1,000 results       |

The result rate is **$0.01 per saved hotel** at the standard price or **$0.001 per saved hotel** with a Bronze, Silver, or Gold discount. The discount applies to results; the Actor start remains $0.01. Check the Actor's Pricing tab for the rate available to your account.

#### Example run costs

| Hotels saved in one run | Standard price, including start | Bronze, Silver, or Gold, including start |
| ----------------------- | ------------------------------- | ---------------------------------------- |
| 100                     | $1.01                           | $0.11                                    |
| 1,000                   | $10.01                          | $1.01                                    |

These examples assume one Actor start and the stated number of saved results. If a search saves fewer hotels, the result charge reflects the number actually saved. The $0.01 start charge applies even when no results are saved; each additional run has its own start charge.

Start with **25 results** to check the search, then increase `maxResults` as needed. Enable **Scrape all** when you want every available page until the API returns an empty results array. Automatic pagination and duplicate removal help keep the dataset focused on unique hotels.

### 🔌 API, scheduling, and integrations

Use the same input JSON through [the Apify API](https://docs.apify.com/api/v2) to run searches from scripts, applications, or automation workflows. The run's `results` output links to the default dataset's original hotel rows.

Save repeatable searches as tasks and [schedule them](https://docs.apify.com/actors/running/schedules) to track selected destinations. For a rolling one-night search, omit fixed dates from both the URL and manual fields so the endpoint can apply its relative defaults. To compare prices for one particular trip, keep the dates, guests, currency, and filters consistent across runs.

[Apify integrations](https://docs.apify.com/integrations) let you connect runs and datasets to workflow tools and storage systems. You can also combine this Actor with other tools from [Apify Store](https://apify.com/store) to process or deliver the resulting hotel data.

### ❓ FAQ and support

#### Why did I receive fewer hotels than requested?

`maxResults` is a ceiling. Your destination and filters may produce fewer results, and some hotels may repeat between pages. The Actor continues until it reaches the requested number of unique hotels or the API returns an empty results array. Try broader filters or a different stay to explore more accommodation.

#### Why do prices or results differ from my browser?

Compare the destination, dates, guest ages, rooms, currency, and sort order first. Prices and availability can change between searches. Manual overrides may also make the Actor's search differ from the pasted URL. Always verify an offer on the property's Booking.com page before making a reservation.

#### Does it collect individual guest reviews or make reservations?

It collects hotel search results, including aggregate review scores and counts. Individual review text and reservation creation are outside this Actor's scope.

#### What should I do if a run fails?

Check the final error in the run log. For input errors, confirm the search mode, provide a valid destination, and check dates and numeric ranges. For HTTP 401 or 403, the deployment operator should check its RapidAPI key and subscription. Rate-limit and temporary server failures are retried automatically; if they persist, check the provider's allowance and try again later. Hotels saved before a failure remain in the dataset, so inspect partial results before starting another run.

#### How can I report a problem or request a feature?

Open the Actor's **Issues** tab in Apify Console and include the run ID, relevant error message, and a minimal example of the search settings. Remove credentials before sharing input or logs. For bugs in your own deployment, you can also open an issue in the [GitHub repository](https://github.com/maks1302/booking-hotels-scraper/issues).

# Actor input Schema

## `searchMode` (type: `string`):

Choose a Booking.com search URL or build a search with the manual destination and filters below. Filters can also override URL values.

## `url` (type: `string`):

Paste a booking.com/searchresults.html URL. Its destination, dates, guests, filters, currency and language are used automatically. Any explicitly passed parameter overrides its URL counterpart; invalid URL hints (past dates, unknown codes) are ignored rather than rejected. Pagination starts at page 1, regardless of the URL offset.

## `maxResults` (type: `integer`):

Maximum number of unique hotels to save (at least 25). Stops earlier if the API returns an empty results array. Ignored when Scrape all is enabled.

## `scrapeAll` (type: `boolean`):

Automatically fetch pages until the API returns an empty results array. No fixed page or result cap. Ignores the desired result count.

## `query` (type: `string`):

Location to search, e.g. New York, Berlin or Paris. Resolves to the first matching destination. Required in manual mode unless both destination ID and type are supplied. In URL mode, a nonblank query overrides the URL destination.

## `dest_id` (type: `string`):

Booking destination ID from Autocomplete. Supply together with destination type instead of a query.

## `dest_type` (type: `string`):

Destination type from Autocomplete, paired with destination ID. Copy the exact returned value (e.g. city).

## `checkin` (type: `string`):

YYYY-MM-DD, today or later. Leave blank to use the URL date or, without a valid URL date, tomorrow.

## `checkout` (type: `string`):

YYYY-MM-DD, after check-in. Leave blank to use the URL date or, without a valid URL date, check-in + 1 night.

## `adults` (type: `integer`):

Number of adults (1–30). Leave blank to use the URL value or 2 adults.

## `children_ages` (type: `string`):

Comma-separated ages from 0 to 17, e.g. 5,12. Leave blank to keep URL ages or travel without children. To clear ages from a URL, remove its age and group_children parameters.

## `rooms` (type: `integer`):

Number of rooms (1–30). Leave blank to use the URL value or 1 room.

## `sort_by` (type: `string`):

Leave blank for the URL order or Booking’s top picks (popularity). Website order codes such as bayesian_review_score, price_from_high_to_low, distance_from_search and upsort_bh are accepted. You can also enter an endpoint-supported order code.

## `price_min` (type: `integer`):

Minimum total price for the stay in the selected currency. Leave blank to keep the URL filter or apply no minimum.

## `price_max` (type: `integer`):

Maximum total price for the stay in the selected currency. Must be at least the minimum price. Leave blank to keep the URL filter or apply no maximum.

## `stars` (type: `string`):

Comma-separated hotel star ratings to include, from 1 to 5 (e.g. 4,5). Leave blank to keep URL filters or include all ratings.

## `min_review_score` (type: `string`):

Leave blank to keep the URL filter or apply no minimum. Choose 6 (Pleasant), 7 (Good), 8 (Very good) or 9 (Superb).

## `locale` (type: `string`):

Booking language code, e.g. en-us, de or fr. Leave blank to keep the URL language or use en-us.

## `currency` (type: `string`):

3-letter currency code, e.g. USD, EUR or GBP. Leave blank to keep the URL currency or use USD.

## Actor input object example

```json
{
  "searchMode": "url",
  "url": "https://www.booking.com/searchresults.html?ss=New+York+%28NYC%29%2C+New+York%2C+United+States+of+America&ssne=Lviv&ssne_untouched=Lviv&efdco=1&label=mkt123sc-e61c468f-b305-48b9-a865-4ad79c35925f&aid=304142&lang=en-us&sb=1&src_elem=sb&src=searchresults&dest_id=20088325&dest_type=city&ac_meta=GiA5MTVlNDE1MGVlOGEzZTRmYjZkYWQ5MThlMWZiZGVkMCABKAEyAnh1OgJueQ%3D%3D&ac_position=1&ac_click_type=b&ac_langcode=xu&ac_suggestion_list_length=5&search_selected=true&search_pageview_id=915e4150ee8a3e4fb6dad918e1fbded0&ltfd=1%3A5%3A9-2027%3A1%3A&group_adults=2&no_rooms=1&group_children=0",
  "maxResults": 100,
  "scrapeAll": false,
  "adults": null,
  "rooms": null,
  "price_min": null,
  "price_max": null
}
```

# Actor output Schema

## `results` (type: `string`):

All saved hotel rows, including property links, images, location, review scores, star ratings, room information, prices and listing flags. The API URL returns original nested JSON. Table views format the same stored rows for comparison.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "url": "https://www.booking.com/searchresults.html?ss=New+York+%28NYC%29%2C+New+York%2C+United+States+of+America&ssne=Lviv&ssne_untouched=Lviv&efdco=1&label=mkt123sc-e61c468f-b305-48b9-a865-4ad79c35925f&aid=304142&lang=en-us&sb=1&src_elem=sb&src=searchresults&dest_id=20088325&dest_type=city&ac_meta=GiA5MTVlNDE1MGVlOGEzZTRmYjZkYWQ5MThlMWZiZGVkMCABKAEyAnh1OgJueQ%3D%3D&ac_position=1&ac_click_type=b&ac_langcode=xu&ac_suggestion_list_length=5&search_selected=true&search_pageview_id=915e4150ee8a3e4fb6dad918e1fbded0&ltfd=1%3A5%3A9-2027%3A1%3A&group_adults=2&no_rooms=1&group_children=0",
    "query": "",
    "dest_id": "",
    "dest_type": "",
    "checkin": "",
    "checkout": "",
    "children_ages": "",
    "sort_by": "",
    "stars": "",
    "min_review_score": "",
    "locale": "",
    "currency": ""
};

// Run the Actor and wait for it to finish
const run = await client.actor("api-ninja/booking-hotel-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "url": "https://www.booking.com/searchresults.html?ss=New+York+%28NYC%29%2C+New+York%2C+United+States+of+America&ssne=Lviv&ssne_untouched=Lviv&efdco=1&label=mkt123sc-e61c468f-b305-48b9-a865-4ad79c35925f&aid=304142&lang=en-us&sb=1&src_elem=sb&src=searchresults&dest_id=20088325&dest_type=city&ac_meta=GiA5MTVlNDE1MGVlOGEzZTRmYjZkYWQ5MThlMWZiZGVkMCABKAEyAnh1OgJueQ%3D%3D&ac_position=1&ac_click_type=b&ac_langcode=xu&ac_suggestion_list_length=5&search_selected=true&search_pageview_id=915e4150ee8a3e4fb6dad918e1fbded0&ltfd=1%3A5%3A9-2027%3A1%3A&group_adults=2&no_rooms=1&group_children=0",
    "query": "",
    "dest_id": "",
    "dest_type": "",
    "checkin": "",
    "checkout": "",
    "children_ages": "",
    "sort_by": "",
    "stars": "",
    "min_review_score": "",
    "locale": "",
    "currency": "",
}

# Run the Actor and wait for it to finish
run = client.actor("api-ninja/booking-hotel-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "url": "https://www.booking.com/searchresults.html?ss=New+York+%28NYC%29%2C+New+York%2C+United+States+of+America&ssne=Lviv&ssne_untouched=Lviv&efdco=1&label=mkt123sc-e61c468f-b305-48b9-a865-4ad79c35925f&aid=304142&lang=en-us&sb=1&src_elem=sb&src=searchresults&dest_id=20088325&dest_type=city&ac_meta=GiA5MTVlNDE1MGVlOGEzZTRmYjZkYWQ5MThlMWZiZGVkMCABKAEyAnh1OgJueQ%3D%3D&ac_position=1&ac_click_type=b&ac_langcode=xu&ac_suggestion_list_length=5&search_selected=true&search_pageview_id=915e4150ee8a3e4fb6dad918e1fbded0&ltfd=1%3A5%3A9-2027%3A1%3A&group_adults=2&no_rooms=1&group_children=0",
  "query": "",
  "dest_id": "",
  "dest_type": "",
  "checkin": "",
  "checkout": "",
  "children_ages": "",
  "sort_by": "",
  "stars": "",
  "min_review_score": "",
  "locale": "",
  "currency": ""
}' |
apify call api-ninja/booking-hotel-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,api-ninja/booking-hotel-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/fNjWoPOKJjRtUxeX7/builds/1uEgD72sEi3dLe8Nh/openapi.json
