{
  "openapi": "3.0.1",
  "info": {
    "title": "Tripadvisor Scraper",
    "description": "Tripadvisor scraper and API for hotels, restaurants and things to do. Search a city or paste Tripadvisor links; get each place's rating, review count, ranking, price level, hotel class, hotel prices for your dates, cuisines, address and map position. $0.42 per 1,000 places.",
    "version": "0.1",
    "x-build-id": "EiBZNKj4pl3X6HMuc"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/dami_studio~tripadvisor-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-dami_studio-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/dami_studio~tripadvisor-scraper/runs": {
      "post": {
        "operationId": "runs-sync-dami_studio-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/dami_studio~tripadvisor-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-dami_studio-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": "Places to search",
            "type": "array",
            "description": "A city, region or country, typed the way you would on Tripadvisor: Paris, Rome Italy, Bali. The run takes Tripadvisor's first match for each, and the log says which place that was.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Tripadvisor links",
            "type": "array",
            "description": "Paste a hotels, restaurants or things-to-do list, a city page, or one place's page, from any Tripadvisor country site. A list link reads only that list. A city page or an id such as g187147 reads every kind ticked below. A place's page gives that one place.",
            "items": {
              "type": "string"
            }
          },
          "placeTypes": {
            "title": "What to get for each place searched",
            "type": "array",
            "description": "Hotels, restaurants, things to do, or any mix. Leave all three for everything.",
            "items": {
              "type": "string",
              "enum": [
                "hotels",
                "restaurants",
                "attractions"
              ],
              "enumTitles": [
                "Hotels",
                "Restaurants",
                "Things to do"
              ]
            },
            "default": [
              "hotels",
              "restaurants",
              "attractions"
            ]
          },
          "maxPlacesPerType": {
            "title": "Places of each kind, per search",
            "minimum": 1,
            "maximum": 3000,
            "type": "integer",
            "description": "How many hotels, restaurants and things to do to return for each place searched or list pasted, in Tripadvisor's own order. 30 is one page.",
            "default": 30
          },
          "maxItems": {
            "title": "Total places for the run",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Stops the whole run once this many places are delivered. 0 means no total.",
            "default": 0
          },
          "minRating": {
            "title": "Lowest rating",
            "enum": [
              "any",
              "3",
              "3.5",
              "4",
              "4.5"
            ],
            "type": "string",
            "description": "Leave out places rated below this, on Tripadvisor's 5-bubble scale.",
            "default": "any"
          },
          "hotelClasses": {
            "title": "Hotel class (stars)",
            "type": "array",
            "description": "Keep only hotels of these classes. A hotel Tripadvisor shows no class for is left out when this is set.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "4",
                "5"
              ],
              "enumTitles": [
                "1 star",
                "2 stars",
                "3 stars",
                "4 stars",
                "5 stars"
              ]
            }
          },
          "restaurantPrices": {
            "title": "Restaurant price level",
            "type": "array",
            "description": "Keep only restaurants at these price levels: cheap eats ($), mid-range ($$ - $$$) or fine dining ($$$$).",
            "items": {
              "type": "string",
              "enum": [
                "cheap",
                "mid",
                "fine"
              ],
              "enumTitles": [
                "Cheap eats ($)",
                "Mid-range ($$ - $$$)",
                "Fine dining ($$$$)"
              ]
            }
          },
          "cuisines": {
            "title": "Cuisines",
            "type": "array",
            "description": "Keep only restaurants that list one of these cuisines, written as Tripadvisor names them: Italian, Japanese, Vegan, Seafood.",
            "items": {
              "type": "string"
            }
          },
          "includeDetails": {
            "title": "Place details",
            "type": "boolean",
            "description": "Also open each place's own page to fill what the lists leave empty: the address and map position of things to do, the ranking of restaurants and things to do, and a description where Tripadvisor has one. Slower, and billed as an extra per place whose page was read (see the Pricing tab).",
            "default": false
          },
          "includeSponsored": {
            "title": "Keep sponsored places",
            "type": "boolean",
            "description": "Tripadvisor puts a few paid placements at the top of each page. They are left out unless you tick this; when kept, isSponsored marks them.",
            "default": false
          },
          "checkIn": {
            "title": "Check-in date",
            "type": "string",
            "description": "For hotel prices on your own dates. Without dates, hotels carry Tripadvisor's prices for its default stay, and checkIn and checkOut on each row say which nights those are."
          },
          "checkOut": {
            "title": "Check-out date",
            "type": "string",
            "description": "The morning you leave. Up to 30 nights after check-in."
          },
          "proxyConfiguration": {
            "title": "Connection",
            "type": "object",
            "description": "Optional. Leave as it is unless you want the run to go out through your own proxies.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}