Use this efficient n8n workflow to generate targeted B2B leads by querying the Google Places API for specific industries and locations, automatically saving rich contact details to a Google Sheet.
Download this n8n workflow template and start using it instantly.
Sales development representatives (SDRs) needing targeted industry lists.
Marketing agencies building outreach campaigns based on geography.
Data analysts looking to map local markets or competition.
Users seeking advanced examples of API handling and pagination within an n8n workflow.
Manually compiling targeted lead lists based on industry and location is time-consuming and often yields inconsistent data. This specialized n8n workflow solves this by utilizing the Google Places API's Text Search feature to rapidly identify relevant businesses and the Place Details API to enrich the results with crucial contact information like phone numbers, addresses, and websites.
Built on robust n8n templates, this automation is designed to handle API pagination limitations—fetching up to three pages of results—and incorporates necessary wait steps to adhere to Google Maps API constraints regarding nextpagetoken activation. The final output is automatically formatted and delivered directly into a structured Google Sheet, providing a clean, ready-to-use B2B lead list. Setting up this n8n workflow is a powerful step towards scalable data acquisition.
The process begins with the Submit Search Query form n8n trigger, where the user inputs the desired industry and location (e.g., 'Plumbers New York').
Has Next Page? (Page 2) n8n node for the existence of a nextpagetoken.Wait 5s (1)). This pause is crucial for allowing the Google Maps API token to activate. It then fetches Text Search Page 2.Has Next Page? (Page 3) n8n node, and if a new token is found, the workflow repeats the wait step and fetches Text Search Page 3.Merge All Pages n8n node. The consolidated results are then broken down into individual business items using the Split out the Results n8n node.Get Place Details n8n node via an HTTP Request, using the unique place_id to retrieve detailed information (website, phone number, formatted address).Format the Output for Google Sheets code n8n node cleans and structures the extracted data, ensuring the fields match the target Google Sheet columns. Finally, the enriched leads are appended to the designated Google Sheet using the Google Sheets n8n node.To deploy this specialized n8n workflow, follow these steps:
Text Search Page 1, Text Search Page 2, Text Search Page 3, and Get Place Details.Append rows in the Google Sheet n8n node. Submit Search Query (Form Trigger): The starting n8n trigger point. It accepts user input for Query (Industry + Location) to initiate the search.
Text Search Page 1/2/3 (HTTP Request): Sends queries to the Google Places Text Search API. These nodes use expressions to pass the user-defined query or the dynamic nextpagetoken for sequential page fetching.
Has Next Page? (If n8n node): Determines the control flow. It checks if the JSON response contains the nextpagetoken field. If true, the workflow proceeds to the waiting and subsequent HTTP Request n8n node.
Wait 5s (1/2) (Wait n8n node): A critical flow control n8n node designed to introduce a 5-second delay. This ensures the nextpagetoken generated by Google Maps API is active before the next API call is made, preventing errors.
Merge All Pages (Merge n8n node): Consolidates the results from the various Text Search pages into a single dataset before processing.
Get Place Details (HTTP Request): Uses the placeid from the search results to call the Place Details API, specifically requesting name, formattedphonenumber, website, and formattedaddress.
Format the Output for Google Sheets (Code n8n node): A JavaScript code n8n node that maps the sometimes nested and verbose API response data into a flat JSON structure suitable for Google Sheets, handling missing fields by assigning null.
Append rows in the Google Sheet (Google Sheets n8n node): The final action node. It authenticates using OAuth and appends the fully formatted B2B lead data as new rows in the specified spreadsheet.
Deploy this advanced n8n workflow to scrape prospect websites using BrightData, identify key pages, and leverage OpenRouter AI to generate synthesized, actionable B2B lead opportunities and pain points.

Use this powerful n8n workflow to generate detailed B2B Ideal Customer Profiles (ICPs) using keyword feature analysis from Implisense and AI. Instantly find and format high-scoring lookalike companies for your CRM.

Generate comprehensive Azure Virtual Machine (VM) timeline and health reports instantly using a powerful n8n workflow powered by Google Gemini AI and custom n8n node tooling.

Automate biblical character vlog creation using this n8n workflow. It leverages GPT-4o for creative ideas, generates cinematic prompts, and creates videos via the Veo3 AI video node.

Generate complex Google BigQuery SQL queries from simple natural language questions using a powerful n8n workflow leveraging GPT-4o and dynamic schema retrieval for secure, robust data access.








































