{
  "openapi": "3.0.1",
  "info": {
    "title": "Local Business Scraper for Google - Ratings, Phones & Websites",
    "description": "Scrape Google's local business results by search: name, rating, exact review count, category, address, phone, website, hours, booking link and Google Maps id, plus the owner's description, review quotes and social profiles. 42 countries. Independent tool, not affiliated with Google LLC.",
    "version": "0.1",
    "x-build-id": "ES1MQhdtjWV5v7ABT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapesage~google-local-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapesage-google-local-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/scrapesage~google-local-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapesage-google-local-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/scrapesage~google-local-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapesage-google-local-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": {
          "queries": {
            "title": "Search queries",
            "type": "array",
            "description": "One local search per line, as you would type it into Google - e.g. `dentist in denver co`, `italian restaurant near soho london`, `plumber austin tx`.",
            "items": {
              "type": "string"
            }
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "Optional city or area appended to every query as `... in <location>` when the query does not already name a place."
          },
          "startUrls": {
            "title": "Google Local URLs",
            "type": "array",
            "description": "Optional. Paste Google local-results URLs (google.com/search?q=...&tbm=lcl) or Google Maps search URLs (google.com/maps/search/...). The query, country and language are read from each URL, and a Maps URL's map position is kept. Use the file/link option to import a list.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "urlsFromFile": {
            "title": "Google Local URLs from a file",
            "type": "string",
            "description": "Optional. Either paste a block of Google local-results or Google Maps search URLs (one per line) or a single link to a .txt/.csv file (or a Google Sheet share link) that lists them."
          },
          "countryCode": {
            "title": "Country (gl)",
            "enum": [
              "us",
              "gb",
              "ca",
              "au",
              "nz",
              "ie",
              "in",
              "sg",
              "ae",
              "za",
              "de",
              "fr",
              "es",
              "it",
              "nl",
              "be",
              "ch",
              "at",
              "se",
              "no",
              "dk",
              "fi",
              "pl",
              "pt",
              "br",
              "mx",
              "ar",
              "cl",
              "co",
              "jp",
              "kr",
              "hk",
              "ph",
              "my",
              "id",
              "th",
              "vn",
              "tr",
              "il",
              "eg",
              "ng",
              "ke"
            ],
            "type": "string",
            "description": "Google country edition used for the search. The search starts on this country's map, so pick the country of the place you search (gb for London, de for Berlin).",
            "default": "us"
          },
          "language": {
            "title": "Language (hl)",
            "enum": [
              "en",
              "de",
              "fr",
              "es",
              "it",
              "pt",
              "nl",
              "sv",
              "no",
              "da",
              "fi",
              "pl",
              "tr",
              "ja",
              "ko",
              "id",
              "th",
              "vi",
              "ar",
              "he",
              "hi"
            ],
            "type": "string",
            "description": "Interface language for the search (categories and hours come back in this language).",
            "default": "en"
          },
          "enrichWithDetails": {
            "title": "Add details: description, review quotes, topics & social profiles",
            "type": "boolean",
            "description": "For every business, read its own Google record and its website: the owner's description, review quotes, what reviewers mention most (with counts), the venue it is located in, and social profiles linked from its website. Phone, website, full address, hours, booking link and Google ids come with every row either way. Charged as a separate event, only when a detail was found.",
            "default": true
          },
          "minRating": {
            "title": "Minimum rating",
            "enum": [
              "any",
              "3",
              "3.5",
              "4",
              "4.5"
            ],
            "type": "string",
            "description": "Only keep businesses rated at least this many stars (businesses without a rating are dropped when set).",
            "default": "any"
          },
          "minReviews": {
            "title": "Minimum review count",
            "minimum": 0,
            "type": "integer",
            "description": "Only keep businesses with at least this many Google reviews."
          },
          "includeSponsored": {
            "title": "Include sponsored listings",
            "type": "boolean",
            "description": "Kept so saved inputs keep working. Google's local business data carries no paid placements, so every row is an organic listing and isSponsored is always false.",
            "default": false
          },
          "maxResults": {
            "title": "Maximum businesses",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "Stop after this many businesses across all queries. Google serves 20 per page; a city search usually runs to 10-15 pages."
          },
          "maxPagesPerQuery": {
            "title": "Maximum pages per query",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many result pages (20 businesses each) to read per query.",
            "default": 5
          },
          "monitorMode": {
            "title": "Only new businesses (monitor mode)",
            "type": "boolean",
            "description": "The first run delivers up to Maximum businesses and records every business in each search (up to Maximum pages per query) as seen; later runs deliver only businesses not seen before. Pair with a Schedule to watch a search for businesses that newly appear in it.",
            "default": false
          },
          "monitorStoreName": {
            "title": "Monitor store name",
            "type": "string",
            "description": "Key-value store that keeps the seen business ids (lowercase letters, numbers and dashes).",
            "default": "google-local-monitor"
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 8,
            "type": "integer",
            "description": "How many Google search pages are read at the same time. Business records are read three times as many at a time (up to 24).",
            "default": 4
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}