{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Scraper: Places, Emails and Leads",
    "description": "Google Maps scraper for local business leads: search a category in a city and get every place inside its real boundary, with phone, website, address, coordinates, rating, review count, opening hours and, optionally, emails and social profiles from each website, at one price per place.",
    "version": "0.1",
    "x-build-id": "4evcbE5KBR1NY9WBF"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/agenttoolworks~google-maps-places-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-agenttoolworks-google-maps-places-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/agenttoolworks~google-maps-places-scraper/runs": {
      "post": {
        "operationId": "runs-sync-agenttoolworks-google-maps-places-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/agenttoolworks~google-maps-places-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-agenttoolworks-google-maps-places-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",
        "required": [
          "searchTerms"
        ],
        "properties": {
          "searchTerms": {
            "title": "Search terms",
            "type": "array",
            "description": "What to look for, as you would type it in Google Maps: a category or a keyword (dentist, restaurant, plumber, coworking). Each term is searched in each location.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "Locations",
            "type": "array",
            "description": "Cities, regions or postcodes, one per line (Lyon, France; Brooklyn, New York; 75011 Paris). Each is resolved to its real boundary on OpenStreetMap, and only places inside it are returned and charged. City plus country works best.",
            "items": {
              "type": "string"
            }
          },
          "maxPlacesPerSearch": {
            "title": "Max places per search",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Stop after this many places for each search term in each location. You are charged per place returned, never more than this, never twice for the same place in a run. Google shows about 120 places per map view; the Actor splits the area into smaller views to go further.",
            "default": 100
          },
          "scrapeContacts": {
            "title": "Emails and social profiles from websites",
            "type": "boolean",
            "description": "Reads each place's own website (the homepage, then up to three contact or imprint pages it links if the homepage shows no email) for emails and links to Facebook, Instagram, LinkedIn, X, YouTube, TikTok and Pinterest. Same price per place, no add-on. Each row says whether the site was read (contactsStatus) so an empty email column is explained.",
            "default": false
          },
          "strictBoundary": {
            "title": "Only places inside the area",
            "type": "boolean",
            "description": "Google pads results with places nearby. On (recommended), places outside the location's boundary are dropped before they are charged.",
            "default": true
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Language of categories, opening hours and status lines (en, fr, de, es, pt-br...). Names and addresses stay as their owners wrote them.",
            "default": "en"
          },
          "skipClosedPlaces": {
            "title": "Skip closed places",
            "type": "boolean",
            "description": "Drop places Google marks as permanently or temporarily closed. Free: dropped places are not charged.",
            "default": false
          },
          "minRating": {
            "title": "Minimum rating",
            "minimum": 1,
            "maximum": 5,
            "type": "number",
            "description": "Keep only places rated at least this (1 to 5). Unrated places are dropped when this is set."
          },
          "requireWebsite": {
            "title": "Only places with a website",
            "type": "boolean",
            "description": "Keep only places that list a website. Free: dropped places are not charged.",
            "default": false
          },
          "requirePhone": {
            "title": "Only places with a phone number",
            "type": "boolean",
            "description": "Keep only places that list a phone number. Free: dropped places are not charged.",
            "default": false
          },
          "categoryFilterWords": {
            "title": "Category must contain",
            "type": "array",
            "description": "Keep a place only if one of its Google categories contains one of these words (case-insensitive). Use it to drop off-topic results, for example dent for a dentist search.",
            "items": {
              "type": "string"
            }
          },
          "customGeolocation": {
            "title": "Custom area (GeoJSON)",
            "type": "object",
            "description": "An exact area instead of, or in addition to, the locations: a Polygon, a MultiPolygon, a Feature or FeatureCollection, or a Point with radiusKm ({\"type\": \"Point\", \"coordinates\": [4.8357, 45.764], \"radiusKm\": 2}). Coordinates are [longitude, latitude], as GeoJSON editors export them."
          },
          "proxy": {
            "title": "Proxy",
            "enum": [
              "residential",
              "datacenter",
              "none"
            ],
            "type": "string",
            "description": "Where Google's requests leave from. residential (default): Google answers in full. datacenter: cheaper for us, but Google caps some datacenter IPs at about 20 places per map view, so dense areas can come back with fewer places (the Actor retries from other IPs, drops capped ones, and marks the search partial with the reason when capped views remain). Business websites always go through datacenter when a proxy is on. none uses the run's own address.",
            "default": "residential"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}