{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Scraper By Radius & GeoJSON Territory",
    "description": "Automate Google Maps scraping to power your internal tools. Whether for targeting, analysis, or reporting, this actor gives you clean, reliable business data with no API limitations or UI restrictions.",
    "version": "0.1",
    "x-build-id": "uoyCZ3YFvgupzpe8o"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/simpleapi~google-maps-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-simpleapi-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/simpleapi~google-maps-scraper/runs": {
      "post": {
        "operationId": "runs-sync-simpleapi-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/simpleapi~google-maps-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-simpleapi-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",
        "required": [
          "keywords"
        ],
        "properties": {
          "keywords": {
            "title": "🔎 What to find (keywords)",
            "type": "array",
            "description": "☕ Business types or search terms — e.g. *coffee shops*, *dentists*, *car dealerships*. 📝 Add many keywords to multiply your searches. Example: [\"coffee shops\", \"cafes\"].",
            "items": {
              "type": "string"
            }
          },
          "coordinates": {
            "title": "🧭 Center coordinates (lat,lng)",
            "type": "string",
            "description": "📌 Latitude,longitude pair used as the search center instead of a named location — e.g. \"29.7604,-95.3698\" for Houston. 📏 Pair it with the radius below; results outside the radius are filtered out. Leave blank to use locations/GeoJSON/postal instead."
          },
          "radius": {
            "title": "📏 Search radius (miles)",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "📐 How far around the center coordinates (or a GeoJSON Point) to search — tight for a neighborhood, wide for a metro sweep. Places farther than this are dropped. Example: radius=5 keeps only places within 5 miles. Default is 5. Used only when coordinates or a GeoJSON Point are set.",
            "default": 5
          },
          "customGeolocation": {
            "title": "🗺️ Custom GeoJSON territory",
            "type": "object",
            "description": "🧩 Define the exact search area as a GeoJSON geometry — Point, Polygon, or MultiPolygon (Feature/FeatureCollection also accepted). Every scraped place is point-in-polygon tested; only places INSIDE the shape are kept (within_territory=true). Overrides coordinates and locations when set. Example: {\"type\":\"Polygon\",\"coordinates\":[[[-95.40,29.74],[-95.34,29.74],[-95.34,29.78],[-95.40,29.78],[-95.40,29.74]]]} (GeoJSON is [lng,lat])."
          },
          "postalCode": {
            "title": "🏤 Postal / ZIP code",
            "type": "string",
            "description": "📮 Scrape one postal/ZIP code area — combine with a country or city in the locations field for unambiguous targeting (one code per run). Example: postalCode=\"77002\" with locations=[\"USA\"]. Leave blank to skip."
          },
          "locations": {
            "title": "📍 Cities, regions, or neighborhoods",
            "type": "array",
            "description": "🏙️ Examples: *New York*, *Texas*, *Downtown Chicago*. Also used as the country/city hint for the postal code above. Optional.",
            "items": {
              "type": "string"
            }
          },
          "urls": {
            "title": "🔗 Optional: Google Maps links",
            "type": "array",
            "description": "🌐 Bulk-friendly list of Google Maps search links (with @lat,lng or /search/ query). ✨ Great when you've bookmarked exact searches. Optional.",
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "🎯 How many places to collect",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "🔢 Total unique places (deduped by place_id) across all geo jobs, locations, keywords, and URLs. ✨ Default is friendly for quick tests; raise it for big territory sweeps.",
            "default": 20
          },
          "proxyConfiguration": {
            "title": "🌐 Connection & reliability",
            "type": "object",
            "description": "🎛️ Optional Apify Proxy — leave off for simple runs; turn on for heavier jobs or picky networks. On block the Actor auto-steps direct → datacenter → residential (sticky)."
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}