{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Scraper",
    "description": "Scrape Google Maps for local business leads: phone, website, emails, social profiles, ratings, and reviews. No API key, no login. Batch keywords × locations in one run, with email and social extraction from each business website.",
    "version": "1.0",
    "x-build-id": "dIo921cmr2ZI7H5Pf"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/labrat011~google-maps-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-labrat011-google-maps-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/labrat011~google-maps-scraper/runs": {
      "post": {
        "operationId": "runs-sync-labrat011-google-maps-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/labrat011~google-maps-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-labrat011-google-maps-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": {
          "keywords": {
            "title": "🔍 Keywords",
            "type": "string",
            "description": "Business type, category, or keyword to search (e.g. 'coffee shops', 'dentists', 'plumbers near me'). Combined with Location to form the search query. Use Keywords List below for batch mode."
          },
          "location": {
            "title": "📍 Location",
            "type": "string",
            "description": "Where to search (e.g. 'Austin, TX', 'London, UK', '10001'). Free text, accepts city, neighborhood, ZIP, or country. Use Locations List below for batch mode. Or use Custom Geolocation below for precise polygon targeting."
          },
          "keywordsList": {
            "title": "📋 Keywords List (Batch Mode)",
            "type": "array",
            "description": "Run many keyword searches in one job. Combined with every entry in Locations List, e.g. ['dentist', 'orthodontist'] × ['Austin, TX', 'Dallas, TX'] = 4 searches, one run. Overrides the single Keywords field when provided.",
            "items": {
              "type": "string"
            }
          },
          "locationsList": {
            "title": "🗺️ Locations List (Batch Mode)",
            "type": "array",
            "description": "Multiple locations to search across in batch mode. Cross-multiplied with Keywords List. Leave empty or pass a single country to search broadly.",
            "items": {
              "type": "string"
            }
          },
          "placeUrls": {
            "title": "🔗 Direct Place URLs",
            "type": "array",
            "description": "Skip search and scrape these Google Maps place URLs directly. Useful when you already have a list of businesses from a previous run, a spreadsheet, or the Places API.",
            "items": {
              "type": "string"
            }
          },
          "customGeolocation": {
            "title": "🌐 Custom Geolocation (GeoJSON)",
            "type": "object",
            "description": "Optional GeoJSON Point or Polygon for precise area targeting. When provided, the scraper searches within the geometry instead of free-text location. Supports { \"type\": \"Point\", \"coordinates\": [lng, lat] } or { \"type\": \"Polygon\", \"coordinates\": [[[lng, lat], ...]] }."
          },
          "language": {
            "title": "🌐 Language",
            "enum": [
              "en",
              "es",
              "fr",
              "de",
              "it",
              "pt",
              "nl",
              "pl",
              "ja",
              "zh-CN",
              "ko",
              "ru",
              "tr",
              "ar"
            ],
            "type": "string",
            "description": "Language code for Google Maps (ISO 639-1). Affects place names, categories, and reviews.",
            "default": "en"
          },
          "countryCode": {
            "title": "🏳️ Country Code",
            "enum": [
              "us",
              "gb",
              "ca",
              "au",
              "de",
              "fr",
              "es",
              "it",
              "nl",
              "br",
              "mx",
              "jp",
              "in",
              "za",
              "ae"
            ],
            "type": "string",
            "description": "Country code for Google Maps regional bias (ISO 3166-1 alpha-2, lowercase).",
            "default": "us"
          },
          "minRating": {
            "title": "⭐ Minimum Rating",
            "enum": [
              "0",
              "3",
              "4",
              "5"
            ],
            "type": "string",
            "description": "Only include places with at least this star rating.",
            "default": "0"
          },
          "includeClosed": {
            "title": "🚫 Include Permanently Closed",
            "type": "boolean",
            "description": "When disabled, skips places marked permanently or temporarily closed on Google Maps.",
            "default": true
          },
          "maxReviewsPerPlace": {
            "title": "💬 Max Reviews per Place",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "How many reviews to extract for each place. Leave at 0 for the fast, cheap run. Any value above 0 makes the actor open every place's detail page, which multiplies runtime and proxy usage. Google ships at most 8 reviews with each place, usually 5, so values above 8 return the same as 8.",
            "default": 0
          },
          "includeReviewSentiment": {
            "title": "📊 Include Review Sentiment",
            "type": "boolean",
            "description": "Adds a simple positive/neutral/negative breakdown based on review star ratings. No LLM cost, adds zero to your bill.",
            "default": true
          },
          "reviewLanguage": {
            "title": "🗣️ Review Language",
            "type": "string",
            "description": "Language code for reviews (ISO 639-1). Leave as 'en' for English.",
            "default": "en"
          },
          "enrichDetails": {
            "title": "📋 Enrich Place Details (Phone, Website, Hours, Images)",
            "type": "boolean",
            "description": "Visit each place's detail page to extract phone number, website, full opening hours, and photos. Adds ~8-10 seconds per place. Disabled by default. Basic results (name, rating, category, address, coordinates) are extracted from the search page without this.",
            "default": false
          },
          "enrichContacts": {
            "title": "📧 Enrich Contacts (Email + Social Profiles)",
            "type": "boolean",
            "description": "When enabled, fetches each place's website and extracts emails, Facebook, Instagram, Twitter/X, LinkedIn, YouTube, TikTok, and Pinterest profile URLs. Cached per unique website within the run.",
            "default": false
          },
          "enrichLinkedIn": {
            "title": "🔗 Enrich with LinkedIn Search URL",
            "type": "boolean",
            "description": "Adds a ready-to-use LinkedIn company search URL to each result. Feed it straight into labrat011/linkedin-jobs-scraper's companyFilter for full lead pipelines. Free.",
            "default": false
          },
          "outputView": {
            "title": "📤 Output View",
            "enum": [
              "places",
              "reviews",
              "leads"
            ],
            "type": "string",
            "description": "Pre-filter results for common use cases. 'places' returns full place records, 'reviews' focuses on review data, 'leads' returns only contact-ready fields.",
            "default": "places"
          },
          "maxResults": {
            "title": "📊 Max Results",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum total places to return across all searches, up to 10,000.",
            "default": 100
          },
          "maxResultsPerSearch": {
            "title": "🔢 Max Results Per Search (Batch Mode)",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Cap per keyword/location combination in batch mode. Example: 3 keywords × 2 locations × 20 per search = up to 120 total results.",
            "default": 100
          },
          "proxyConfiguration": {
            "title": "🔒 Proxy Configuration",
            "type": "object",
            "description": "Proxy settings. RESIDENTIAL is required for reliable browser-based scraping. Do not use GOOGLE_SERP here. It only supports plain HTTP fetching (not HTTPS tunneling) and will fail Playwright navigation.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ],
              "apifyProxyCountry": "US"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}