{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Places Scraper: Businesses, Phones & Websites",
    "description": "Built to beat Google Maps Scraper: 98% of results in the city you asked for (theirs 77%), more places in whole-city runs (339 vs 138 Leeds plumbers), structured addresses, closed and unclaimed flags. $1.00 per 1,000 places vs ~$2.70 there.",
    "version": "0.1",
    "x-build-id": "n59zhIeXYugKlHD1H"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/tidyharvest~google-maps-places-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-tidyharvest-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/tidyharvest~google-maps-places-scraper/runs": {
      "post": {
        "operationId": "runs-sync-tidyharvest-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/tidyharvest~google-maps-places-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-tidyharvest-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": [
          "searches"
        ],
        "properties": {
          "searches": {
            "title": "Searches",
            "type": "array",
            "description": "What you would type into Google Maps, one per line: `coffee shops`, `plumbers`, `wine bars in San Francisco`. For a list of known businesses, one per line as `Name, street, city` (or paste Google Maps place links) and set Max places per search to 1: each line gets its best match, labelled by how well name and street agree, and a line with no confident match comes back as a free `lookupMatch: none` row. With a Location below, write just the category (`coffee shops`).",
            "items": {
              "type": "string"
            }
          },
          "location": {
            "title": "Location (whole-area mode)",
            "type": "string",
            "description": "A city, district or region (`Austin, TX`, `Brooklyn`, `Bruges, Belgium`). Each search then covers the whole area, past Google Maps' ~120-results-per-search limit. Places outside the area's boundary are dropped and not charged."
          },
          "splitArea": {
            "title": "Cover the whole area",
            "type": "boolean",
            "description": "With a Location: keep searching until the whole area is covered or the search budget is used. Off = one search of up to ~120 places centred on the location.",
            "default": true
          },
          "maxCellsPerSearch": {
            "title": "Max Google searches per category (whole-area mode)",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Search budget per category in whole-area mode. The run stops earlier when the area is covered. 60 covers one category in a city of ~100k; raise it for large cities or broad categories like restaurants.",
            "default": 60
          },
          "maxPlacesPerSearch": {
            "title": "Max places per search",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Cap per search. Default 60 for a normal search (Google stops at ~120); no cap in whole-area mode unless you set one. 1 = lookup mode for lists of known businesses (see Searches)."
          },
          "latitude": {
            "title": "Latitude (optional)",
            "type": "number",
            "description": "Center the search here. Use with Longitude and Radius."
          },
          "longitude": {
            "title": "Longitude (optional)",
            "type": "number",
            "description": "Center the search here."
          },
          "radiusMeters": {
            "title": "Radius in meters (optional)",
            "minimum": 100,
            "maximum": 100000,
            "type": "integer",
            "description": "Search area around the coordinates. Default 10,000."
          },
          "strictLocation": {
            "title": "Only places in the area you asked for",
            "type": "boolean",
            "description": "Google sometimes mixes in places from another city with the same name (Glasgow, Delaware for `electricians in Glasgow`) or another country. On: those are dropped and not charged (counted in the run's SUMMARY). Service-area businesses with no public address are kept.",
            "default": true
          },
          "includeContacts": {
            "title": "Find emails and social profiles",
            "type": "boolean",
            "description": "Also read each place's own website for public emails and Instagram, Facebook, TikTok, X, YouTube and LinkedIn links. Add-on: $0.20 per 1,000 places that have a website.",
            "default": false
          },
          "keywords": {
            "title": "Keywords (match any)",
            "type": "array",
            "description": "Keep a place only if its name, categories or description contains one of these.",
            "items": {
              "type": "string"
            }
          },
          "minRating": {
            "title": "Minimum rating",
            "minimum": 0,
            "maximum": 5,
            "type": "number",
            "description": "Keep places rated at least this (0-5)."
          },
          "minReviews": {
            "title": "Minimum reviews",
            "minimum": 0,
            "type": "integer",
            "description": "Keep places with at least this many reviews."
          },
          "requireWebsite": {
            "title": "Only places with a website",
            "type": "boolean",
            "description": "Drop places that list no website.",
            "default": false
          },
          "skipClosedPlaces": {
            "title": "Skip permanently closed places",
            "type": "boolean",
            "description": "Leave out places Google marks as permanently closed (not charged). Off: they are returned with `permanentlyClosed: true`.",
            "default": false
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Result language code, for example `en`, `es`, `de`.",
            "default": "en"
          },
          "country": {
            "title": "Country bias",
            "type": "string",
            "description": "Two-letter country code that biases results, for example `us`, `gb`, `mx`.",
            "default": "us"
          },
          "useApifyProxy": {
            "title": "Use Apify proxy",
            "type": "boolean",
            "description": "Route requests through Apify datacenter proxy. Leave off unless Google refuses the run.",
            "default": false
          },
          "maxItems": {
            "title": "Max places in total",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap on results for the whole run (also caps your cost). 0 or empty = no limit."
          },
          "dedupeAcrossSearches": {
            "title": "Skip places already returned",
            "type": "boolean",
            "description": "Return each place once per run. Turn off when you look up a list of businesses and want one row per input line, even for duplicates.",
            "default": true
          },
          "skipPlaceIds": {
            "title": "Skip places you already have (ids)",
            "type": "array",
            "description": "placeId, fid or cid values to leave out (not charged). For scheduled runs that should return only new places.",
            "items": {
              "type": "string"
            }
          },
          "skipDatasetIds": {
            "title": "Skip places from earlier runs (dataset ids)",
            "type": "array",
            "description": "Dataset ids (or dataset URLs) of earlier runs of this actor: every place in them is skipped and not charged.",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}