A: You have the option to apply filters to your Google Maps search results using the following parameters:
- min_rating
- min_reviews
- max_reviews
- has_phone
- has_website
To specify filters, open src/config.py
and specify your filters.
The Following example will scrape only those listings with a minimum of 5 reviews, a maximum of 100 reviews, and a phone number.
queries = [
{
"keyword": "restaurants in delhi",
"min_reviews": 5 ,
"max_reviews": 100,
"has_phone": True,
},
]
To sort your results by reviews, rating, or title, follow these steps:
Open the file src/config.py
and set the sort
key.
For example, to sort by reviews in descending order, modify the code as follows:
queries = [
{
"keyword": "stupas in kathmandu",
"sort": {
"by": "reviews",
"order": "desc",
},
},
]
You can sort by any field, such as reviews
, main_category
, title
, rating
, or any other field. Here are some common sort examples:
- Sort by
reviews
count in descending order:
"sort": {
"by": "reviews",
"order": "desc",
},
- Sort by
main_category
in ascending order:
"sort": {
"by": "main_category",
"order": "asc",
},
- Sort by
title
in ascending order:
"sort": {
"by": "title",
"order": "asc",
},
- Sort by
rating
in descending order:
"sort": {
"by": "rating",
"order": "desc",
},
If you want to select specific fields to be output in your CSV and JSON files, you can do so by following these steps:
- Open
src/config.py
. - Modify the
select
key to include the fields you want to select.
For example, if you want to select "title", "link", "main_category", "rating", "reviews", "website", "phone", and "address", you should adjust the code as follows:
queries = [
{
"keyword": "stupas in kathmandu",
"select": ["title", "link", "main_category", "rating", "reviews", "website", "phone" , "address"],
},
]
You are free to select any field. Here are a couple of common field selections:
- Standard field selection:
"select": ["title", "link", "main_category", "rating", "reviews", "website", "phone" , "address"],
- Selection of all fields (Default):
"select": "ALL",
The Pro Version scrapes the following data points:
- Title
- Link
- Main Category
- Rating
- Reviews
- Website
- Phone
- Address
- Place ID
- Status
- Price Range
- Description
- Reviews per Rating
- Reviews Link
- Thumbnail
- Images
- Hours
- Menu
- Order Online Links
- Reservations
- Owner
- Categories
- Coordinates
- Plus Code
- Complete Address
- Time Zone
- About
- User Reviews
- CID
- Data ID
You can view sample leads scraped by the Pro Version here