{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Maps Leads & Email Extractor",
    "description": "Extract Google Maps business leads with emails, phone numbers, WhatsApp links and social profiles for a whole city, region or country. Goes past the 120-result limit. Pay only for saved leads and emails found, from $3.50 per 1,000.",
    "version": "1.0",
    "x-build-id": "I3E9ZYQaxUaIbrxHG"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/aimen_ch~google-maps-email-extractor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-aimen_ch-google-maps-email-extractor",
        "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/aimen_ch~google-maps-email-extractor/runs": {
      "post": {
        "operationId": "runs-sync-aimen_ch-google-maps-email-extractor",
        "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/aimen_ch~google-maps-email-extractor/run-sync": {
      "post": {
        "operationId": "run-sync-aimen_ch-google-maps-email-extractor",
        "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",
          "location"
        ],
        "properties": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "One business type per line, without the location (\"dentist\", not \"dentist in Oran\").",
            "items": {
              "type": "string"
            }
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "City, region or country, e.g. \"Austin, Texas\" or \"Oran, Algeria\". Its real boundary is looked up on OpenStreetMap and the whole area is searched."
          },
          "maxResults": {
            "title": "Max new places",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many unique places (0 = no limit). When \"Stop after N leads with email\" is set, the run stops at whichever comes first; set this to 0 to stop on emails only.",
            "default": 500
          },
          "maxEmails": {
            "title": "Stop after N leads with email",
            "minimum": 0,
            "type": "integer",
            "description": "Stop once this many leads have an email (0 = off). Maps searches pause while websites are being checked, so the run doesn't keep searching once it has enough places. Turns on email finding automatically.",
            "default": 0
          },
          "onlyWithEmail": {
            "title": "Only save leads with an email",
            "type": "boolean",
            "description": "Leave out leads where no email was found. You only pay for the leads that are saved, so leads without an email cost nothing. Turns on email finding automatically.",
            "default": false
          },
          "keepInside": {
            "title": "Only keep places inside the location boundary",
            "type": "boolean",
            "description": "Google also shows some results from just outside the searched area. When on, those are dropped.",
            "default": true
          },
          "enrichEmails": {
            "title": "Find emails & social links on websites",
            "type": "boolean",
            "description": "Visits each business website (home + contact/about pages) to find emails, social profiles and WhatsApp links.",
            "default": true
          },
          "countryCode": {
            "title": "Default phone country code",
            "type": "string",
            "description": "Used to turn local numbers (0555…) into international ones (+213555…) and WhatsApp links. Leave empty to use the country of your location."
          },
          "language": {
            "title": "Google Maps language",
            "type": "string",
            "description": "Language code for Google Maps (en, fr, ar…). Keep \"en\" unless you need categories/addresses in another language.",
            "default": "en"
          },
          "searchMethod": {
            "title": "Search method",
            "enum": [
              "http",
              "browser"
            ],
            "type": "string",
            "description": "HTTP: sends Google Maps' own search request directly, no browser. Much cheaper and faster (1 GB memory is enough). Browser: loads real Maps pages; slower and costs more, but keeps working if Google changes the HTTP format. If the HTTP format breaks, the run switches to Browser by itself (see \"Switch to Browser automatically\").",
            "default": "http"
          },
          "autoFallback": {
            "title": "Switch to Browser automatically",
            "type": "boolean",
            "description": "If Google changes the HTTP search format, continue the run with the Browser method instead of failing. Needs at least 2 GB of memory (4 GB recommended); with less, the run stops with a clear message and keeps the leads found so far.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "Proxy for Google Maps",
            "type": "object",
            "description": "Google blocks datacenter IPs quickly. Residential proxies are strongly recommended. Pick the country of your location for the most relevant results.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          },
          "websiteProxyConfiguration": {
            "title": "Proxy for business websites",
            "type": "object",
            "description": "Business websites rarely block scrapers, so by default they are fetched directly (no proxy). Measured: faster and cheaper than going through Apify's datacenter proxy. Turn a proxy on only if many websites fail.",
            "default": {
              "useApifyProxy": false
            }
          },
          "mapsConcurrency": {
            "title": "Parallel Maps searches",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Requests/browsers working at the same time, each on its own proxy IP. Default: 20 for HTTP, 8 for Browser (Browser needs ~1 GB memory per 2–3)."
          },
          "maxSearchesPerMinute": {
            "title": "Max Maps requests per minute",
            "minimum": 1,
            "type": "integer",
            "description": "Overall rate limit across all IPs. Default: 120 for HTTP (each request = 20 results), 60 for Browser (each = one page). Lower it if the log shows many blocked/retried requests."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}