Automatizador de captación de clientes: Apify a Google Sheets

Intermedio

Este es unSales, AI, Marketingflujo de automatización del dominio deautomatización que contiene 6 nodos.Utiliza principalmente nodos como Set, Code, HttpRequest, GoogleSheets, ManualTrigger, combinando tecnología de inteligencia artificial para lograr automatización inteligente. Automatización de la captación de prospectos comerciales de Apify a Google Sheets mediante limpieza de datos

Requisitos previos
  • Pueden requerirse credenciales de autenticación para la API de destino
  • Credenciales de API de Google Sheets
Vista previa del flujo de trabajo
Visualización de las conexiones entre nodos, con soporte para zoom y panorámica
Exportar flujo de trabajo
Copie la siguiente configuración JSON en n8n para importar y usar este flujo de trabajo
{
  "id": "8dpOtivR6zGMa8Nf",
  "meta": {
    "instanceId": "2000c64071c20843606b95c63795bb0797c41036047055a6586498e855b96efc",
    "templateCredsSetupCompleted": true
  },
  "name": "Automated Lead Scraper: Apify to Google Sheets",
  "tags": [],
  "nodes": [
    {
      "id": "331e904a-362e-4b18-ac01-60bd138a7ee1",
      "name": "Activador Manual",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -1740,
        -300
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "c8c72d6e-4558-4ab1-9c19-2b8e3cefc856",
      "name": "Ejecutar Apify Scraper",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1280,
        -300
      ],
      "parameters": {
        "url": "={{ 'https://api.apify.com/v2/actor-tasks/' + $json.APIFY_TASK_ID + '/run-sync-get-dataset-items?token=' +$json.APIFY_TOKEN}}",
        "options": {
          "splitIntoItems": true
        }
      },
      "typeVersion": 1
    },
    {
      "id": "fb61d5a9-0352-4079-a00f-c42df06bb09e",
      "name": "Limpiar Datos",
      "type": "n8n-nodes-base.code",
      "position": [
        -1080,
        -300
      ],
      "parameters": {
        "jsCode": "// Clean scraped data before LLM processing\nreturn $input.all().map(item => ({\n  ...item.json,\n  phone: item.json.phone?.replace(/[^\\d+]/g, '') || '',\n  email: item.json.email?.toLowerCase().trim() || ''\n}));"
      },
      "typeVersion": 2
    },
    {
      "id": "a6988139-87e5-423c-bec9-ce155f617dab",
      "name": "Exportar a Hojas de Google",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -760,
        -300
      ],
      "parameters": {
        "columns": {
          "value": {
            "phone": "={{ $json.phone }}",
            "Address": "={{ $json.address }}",
            "company name": "={{ $json.title }}"
          },
          "schema": [
            {
              "id": "company name",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "company name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "website",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "website",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "phone",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "phone",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Address",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Address",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "Sheet1",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1UHkd_OuK1Xzc0ZXo7FPrsd5M1JlsIY9pJDC3fsJ3oq8/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "YOUR_GOOGLE_SHEET_ID",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1UHkd_OuK1Xzc0ZXo7FPrsd5M1JlsIY9pJDC3fsJ3oq8/edit?usp=drivesdk",
          "cachedResultName": "leas list solar"
        }
      },
      "typeVersion": 4.5
    },
    {
      "id": "f4398fd2-bff0-4e9c-ae1b-f5950be0a384",
      "name": "Variables",
      "type": "n8n-nodes-base.set",
      "position": [
        -1500,
        -300
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "4486360c-2296-41ad-a48f-706e24c49a4f",
              "name": "APIFY_TOKEN",
              "type": "string",
              "value": "YOUR_APIFY_API_TOKEN"
            },
            {
              "id": "6e56b0e3-36ae-4f1e-b0e5-38767bbe8af9",
              "name": "APIFY_TASK_ID",
              "type": "string",
              "value": "YOUR_APIFY_TASK_ID"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "04a980cf-365b-4cc3-8439-fd71cb1f05a3",
      "name": "Nota Adhesiva",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1860,
        -820
      ],
      "parameters": {
        "color": 7,
        "width": 1660,
        "height": 780,
        "content": "## Automated Business Lead Scraper with Apify to Google Sheets\n**Purpose:** Automates scraping business leads using Apify, cleaning the data, and exporting them to Google Sheets.\n\n**Workflow Steps:**\n1. **Manual Trigger**: Starts the workflow manually.\n2. **Set API Credentials**: Add your `APIFY_TOKEN` and `APIFY_TASK_ID`.\n3. **Run Apify Scraper**: Fetches leads using Apify HTTP API.\n4. **Clean Data**: Formats phone numbers and emails.\n5. **Export to Google Sheets**: Appends data to your spreadsheet.\n\n**Google Sheet Requirements:**\n- Sheet name: `Sheet1`\n- Columns: `company name`, `phone`, `Address`\n\n**Customization Tips:**\n- Add more fields like `email`, `website` in Clean Data and mapping.\n- Add conditions or filters before exporting.\n- Add email alerts if needed.\n"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "47bf9abd-67aa-49c8-81c9-761e75ee731f",
  "connections": {
    "Start": {
      "main": [
        [
          {
            "node": "f4398fd2-bff0-4e9c-ae1b-f5950be0a384",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "f4398fd2-bff0-4e9c-ae1b-f5950be0a384": {
      "main": [
        [
          {
            "node": "c8c72d6e-4558-4ab1-9c19-2b8e3cefc856",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "fb61d5a9-0352-4079-a00f-c42df06bb09e": {
      "main": [
        [
          {
            "node": "Exportar a Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "c8c72d6e-4558-4ab1-9c19-2b8e3cefc856": {
      "main": [
        [
          {
            "node": "fb61d5a9-0352-4079-a00f-c42df06bb09e",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Preguntas frecuentes

¿Cómo usar este flujo de trabajo?

Copie el código de configuración JSON de arriba, cree un nuevo flujo de trabajo en su instancia de n8n y seleccione "Importar desde JSON", pegue la configuración y luego modifique la configuración de credenciales según sea necesario.

¿En qué escenarios es adecuado este flujo de trabajo?

Intermedio - Ventas, Inteligencia Artificial, Marketing

¿Es de pago?

Este flujo de trabajo es completamente gratuito, puede importarlo y usarlo directamente. Sin embargo, tenga en cuenta que los servicios de terceros utilizados en el flujo de trabajo (como la API de OpenAI) pueden requerir un pago por su cuenta.

Información del flujo de trabajo
Nivel de dificultad
Intermedio
Número de nodos6
Categoría3
Tipos de nodos6
Descripción de la dificultad

Adecuado para usuarios con experiencia intermedia, flujos de trabajo de complejidad media con 6-15 nodos

Autor
David Olusola

David Olusola

@dae221

I love building smart, efficient automations with n8n that help businesses save time and scale effortlessly. Turning complex workflows into simple solutions is where I have the most fun

Enlaces externos
Ver en n8n.io

Compartir este flujo de trabajo

Categorías

Categorías: 34