8
n8n 中文网amn8n.com

我的工作流79

高级

这是一个Social Media领域的自动化工作流,包含 34 个节点。主要使用 If, Set, Wait, Filter, HttpRequest 等节点。 使用Google Sheets和MailerSend构建完整的电子邮件CRM系统

前置要求
  • 可能需要目标 API 的认证凭证
  • Google Sheets API 凭证
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "id": "rzzP4NRN7TiPJkMJ",
  "meta": {
    "instanceId": "c24388df44432e8ff2c4acecd7ab0dd2faec628bd83c70beb384cea105f7a50a"
  },
  "name": "我的工作流 79",
  "tags": [],
  "nodes": [
    {
      "id": "956055e1-996a-4adc-9b04-933c0f8adfac",
      "name": "计划触发器",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -200,
        160
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "triggerAtHour": 10
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "a7964cef-e8bc-4b59-8f4e-47a7396c5877",
      "name": "设置流程",
      "type": "n8n-nodes-base.set",
      "position": [
        20,
        160
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "d309aa70-6566-4caf-b195-343a439005a8",
              "name": "flow_id",
              "type": "number",
              "value": 3
            }
          ]
        }
      },
      "retryOnFail": false,
      "typeVersion": 3.4
    },
    {
      "id": "bdcdfb37-6e24-4b08-b665-570575a7770a",
      "name": "映射数据",
      "type": "n8n-nodes-base.set",
      "position": [
        -140,
        460
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "a859ab5d-72db-499b-916f-c86056d2e8e5",
              "name": "user_id",
              "type": "string",
              "value": "={{ $json.user_id }}"
            },
            {
              "id": "a08c6a8f-d449-419c-8137-97ff7da25eb9",
              "name": "database_id",
              "type": "string",
              "value": "={{ $('IF Template Parameters OK').item.json.database_id }}"
            },
            {
              "id": "68feb703-6295-4181-a9d4-f30891a5ea1d",
              "name": "type",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.type }}"
            },
            {
              "id": "82eaab08-abd6-45a2-a1f0-a1f4388064c1",
              "name": "template_name",
              "type": "string",
              "value": "={{ $('IF Template Parameters OK').item.json.template_name }}"
            },
            {
              "id": "c598ef15-d75d-48d6-aa95-9ca9d951293c",
              "name": "type_template_id",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.type_template_id }}"
            },
            {
              "id": "82a53708-84f8-4ef1-a97a-421ca0926f38",
              "name": "template_id",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.Id }}"
            },
            {
              "id": "1ca0c8d6-0b7f-4786-9deb-c154d624e691",
              "name": "email",
              "type": "string",
              "value": "={{ $json.email }}"
            },
            {
              "id": "ccab5936-05fc-48c8-8b2c-fa33becb3983",
              "name": "first_name",
              "type": "string",
              "value": "={{ $json.first_name }}"
            },
            {
              "id": "598822c7-e5f5-4317-8e89-5ba751347dbd",
              "name": "discount_code",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.discount_code }}"
            },
            {
              "id": "a6d160b6-009c-43ce-a0bc-80e6db1691bc",
              "name": "gift_code",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.gift_code }}"
            },
            {
              "id": "3418ee65-fb37-4b7a-a97a-41ed2d62f97c",
              "name": "journey",
              "type": "string",
              "value": "={{ $('Filter Template').item.json.journey }}"
            },
            {
              "id": "bbecf918-f856-4750-96ce-e94c9a6c7dd1",
              "name": "number",
              "type": "string",
              "value": "={{ $json.number }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "18e97315-1c69-420a-9849-589914b40f65",
      "name": "筛选模板",
      "type": "n8n-nodes-base.filter",
      "position": [
        440,
        160
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "0ec67f9e-14e1-4581-be9f-1cccf1e07c89",
              "operator": {
                "type": "number",
                "operation": "equals"
              },
              "leftValue": "={{ $('Setup Flow').item.json.flow_id }}",
              "rightValue": "={{ $json.Id }}"
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "c0795f4f-7588-422a-b783-f9718ac640df",
      "name": "如果模板参数正常",
      "type": "n8n-nodes-base.if",
      "position": [
        680,
        160
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "cb609e58-4b53-45ce-b8b7-878bb66ec21c",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.template_name }}",
              "rightValue": ""
            },
            {
              "id": "bb59523e-94fb-4db1-9218-5cd1bd95f644",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.database_id }}",
              "rightValue": ""
            },
            {
              "id": "d7d05f35-503a-4211-a343-021462f8a798",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.type }}",
              "rightValue": ""
            },
            {
              "id": "71520d2f-c23f-424b-a6fd-7d84a492d499",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.type_template_id }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "7d9fa178-95e5-417d-9321-ebb6f903afaa",
      "name": "如果 user_id 不为空",
      "type": "n8n-nodes-base.if",
      "position": [
        1120,
        240
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "3807b703-6ebf-46a7-877c-bf7b10c23da8",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.user_id }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "eea2dd6c-2cec-47a5-ba0e-e49cbeb38280",
      "name": "等待",
      "type": "n8n-nodes-base.wait",
      "position": [
        440,
        560
      ],
      "webhookId": "5704f00a-d80d-42d4-a812-4e40eeac8a1e",
      "parameters": {
        "amount": 1
      },
      "typeVersion": 1.1
    },
    {
      "id": "a07ff8e2-b738-4e2a-9a0b-ac501d03eeda",
      "name": "移除重复项",
      "type": "n8n-nodes-base.removeDuplicates",
      "position": [
        900,
        660
      ],
      "parameters": {
        "compare": "selectedFields",
        "options": {},
        "fieldsToCompare": "user_id"
      },
      "typeVersion": 2
    },
    {
      "id": "3881117a-f258-4efe-9c81-ac40e9fe9b4a",
      "name": "如果类型为邮件",
      "type": "n8n-nodes-base.if",
      "position": [
        1980,
        460
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "da42108f-7501-4028-8cfe-a91bf73e081d",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.type }}",
              "rightValue": "email"
            },
            {
              "id": "d267dd9d-7695-4093-aea6-8bd93f58c460",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "{{ $json.user_id}}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "aaf86910-cbf0-4abc-9f44-e855930077fe",
      "name": "计划触发器1",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        1580,
        460
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "hours"
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "0b5c4da8-a9eb-4b91-8b5d-abdf46553f01",
      "name": "便签",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1760,
        -80
      ],
      "parameters": {
        "color": 5,
        "width": 720,
        "height": 1040,
        "content": "# 描述"
      },
      "typeVersion": 1
    },
    {
      "id": "f9c24ac3-1218-49c3-a548-76e0d6d97523",
      "name": "便签1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        820,
        880
      ],
      "parameters": {
        "color": 4,
        "width": 460,
        "height": 460,
        "content": "## transaction"
      },
      "typeVersion": 1
    },
    {
      "id": "1ed6e59c-b643-4d80-9c00-79f537d3c05a",
      "name": "便签2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -40,
        880
      ],
      "parameters": {
        "color": 4,
        "width": 840,
        "height": 200,
        "content": "## template"
      },
      "typeVersion": 1
    },
    {
      "id": "cf47bec3-465f-4d14-bbdf-683d5cb7f6c2",
      "name": "便签3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        360,
        1100
      ],
      "parameters": {
        "color": 4,
        "width": 440,
        "height": 220,
        "content": "## segment1"
      },
      "typeVersion": 1
    },
    {
      "id": "c74bf344-3943-4a47-941e-9aa083715cf1",
      "name": "便签4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -40,
        1100
      ],
      "parameters": {
        "color": 4,
        "width": 380,
        "height": 220,
        "content": "# 数据库示例📋"
      },
      "typeVersion": 1
    },
    {
      "id": "68522da8-5016-443d-9ff7-3fb5b6cb3d6b",
      "name": "便签5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1020,
        -80
      ],
      "parameters": {
        "color": 5,
        "width": 720,
        "height": 1300,
        "content": "# 📌 逐节点描述 (MailerSend eCRM)"
      },
      "typeVersion": 1
    },
    {
      "id": "fd666783-f039-49cb-9158-e64f0424b0ec",
      "name": "如果邮箱不为空",
      "type": "n8n-nodes-base.if",
      "position": [
        2240,
        380
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "3df05c9a-ebe6-4126-9143-2b24066fde58",
              "operator": {
                "type": "string",
                "operation": "notEmpty",
                "singleValue": true
              },
              "leftValue": "={{ $json.email }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "588eb175-9d20-482a-947b-d49c6b1511ef",
      "name": "便签6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -280,
        20
      ],
      "parameters": {
        "color": 3,
        "width": 340,
        "height": 80,
        "content": "# 📝 插入 user_id"
      },
      "typeVersion": 1
    },
    {
      "id": "2359c11c-fecc-4ea4-9d16-14902a3a3cf1",
      "name": "便签7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1420,
        80
      ],
      "parameters": {
        "color": 3,
        "width": 340,
        "height": 80,
        "content": "# ✉️ 发送邮件"
      },
      "typeVersion": 1
    },
    {
      "id": "9d1dc07c-4f18-4524-923d-a1044bae5faa",
      "name": "临时邮箱检查",
      "type": "n8n-nodes-base.if",
      "position": [
        2460,
        300
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "e5fd1b3e-9575-4bfa-ae7a-fe65943fbebc",
              "operator": {
                "type": "string",
                "operation": "notRegex"
              },
              "leftValue": "{{ $json.email }}",
              "rightValue": ".*(temp|abc|1234|yopmail|protonmail|mailinator|\\.cc|bigbester|fake|spam|gdf|sdf|mr123|passinbox|landininbox|@inbox|random|anony|mymail|mail\\.ru|\\.buzz|asdasd|asf|simplelogin|simplelogin\\.com|silomails\\.com|slmails\\.com|simplelogin\\.fr|aleeas\\.com|slmail\\.me|8shield\\.net|dralias\\.com|passinbox\\.com|passfwd\\.com|passmail\\.com|passmail\\.net|simplelogin\\.co|simplelogin\\.io|duck\\.com|mozmail\\.com|anonaddy\\.com|anonaddy\\.me|trash|guerrilla|getnada|owly|mvrht|sharklasers|anonbox).*"
            }
          ]
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "acbdbe02-1f83-4d34-97f1-d9fdf66c0652",
      "name": "从 cdp 获取 user_id",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        920,
        240
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "name",
          "value": "={{ $json.database_id }}"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "a3a0ce7f-466d-4f7d-a789-1c2adbf22e30",
      "name": "按状态处理",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        220,
        560
      ],
      "parameters": {
        "columns": {
          "value": {
            "type": "={{ $json.type }}",
            "email": "={{ $json.email }}",
            "number": "={{ $json.number }}",
            "status": "0-processing",
            "journey": "={{ $json.journey }}",
            "user_id": "={{ $json.user_id }}",
            "CreatedAt": "={{ $('Schedule Trigger').item.json.timestamp }}",
            "UpdatedAt": "={{ $('Schedule Trigger').item.json.timestamp }}",
            "gift_code": "={{ $json.gift_code }}",
            "first_name": "={{ $json.first_name }}",
            "database_id": "={{ $json.database_id }}",
            "template_id": "={{ $json.template_id }}",
            "discount_code": "={{ $json.discount_code }}",
            "template_name": "={{ $json.template_name }}",
            "type_template_id": "={{ $json.type_template_id }}"
          },
          "schema": [
            {
              "id": "CreatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "CreatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "UpdatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "UpdatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "user_id",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "user_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "email",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "number",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "first_name",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "first_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "database_id",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "database_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "type",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_id",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type_template_id",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "type_template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_name",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "template_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "journey",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "journey",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "sent_result",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "sent_result",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "discount_code",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "discount_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "gift_code",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "gift_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "7f85d42d-c21d-46d6-a61d-f021ed619153",
      "name": "Insert Data By Status Processing",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        640,
        560
      ],
      "parameters": {
        "options": {},
        "filtersUI": {
          "values": [
            {
              "lookupValue": "0-processing",
              "lookupColumn": "status"
            }
          ]
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "executeOnce": true,
      "typeVersion": 4.6
    },
    {
      "id": "5232fd36-adc4-4a78-bb09-af5e880a82bf",
      "name": "Change Status to Sending",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1120,
        660
      ],
      "parameters": {
        "columns": {
          "value": {
            "status": "1-sending",
            "user_id": "={{ $json.user_id }}",
            "UpdatedAt": "={{ $('Schedule Trigger').item.json.timestamp }}"
          },
          "schema": [
            {
              "id": "CreatedAt",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "CreatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "UpdatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "UpdatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "user_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "user_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "email",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "number",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "first_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "first_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "database_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "database_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type_template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type_template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "journey",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "journey",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "sent_result",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "sent_result",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "discount_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "discount_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "gift_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "gift_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "row_number",
              "type": "string",
              "display": true,
              "removed": true,
              "readOnly": true,
              "required": false,
              "displayName": "row_number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "user_id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "update",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "d099864f-5ec0-42a3-b5c8-d443a9606a32",
      "name": "Insert Data By Status Sending",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1780,
        460
      ],
      "parameters": {
        "options": {},
        "filtersUI": {
          "values": [
            {
              "lookupValue": "1-sending",
              "lookupColumn": "status"
            }
          ]
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "executeOnce": true,
      "typeVersion": 4.6
    },
    {
      "id": "af7b1c39-99db-4da7-8210-420347a57503",
      "name": "No Email Update",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2460,
        560
      ],
      "parameters": {
        "columns": {
          "value": {
            "status": "3-no-email",
            "user_id": "={{ $json.user_id }}",
            "UpdatedAt": "={{ $('Schedule Trigger1').item.json.timestamp }}"
          },
          "schema": [
            {
              "id": "CreatedAt",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "CreatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "UpdatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "UpdatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "user_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "user_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "email",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "number",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "first_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "first_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "database_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "database_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type_template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type_template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "journey",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "journey",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "sent_result",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "sent_result",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "discount_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "discount_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "gift_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "gift_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "user_id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "update",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "f99dae69-12d7-48bf-acd3-4d43defa01c9",
      "name": "Disposal Email Update",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2700,
        420
      ],
      "parameters": {
        "columns": {
          "value": {
            "status": "4-disposal-email",
            "user_id": "={{ $json.user_id }}",
            "UpdatedAt": "={{ $('Schedule Trigger1').item.json.timestamp }}"
          },
          "schema": [
            {
              "id": "CreatedAt",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "CreatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "UpdatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "UpdatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "user_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "user_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "email",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "number",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "first_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "first_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "database_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "database_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type_template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type_template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "journey",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "journey",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "sent_result",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "sent_result",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "discount_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "discount_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "gift_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "gift_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "row_number",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": true,
              "required": false,
              "displayName": "row_number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "user_id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "update",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "f0fb7eee-caee-4f5c-86b6-882b6390c9bb",
      "name": "Update Status: 2-Sent",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        3140,
        220
      ],
      "parameters": {
        "columns": {
          "value": {
            "status": "2-sent",
            "user_id": "={{ $json.user_id }}",
            "UpdatedAt": "={{ $('Schedule Trigger1').item.json.timestamp }}"
          },
          "schema": [
            {
              "id": "CreatedAt",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "CreatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "UpdatedAt",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "UpdatedAt",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "user_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "user_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "email",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "number",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "first_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "first_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "database_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "database_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "type_template_id",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "type_template_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "template_name",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "template_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "journey",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "journey",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "sent_result",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "sent_result",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "discount_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "discount_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "gift_code",
              "type": "string",
              "display": true,
              "removed": true,
              "required": false,
              "displayName": "gift_code",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "row_number",
              "type": "string",
              "display": true,
              "removed": true,
              "readOnly": true,
              "required": false,
              "displayName": "row_number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "user_id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "update",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1746603725,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0/edit#gid=1746603725",
          "cachedResultName": "transaction"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "37b87499-d9d8-4274-9fc2-5a7b73384d77",
      "name": "Get all flow templates from Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        220,
        160
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit#gid=0",
          "cachedResultName": "template"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1jK0xlp7-_JPDz5uMTUN0Hac7vFxAv8ZEvD10kwnJXrw/edit?usp=drivesdk",
          "cachedResultName": "Automate-Email-Marketing-Campaigns MailerSend | n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "A3ebjIB2M27srsju",
          "name": "Nima40"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "00401910-2157-47ee-a73c-385694db6345",
      "name": "便签8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        240,
        -220
      ],
      "parameters": {
        "color": 4,
        "width": 660,
        "height": 240,
        "content": "# 📄 Transaction Sheet (Copy This)\n\nAll example data for this workflow is already prepared ✅  \nOpen the Google Sheet below and copy the **Transaction** tab:\n\n🔗 Google Sheet:\nhttps://docs.google.com/spreadsheets/d/17KqltP-NqchPhZV7gk6QToqCZX6IiA5EBkDCBNsIX_0/edit?usp=sharing\n"
      },
      "typeVersion": 1
    },
    {
      "id": "ddcaa8e2-5fb8-4953-971c-a2d42bcbe1a0",
      "name": "Send an template HTML Mailerlite",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        2760,
        220
      ],
      "parameters": {
        "url": "https://api.mailersend.com/v1/email",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"from\": {\n    \"email\": \"info@example.com\"\n  },\n  \"to\": [\n    {\n      \"email\": \"{{ $json.email }}\"\n    }\n  ],\n  \"template_id\": \"{{ $json.type_template_id }}\",\n  \"personalization\": [\n    {\n      \"email\": \"{{ $json.email }}\",\n      \"data\": {\n        \"first_name\": \"{{ $json.first_name }}\"\n      }\n    }\n  ]\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            },
            {
              "name": "X-Requested-With",
              "value": "XMLHttpRequest"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "ipwzCWBxUO1BQJhe",
          "name": "MailerSend2 - Test"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "d528c926-e075-48d6-aa00-16b1720c7cac",
      "name": "便签9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1540,
        140
      ],
      "parameters": {
        "color": 5,
        "width": 1780,
        "height": 660,
        "content": "确保您的表名与实际知识库结构匹配"
      },
      "typeVersion": 1
    },
    {
      "id": "be5abdba-ae74-4d43-b6f8-0bea73e1ed03",
      "name": "便签 10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -280,
        80
      ],
      "parameters": {
        "color": 5,
        "width": 1620,
        "height": 760,
        "content": "确保您的表名与实际知识库结构匹配"
      },
      "typeVersion": 1
    },
    {
      "id": "b5564b95-2824-4066-be2c-3bf9f815a7bf",
      "name": "便签12",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2600,
        -380
      ],
      "parameters": {
        "width": 460,
        "height": 780,
        "content": "# ✉️ MailerSend Send Email\n\nThis node sends the campaign email to each valid subscriber.\n\n✅ Uses MailerSend Template ID from:\n• `type_template_id` field in template sheet (string)\n\n✅ Personalization fields:\n• first_name\n• discount_code\n• gift_code\n\n⚠️ Required Setup:\n👉 Edit the \"from\" field inside the JSON:\n\"from\": {\n  \"email\": \"YOUR_SENDER_EMAIL@here.com\"\n}\n\nThis email must be:\n✅ Verified inside MailerSend Dashboard\n✅ Approved by MailerSend to avoid blocked sends\n\n📌 Output values saved:\n• sent_result → MailerSend Message ID\n• sent_at → Timestamp\n• status → `2-sent`\n\nTip 🧠: Test with your own email first before going live."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "ed416c60-3f9f-48b3-851a-cc5e19546707",
  "connections": {
    "Wait": {
      "main": [
        [
          {
            "node": "Insert Data By Status Processing",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Map Data": {
      "main": [
        [
          {
            "node": "Add records By Status Processing",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Setup Flow": {
      "main": [
        [
          {
            "node": "Get all flow templates from Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "IF Type Email": {
      "main": [
        [
          {
            "node": "If email is not empty",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Disposal Check": {
      "main": [
        [
          {
            "node": "Send an template HTML Mailerlite",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Disposal Email Update",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter Template": {
      "main": [
        [
          {
            "node": "IF Template Parameters OK",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "Setup Flow",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Remove Duplicates": {
      "main": [
        [
          {
            "node": "Change Status to Sending",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger1": {
      "main": [
        [
          {
            "node": "Insert Data By Status Sending",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get user_id from cdp": {
      "main": [
        [
          {
            "node": "IF user_id is not empty",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If email is not empty": {
      "main": [
        [
          {
            "node": "Disposal Check",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "No Email Update",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "IF user_id is not empty": {
      "main": [
        [
          {
            "node": "Map Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "IF Template Parameters OK": {
      "main": [
        [
          {
            "node": "Get user_id from cdp",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Insert Data By Status Sending": {
      "main": [
        [
          {
            "node": "IF Type Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Add records By Status Processing": {
      "main": [
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Insert Data By Status Processing": {
      "main": [
        [
          {
            "node": "Remove Duplicates",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send an template HTML Mailerlite": {
      "main": [
        [
          {
            "node": "Update Status: 2-Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get all flow templates from Sheet": {
      "main": [
        [
          {
            "node": "Filter Template",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
常见问题

如何使用这个工作流?

复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。

这个工作流适合什么场景?

高级 - 社交媒体

需要付费吗?

本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。

工作流信息
难度等级
高级
节点数量34
分类1
节点类型9
难度说明

适合高级用户,包含 16+ 个节点的复杂工作流

作者
Nima Salimi

Nima Salimi

@salimi

- Marketing Automation Specialist - Marketing Workflow Architect - Optimizing Marketing Processes

外部链接
在 n8n.io 查看

分享此工作流