{
  "openapi": "3.0.1",
  "info": {
    "title": "Tripadvisor Scraper - Hotels, Restaurants & Reviews",
    "description": "Scrape Tripadvisor hotels, restaurants and things to do for any city, with ratings, rankings, prices, contacts, amenities, hours and reviews. No browser, pay per result.",
    "version": "1.0",
    "x-build-id": "dfnT1mjIsEniKfnnt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/extraordinary_grasshopper~tripadvisor-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-extraordinary_grasshopper-tripadvisor-scraper",
        "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/extraordinary_grasshopper~tripadvisor-scraper/runs": {
      "post": {
        "operationId": "runs-sync-extraordinary_grasshopper-tripadvisor-scraper",
        "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/extraordinary_grasshopper~tripadvisor-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-extraordinary_grasshopper-tripadvisor-scraper",
        "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",
        "properties": {
          "locations": {
            "title": "Locations (cities, regions, countries)",
            "type": "array",
            "description": "Destinations to list places from: a name (Paris, Bali, New York City), a Tripadvisor destination URL or its geo id (the number after -g in the URL). One per line.",
            "items": {
              "type": "string"
            }
          },
          "scrapeHotels": {
            "title": "Hotels",
            "type": "boolean",
            "description": "List the hotels of each location.",
            "default": true
          },
          "scrapeRestaurants": {
            "title": "Restaurants",
            "type": "boolean",
            "description": "List the restaurants of each location.",
            "default": false
          },
          "scrapeAttractions": {
            "title": "Things to do (attractions)",
            "type": "boolean",
            "description": "List the attractions, tours and activities of each location.",
            "default": false
          },
          "maxPlacesPerLocation": {
            "title": "Max places per location and type",
            "minimum": 1,
            "maximum": 3000,
            "type": "integer",
            "description": "Stops paging once this many hotels / restaurants / attractions are collected for a location (30 per page).",
            "default": 30
          },
          "placeUrls": {
            "title": "Place URLs or ids",
            "type": "array",
            "description": "Specific hotels, restaurants, attractions or tours: a Tripadvisor URL (any country domain) or the location id (the number after -d in the URL). You get their full details, and their reviews when reviews are turned on.",
            "items": {
              "type": "string"
            }
          },
          "includeDetails": {
            "title": "Include full place details",
            "type": "boolean",
            "description": "Opens every place for its full page: contact info, website, subratings, rating distribution, amenities, hours, menu, awards, photos and an AI review summary. Charged as place details instead of a list place.",
            "default": false
          },
          "includeReviews": {
            "title": "Include reviews",
            "type": "boolean",
            "description": "Scrapes the reviews of every place (one dataset item per review).",
            "default": false
          },
          "maxReviewsPerPlace": {
            "title": "Max reviews per place",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Most recent reviews first by default.",
            "default": 20
          },
          "reviewsLanguage": {
            "title": "Reviews language",
            "type": "string",
            "description": "2-letter code (en, fr, de, es, it, ja, pt, ru, zh-CN...). \"en\" includes reviews machine-translated to English; \"all\" returns every review in its original language.",
            "default": "en"
          },
          "reviewsSort": {
            "title": "Sort reviews",
            "enum": [
              "most_recent",
              "detailed",
              "insightful"
            ],
            "type": "string",
            "description": "Order in which reviews are collected.",
            "default": "most_recent"
          },
          "reviewRatings": {
            "title": "Only these star ratings",
            "type": "array",
            "description": "Ratings from 1 to 5, one per line, e.g. 1 and 2 for complaints. Empty = all ratings.",
            "items": {
              "type": "string"
            }
          },
          "reviewTripTypes": {
            "title": "Only these trip types",
            "type": "array",
            "description": "family, couples, solo, business or friends, one per line. Empty = all trip types.",
            "items": {
              "type": "string"
            }
          },
          "reviewKeyword": {
            "title": "Only reviews mentioning",
            "type": "string",
            "description": "A word or phrase the review must contain, e.g. breakfast or parking. Optional."
          },
          "hotelSort": {
            "title": "Hotel list order",
            "enum": [
              "best_value",
              "traveler_ranked"
            ],
            "type": "string",
            "description": "Order of the hotel list.",
            "default": "best_value"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}