Automatización de correos electrónicos de bienvenida y envío de códigos de descuento con Mailchimp y Gmail

Intermedio

Este es unSocial Media, Multimodal AIflujo de automatización del dominio deautomatización que contiene 7 nodos.Utiliza principalmente nodos como Gmail, Webhook, Mailchimp. Automatización de correos de bienvenida y envío de códigos de descuento con Mailchimp y Gmail

Requisitos previos
  • Cuenta de Google y credenciales de API de Gmail
  • Punto final de HTTP Webhook (n8n generará automáticamente)
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
{
  "meta": {
    "instanceId": "cbbe3d07d282d90d2165a7ab7800571be416166e6eb660e7a28cfe9b84473f49",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "1363ffcf-aa23-436a-8c53-0a3fbc096cfa",
      "name": "Disparador Webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -352,
        -32
      ],
      "webhookId": "b3d366be-bffc-4d2d-a465-db487976ada0",
      "parameters": {
        "path": "b3d366be-bffc-4d2d-a465-db487976ada0",
        "options": {},
        "httpMethod": "POST",
        "responseMode": "lastNode"
      },
      "typeVersion": 2.1
    },
    {
      "id": "36da0cb5-4135-4289-bfd9-2ceb81aea84a",
      "name": "Crear un miembro",
      "type": "n8n-nodes-base.mailchimp",
      "onError": "continueRegularOutput",
      "position": [
        -128,
        -32
      ],
      "parameters": {
        "list": "YOUR_MAILCHIMP_LIST_ID ",
        "email": "={{ $json.body.email }}",
        "status": "subscribed",
        "options": {},
        "mergeFieldsUi": {
          "mergeFieldsValues": [
            {
              "name": "FNAME",
              "value": "={{ $json.body.name }}"
            }
          ]
        }
      },
      "credentials": {
        "mailchimpApi": {
          "id": "t9AnVp15cqDkacCi",
          "name": "Mailchimp account"
        }
      },
      "retryOnFail": false,
      "typeVersion": 1,
      "alwaysOutputData": false
    },
    {
      "id": "6370189c-3288-4e4a-8c91-cfe831fc96b1",
      "name": "Enviar un mensaje",
      "type": "n8n-nodes-base.gmail",
      "position": [
        96,
        -32
      ],
      "webhookId": "c28c4c93-f099-407e-aec7-dcb7ca5c7fb7",
      "parameters": {
        "sendTo": "={{ $('Webhook').item.json.body.email }}",
        "message": "=<!DOCTYPE html> <html> <body style=\"font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;\">     <div style=\"background-color: #f8f9fa; padding: 20px; text-align: center;\">         <h1 style=\"color: #333;\">Welcome to [Your Business Name]!</h1>                  <p style=\"font-size: 18px; color: #666;\">             Hi {{ $node[\"Webhook\"].json[\"name\"] || \"there\" }},         </p>                  <p style=\"font-size: 16px; color: #666; line-height: 1.6;\">             Thank you for joining our community! We're excited to have you on board.         </p>                  <div style=\"background-color: #007bff; color: white; padding: 20px; margin: 20px 0; border-radius: 8px;\">             <h2 style=\"margin: 0;\">Your Welcome Gift!</h2>             <p style=\"font-size: 24px; font-weight: bold; margin: 10px 0;\">                 WELCOME15             </p>             <p style=\"margin: 0;\">Use this code for 15% off your first order</p>         </div>                  <a href=\"https://your-website.com/shop\"             style=\"background-color: #28a745; color: white; padding: 15px 30px;                    text-decoration: none; border-radius: 5px; display: inline-block;                    margin: 20px 0;\">             Start Shopping         </a>                  <p style=\"font-size: 14px; color: #999; margin-top: 30px;\">             Follow us on social media for the latest updates and offers!         </p>                  <div style=\"margin-top: 20px;\">             <a href=\"https://facebook.com/yourpage\" style=\"margin: 0 10px;\">Facebook</a>             <a href=\"https://instagram.com/yourpage\" style=\"margin: 0 10px;\">Instagram</a>             <a href=\"https://twitter.com/yourpage\" style=\"margin: 0 10px;\">Twitter</a>         </div>     </div> </body> </html>",
        "options": {},
        "subject": "Welcome to Berley! Here's your 15% discount 🎉"
      },
      "credentials": {
        "gmailOAuth2": {
          "id": "VI8hpbWunRMMvR6a",
          "name": "Gmail account"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "36131d9d-d138-4955-ae74-40b765851aef",
      "name": "Nota adhesiva",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -864,
        -240
      ],
      "parameters": {
        "width": 304,
        "height": 1136,
        "content": "## 📧 Automated Welcome Email with Discount Code\n\n### 🎯 What This Does\nAutomatically nurtures new subscribers with personalized welcome emails and discount codes:\n  - **Instant response** to website signup forms via webhook\n  - **Mailchimp integration** adds contacts to your email list\n  - **Branded welcome email** with personalized discount code\n  - **Error handling** ensures emails send even if list addition fails\n\n### ⚡ How It Works\n  1. Website form submits data to webhook endpoint\n  2. Contact automatically added to Mailchimp audience\n  3. Personalized welcome email sent via Gmail\n  4. Subscriber gets immediate value with discount code\n\n### 🛠️ Setup Required\n**Before using this workflow:**\n  1. Replace YOUR_MAILCHIMP_LIST_ID with your actual Mailchimp list ID\n  2. Update email template with your business name and branding\n  3. Change discount code and shop URL to your own\n  4. Add your website form endpoint to trigger the webhook\n  5. Configure Mailchimp and Gmail credentials\n\n### 💡 Perfect For\n  - E-commerce businesses building customer lists\n  - SaaS companies onboarding trial users\n  - Course creators nurturing leads\n  - Service providers automating client intake"
      },
      "typeVersion": 1
    },
    {
      "id": "244bd91b-1dc0-4b0c-8771-4c7da2ebf0f9",
      "name": "Nota adhesiva1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -448,
        -192
      ],
      "parameters": {
        "color": 6,
        "height": 336,
        "content": "#### Step 1: Receive Signup Data\n\nWebhook receives form submissions from your website."
      },
      "typeVersion": 1
    },
    {
      "id": "6768e505-ed3e-4462-8fc3-2825580d9cbc",
      "name": "Nota adhesiva2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -192,
        -192
      ],
      "parameters": {
        "color": 3,
        "height": 336,
        "content": "#### Step 2: Add to Email List\n\nAutomatically adds subscriber to your Mailchimp audience."
      },
      "typeVersion": 1
    },
    {
      "id": "de85be05-732e-4ab9-b12f-5c35dee75a96",
      "name": "Nota adhesiva3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        64,
        -192
      ],
      "parameters": {
        "color": 4,
        "height": 336,
        "content": "#### Step 3: Send Welcome Email\n\nSends branded welcome email with personalized discount code."
      },
      "typeVersion": 1
    }
  ],
  "pinData": {
    "Webhook": [
      {
        "body": {
          "name": "Bideen",
          "email": "abideen.datascienceofficial@gmail.com",
          "source": "website",
          "timestamp": "2025-08-23T20:12:07.935Z"
        },
        "query": {},
        "params": {},
        "headers": {
          "host": "primary-production-a4a8.up.railway.app",
          "accept": "*/*",
          "origin": "https://a7b923f7-55b0-4612-98a3-bec7fe294375.sandbox.lovable.dev",
          "referer": "https://a7b923f7-55b0-4612-98a3-bec7fe294375.sandbox.lovable.dev/",
          "priority": "u=1, i",
          "sec-ch-ua": "\"Not;A=Brand\";v=\"99\", \"Microsoft Edge\";v=\"139\", \"Chromium\";v=\"139\"",
          "x-real-ip": "102.88.52.28",
          "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/139.0.0.0 Safari/537.36 Edg/139.0.0.0",
          "content-type": "application/json",
          "content-length": "123",
          "sec-fetch-dest": "empty",
          "sec-fetch-mode": "cors",
          "sec-fetch-site": "cross-site",
          "x-railway-edge": "railway/europe-west4-drams3a",
          "accept-encoding": "gzip, deflate, br, zstd",
          "accept-language": "en-US,en;q=0.9,en-GB;q=0.8",
          "x-forwarded-for": "102.88.52.28",
          "x-request-start": "1755979928499",
          "sec-ch-ua-mobile": "?0",
          "x-forwarded-host": "primary-production-a4a8.up.railway.app",
          "x-forwarded-proto": "https",
          "sec-ch-ua-platform": "\"Windows\"",
          "x-railway-request-id": "NJw37UqQQF-nnduU5nX1uw"
        },
        "webhookUrl": "https://primary-production-a4a8.up.railway.app/webhook-test/b3d366be-bffc-4d2d-a465-db487976ada0",
        "executionMode": "test"
      }
    ]
  },
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "36da0cb5-4135-4289-bfd9-2ceb81aea84a",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "36da0cb5-4135-4289-bfd9-2ceb81aea84a": {
      "main": [
        [
          {
            "node": "6370189c-3288-4e4a-8c91-cfe831fc96b1",
            "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 - Redes sociales, IA Multimodal

¿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 nodos7
Categoría2
Tipos de nodos4
Descripción de la dificultad

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

Autor
Abideen Bello

Abideen Bello

@bideen

Data/Automation consultant with experience helping Sales & Marketing teams to streamline their processes. Use my link to book an initial consultation for custom n8n work.

Enlaces externos
Ver en n8n.io

Compartir este flujo de trabajo

Categorías

Categorías: 34