{
  "name": "Automate YP.com directory scraping to Google Sheets using BrowserAct",
  "nodes": [
    {
      "id": "8ad92360-1ee6-44cb-ad18-ff1d898489b0",
      "name": "When clicking ‘Execute workflow’",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -32,
        208
      ]
    },
    {
      "id": "281fdee8-0b6e-4f2d-b811-7376e20c14f2",
      "name": "Run a workflow task",
      "type": "n8n-nodes-browseract-workflows.browserAct",
      "position": [
        144,
        208
      ]
    },
    {
      "id": "35073d60-1922-4fec-a162-de41e3c3a037",
      "name": "Get details of a workflow task",
      "type": "n8n-nodes-browseract-workflows.browserAct",
      "position": [
        352,
        208
      ]
    },
    {
      "id": "6efa3204-54af-4b38-95a7-9996028b6166",
      "name": "Code in JavaScript",
      "type": "n8n-nodes-base.code",
      "position": [
        640,
        208
      ]
    },
    {
      "id": "dc54c1f9-db58-48fd-92c1-45091fd18751",
      "name": "Append or update row in sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        944,
        208
      ]
    },
    {
      "id": "764d9961-c8f2-4b85-a30f-5953edec0645",
      "name": "Sticky Note - Intro",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -640,
        -160
      ],
      "parameters": {
        "width": 592,
        "height": 424,
        "content": "## Try It Out!\n### This n8n template helps you generate local business leads by scraping online directories and saving the results directly to a spreadsheet.\n\n### How it works\n* The workflow is trigge"
      }
    },
    {
      "id": "708ca10f-6d70-4b8d-8a28-4e551509b05f",
      "name": "Sticky Note - How to Use",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -640,
        272
      ],
      "parameters": {
        "width": 592,
        "height": 208,
        "content": "## How to use\n\n1.  **Set up Credentials:** Add your credentials for **BrowserAct** and **Google Sheets** to the workflow.\n2.  **Customize Your Search:** In the **Run a workflow task** node, change the"
      }
    },
    {
      "id": "e66f41b8-e129-4645-a969-fad9b7094770",
      "name": "Sticky Note - Need Help",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -640,
        496
      ],
      "parameters": {
        "width": 336,
        "height": 120,
        "content": "### Need Help?\n* #### [How to Find Your BrowseAct API Key & Workflow ID](https://www.youtube.com/watch?v=pDjoZWEsZlE)\n* #### [How to Connect n8n to Browseract](https://www.youtube.com/watch?v=RoYMdJaR"
      }
    },
    {
      "id": "8ebf7b39-412f-42d1-b230-f5c6344c9e3e",
      "name": "Sticky Note - Scraping Stage",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        96,
        0
      ],
      "parameters": {
        "width": 416,
        "height": 168,
        "content": "### 🌐 1. Scrape & Wait\n\n* **Run a workflow task:** This node starts your BrowserAct scraper. This is where you define what you're searching for (e.g., 'dentists' and 'Brooklyn'). You can easily change"
      }
    },
    {
      "id": "6bfa6f3c-b47f-4e8f-9d2d-8b49eb52a031",
      "name": "Sticky Note - Processing Stage",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        528,
        0
      ],
      "parameters": {
        "width": 336,
        "height": 164,
        "content": "### 🧹 2. Parse & Split Data\n\nThis **Code** node is the most critical processing step. Scrapers often return a list of results as a single block of text (a JSON string). \n\nThis code takes that string, "
      }
    },
    {
      "id": "290deae8-3767-4144-a54b-6eee32210336",
      "name": "Sticky Note - Output Stage",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        880,
        384
      ],
      "parameters": {
        "width": 288,
        "height": null,
        "content": "### 💾 3. Save to Google Sheets\n\nThis node takes each individual business lead and adds it as a new row in your sheet.\n\n**💡 Tip:** The operation is set to `appendOrUpdate` and matches on 'Company Name'"
      }
    },
    {
      "id": "897e4af5-b6c4-43c9-9dec-3ddf5d76aee8",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        96,
        192
      ],
      "parameters": {
        "width": 416,
        "height": 176,
        "content": ""
      }
    },
    {
      "id": "4fa7bfe9-c045-4768-9bb6-9e5331635a50",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        528,
        192
      ],
      "parameters": {
        "width": 336,
        "height": 176,
        "content": ""
      }
    },
    {
      "id": "31b49192-05ad-434b-8770-eb1bc279f607",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        880,
        192
      ],
      "parameters": {
        "width": 288,
        "height": 176,
        "content": ""
      }
    },
    {
      "id": "c36f1e00-e08c-421e-b5c2-4d9f5c5e47f8",
      "name": "Sticky Note - Need Help1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -288,
        496
      ],
      "parameters": {
        "width": null,
        "height": 120,
        "content": "### Workflow Guidance and Showcase\n\n* #### [STOP Manual Leads! Automate Lead Gen with BrowserAct & n8n](https://www.youtube.com/watch?v=W9BHL7vok6c)"
      }
    }
  ],
  "connections": {
    "Code in JavaScript": {
      "main": [
        [
          {
            "node": "Append or update row in sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Run a workflow task": {
      "main": [
        [
          {
            "node": "Get details of a workflow task",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get details of a workflow task": {
      "main": [
        [
          {
            "node": "Code in JavaScript",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Run a workflow task",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}