{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Hotels Price Scraper – Vendor Rates, Price History",
    "description": "Hotel prices from Google Hotels: per-vendor rates (OTA price ladder), rate comparison and price history for tracked stays. API and MCP-ready. Data-quality figures: data.yappman.com/data-quality",
    "version": "0.1",
    "x-build-id": "AXMPTwOZWF7YdhsAV"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yappman~google-hotels-prices/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yappman-google-hotels-prices",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/yappman~google-hotels-prices/runs": {
      "post": {
        "operationId": "runs-sync-yappman-google-hotels-prices",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/yappman~google-hotels-prices/run-sync": {
      "post": {
        "operationId": "run-sync-yappman-google-hotels-prices",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "search",
              "hotel",
              "history",
              "tracked"
            ],
            "type": "string",
            "description": "What to run. search: find hotels for a destination. hotel: look up hotels by id or Google Travel URL for one pair of dates. history: stored lead-price snapshots for tracked hotels. tracked: list the tracked hotels (free).",
            "default": "search"
          },
          "searches": {
            "title": "Searches",
            "maxItems": 20,
            "type": "array",
            "description": "search mode only. Up to 20 searches, each with destination (a city, area or landmark, 1-200 characters), optional checkIn and checkOut (YYYY-MM-DD, checkOut after checkIn), adults (1-12, default 2) and rooms (must be 1, Google ignores it). Dates should be in the future. Give both dates, or neither: with neither, the stay is 2 nights starting 14 days after the run starts; checkIn alone gives a 2-night stay; checkOut without checkIn is rejected. Each search reads at most 30 result pages (about 540 hotels); the run stops at maxItems.",
            "default": [
              {
                "destination": "Lisbon",
                "adults": 2,
                "rooms": 1
              }
            ]
          },
          "hotels": {
            "title": "Hotels",
            "maxItems": 1000,
            "type": "array",
            "description": "hotel and history modes only. Google hotel ids (they start with Ch) or Google Travel hotel page URLs containing /travel/hotels/entity/<id>. Up to 1,000 in hotel mode and 100 in history mode, each up to 500 characters. Entries that are neither are skipped.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "dates": {
            "title": "Dates",
            "type": "object",
            "description": "hotel and history modes only. { \"checkIn\": \"YYYY-MM-DD\", \"checkOut\": \"YYYY-MM-DD\" }, checkOut after checkIn, both in the future. Both modes use 2 adults and 1 room; history returns only stays stored for exactly these dates."
          },
          "includeVendorRates": {
            "title": "Include vendor rates",
            "type": "boolean",
            "description": "search mode only (rejected in other modes). Adds each hotel's per-vendor rates, with the vendor's registrable domain as vendorDomain. Off by default. It makes one extra request per hotel and is charged as its own event for each hotel that comes back with rates.",
            "default": false
          },
          "filters": {
            "title": "Filters",
            "type": "object",
            "description": "search and hotel modes. Optional keys: minPrice and maxPrice (per night, in the chosen currency), minRating (0-5; compares against the rating rounded to one decimal), hotelClass (a list of 1-5). The Actor applies them after fetching; hotels that fail a filter, or lack the data it needs, are dropped and do not count toward maxItems. Each row's filtersApplied.actor names the filters set. freeCancellation: true and a non-empty amenities list are rejected as not supported yet.",
            "default": {}
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "relevance",
              "price",
              "rating",
              "reviews"
            ],
            "type": "string",
            "description": "search mode only. The order Google returns results in: relevance (default), price (lowest first), rating (highest first) or reviews (most reviewed). maxItems keeps the first hotels in that order.",
            "default": "relevance"
          },
          "currency": {
            "title": "Currency",
            "pattern": "^[A-Z]{3}$",
            "type": "string",
            "description": "search and hotel modes. Three-letter uppercase currency code, e.g. USD or GBP. Prices are shown as Google returns them in this currency; the Actor never converts.",
            "default": "USD"
          },
          "language": {
            "title": "Language",
            "pattern": "^[a-z]{2}(-[A-Z]{2})?$",
            "type": "string",
            "description": "search and hotel modes. Language code sent to Google as hl: two lowercase letters, optionally with a region, e.g. en or en-GB.",
            "default": "en"
          },
          "country": {
            "title": "Country",
            "pattern": "^[a-z]{2}$",
            "type": "string",
            "description": "search and hotel modes. Two-letter lowercase country code sent to Google as gl, e.g. us. uk for the United Kingdom returned a normal Google results page when tested; gb has not been tested.",
            "default": "us"
          },
          "maxItems": {
            "title": "Max hotels",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "search and hotel modes. The most hotels returned in one run, across all searches, 1 to 1,000. Hotels removed by filters, and duplicates, do not count. History mode ignores it (up to 100 hotels).",
            "default": 20
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}