{
  "nodes": [
    {
      "id": "dc30089e-2dea-4cba-ae74-f043240b5176",
      "name": "Google Gemini Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
      "position": [
        -40,
        1560
      ],
      "parameters": {
        "options": {},
        "modelName": "models/gemini-2.5-flash-preview-05-20"
      },
      "typeVersion": 1
    },
    {
      "id": "27d02a47-659e-4b6a-8c5f-50253fc5be1c",
      "name": "Simple Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        820,
        1620
      ],
      "parameters": {
        "sessionKey": "={ { $execution.id } }",
        "sessionIdType": "customKey"
      },
      "typeVersion": 1.3
    },
    {
      "id": "b791c4dd-bdc8-4d38-a301-ababb9ff129f",
      "name": "brave_web_search",
      "type": "n8n-nodes-mcp.mcpClientTool",
      "position": [
        1160,
        1300
      ],
      "parameters": {
        "toolName": "brave_web_search",
        "operation": "executeTool",
        "connectionType": "http",
        "toolParameters": "={ { /*n8n-auto-generated-fromAI-override*/ $fromAI('Tool_Parameters', `Generate a JSON object with the parameters for the 'brave_web_search' tool.\nThe tool expects a JSON object with the following keys:\n- \"query\": (string, **required**) The search terms designed to find multiple examples of a business type in a given area. Examples: \"list of crane hire companies in Newcastle NSW\", \"artisan bakeries Sydney CBD reviews\", \"marketing agencies California specializing in tech startups\".\n- \"count\": (number, optional) Number of results. For prospect discovery, a higher count (e.g., 10-20) might be useful to cast a wider net.\n- \"offset\": (number, optional) For pagination if analyzing multiple pages of results.\n\nExample:\n{\"query\": \"top rated plumbing services in Bristol UK\", \"count\": 15}`, 'json') } }",
        "descriptionType": "manual",
        "toolDescription": "Performs a general web search using Brave Search. Primarily used to find lists, directories, articles, or multiple mentions of businesses matching a specified type and location. The goal is to identify several potential prospect company names and their websites, not just one official site. Effective for initial broad sweeps to gather candidate businesses. Parameters: 'query' (required string), 'count' (optional number, max 20), 'offset' (optional number)."
      },
      "typeVersion": 1
    },
    {
      "id": "d33f89c7-ed40-427e-9f2c-b699194e860e",
      "name": "brave_local_search",
      "type": "n8n-nodes-mcp.mcpClientTool",
      "position": [
        1720,
        1300
      ],
      "parameters": {
        "toolName": "brave_local_search",
        "operation": "executeTool",
        "connectionType": "http",
        "toolParameters": "={ { /*n8n-auto-generated-fromAI-override*/ $fromAI('Tool_Parameters', `Generate a JSON object with the parameters for the 'brave_local_search' tool.\nThe tool expects a JSON object with the following keys:\n- \"query\": (string, **required**) The search terms, typically a specific business name and its suspected city/area, to get a quick local listing check. Example: \"ABC Cranes Newcastle\", \"The Corner Bakery Springfield\".\n- \"count\": (number, optional) Usually 1 or a small number (e.g., 3) is sufficient, as you're checking a specific entity.\n\nExample:\n{\"query\": \"Summit Logistics, Dallas TX\", \"count\": 1}`, 'json') } }",
        "descriptionType": "manual",
        "toolDescription": "Searches for local business listings using Brave Local Search. In prospect discovery, this tool can be used sparingly to quickly verify if a business name found through broader searches has a local presence or to find a website URL if it's not immediately apparent from web search results. Not the primary tool for initial discovery of types, but useful for quick validation of individual potential prospects from a list. Parameters: 'query' (required string), 'count' (optional number, usually 1-3 for this purpose)."
      },
      "typeVersion": 1
    },
    {
      "id": "d2cd00e1-bb22-4a6d-a7c5-bcf299883396",
      "name": "jina_ai_web_page_scraper",
      "type": "n8n-nodes-base.jinaAiTool",
      "position": [
        2880,
        1300
      ],
      "parameters": {
        "url": "={ { /*n8n-auto-generated-fromAI-override*/ $fromAI('URL', `Provide the full URL of a potential prospect's homepage or 'About Us' page. Use this only if you need to quickly verify from the website's text if the business matches the desired type before finalizing it as a prospect. Example: 'https://potentialprospect.com/about'.`, 'string') } }",
        "options": {
          "outputFormat": "markdown",
          "enableImageCaptioning": true
        },
        "requestOptions": {},
        "descriptionType": "manual",
        "toolDescription": "Extracts main textual content from a given web page URL. In prospect discovery, use this very selectively and sparingly. If a promising business website is found but it's unclear if they are the correct business type, a quick scrape of their homepage or 'About Us' page can help confirm relevance before adding them to the prospect list. Not for deep information extraction at this stage. Parameter: 'url' (required string). Critical: Use for 1-2 URLs max for quick validation if needed, due to time limits."
      },
      "typeVersion": 1
    },
    {
      "id": "71869bea-8ed4-4aa6-a8d3-6a19be1af7e8",
      "name": "prospect_discovery",
      "type": "@n8n/n8n-nodes-langchain.mcpTrigger",
      "position": [
        -220,
        -80
      ],
      "parameters": {
        "path": "5de5d0b6-7f58-47df-8d2c-4096f61212c8"
      },
      "typeVersion": 1
    },
    {
      "id": "d54d6483-54bc-45b3-9a2b-05767176aa08",
      "name": "prospect_discovery_workflow",
      "type": "n8n-nodes-base.executeWorkflowTrigger",
      "position": [
        -500,
        1180
      ],
      "parameters": {
        "workflowInputs": {
          "values": [
            {
              "name": "business_type"
            },
            {
              "name": "location_query"
            },
            {
              "name": "desired_num_prospects"
            },
            {
              "name": "additional_keywords"
            }
          ]
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "2b29393a-1ffe-494c-9ab3-803da13efbc9",
      "name": "prospect_discovery_agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        240,
        1180
      ],
      "parameters": {
        "text": "=Based on the provided business type, location, desired number of prospects, and any additional keywords, identify a list of potential business prospects including their names and website URLs.\nbusiness_type: { { $('prospect_discovery_workflow').item.json.business_type || 'Not specified' } }\nlocation_query: { { $('prospect_discovery_workflow').item.json.location_query || 'Not specified' } }\ndesired_num_prospects: { { Number($('prospect_discovery_workflow').item.json.desired_num_prospects) || 1 } }\nadditional_keywords: { { $('prospect_discovery_workflow').item.json.additional_keywords || 'None' } }",
        "options": {
          "systemMessage": "=You are an AI Prospecting Specialist. Your mission is to identify a specified number of potential business prospects. For EACH prospect you identify, you must gather key details including their official name, website URL, a brief description of their services, a key contact person/owner (if discoverable), and a business phone number (if discoverable). This process is guided by the `business_type`, `location_query`, `desired_num_prospects`, and optional `additional_keywords` you receive. Your final output must be a structured JSON array of these detailed prospect profiles."
        },
        "promptType": "define"
      },
      "typeVersion": 2
    }
  ],
  "connections": {
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "brave_web_search": {
      "ai_tool": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "discover_prospect": {
      "ai_tool": [
        [
          {
            "node": "prospect_discovery",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "brave_local_search": {
      "ai_tool": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Google Gemini Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "jina_ai_web_page_scraper": {
      "ai_tool": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "prospect_discovery_workflow": {
      "main": [
        [
          {
            "node": "prospect_discovery_agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}