AutomationFlowsFinance › Send Invoice Email via Webhook

Send Invoice Email via Webhook

Original n8n title: Scrapflow - Customer Invoice (outbound)

ScrapFlow - Customer Invoice (Outbound). Uses emailSend. Webhook trigger; 4 nodes.

Webhook trigger★★☆☆☆ complexity4 nodesEmail Send
Finance Trigger: Webhook Nodes: 4 Complexity: ★★☆☆☆ Added:

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "name": "ScrapFlow - Customer Invoice (Outbound)",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "scrapflow-outbound-completed",
        "responseMode": "onReceived",
        "responseData": "firstEntryJson"
      },
      "id": "4a2b3c4d-0001",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 1.1,
      "position": [
        250,
        300
      ]
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict"
          },
          "conditions": [
            {
              "id": "event-check",
              "leftValue": "={{ $json.event }}",
              "rightValue": "ticket.outbound.completed",
              "operator": {
                "type": "string",
                "operation": "equals"
              }
            },
            {
              "id": "email-check",
              "leftValue": "={{ $json.data.customer?.email }}",
              "rightValue": "",
              "operator": {
                "type": "string",
                "operation": "isNotEmpty"
              }
            }
          ],
          "combinator": "and"
        }
      },
      "id": "4a2b3c4d-0002",
      "name": "Has Customer Email?",
      "type": "n8n-nodes-base.if",
      "typeVersion": 2,
      "position": [
        450,
        300
      ]
    },
    {
      "parameters": {
        "fromEmail": "kwanelerh069@gmail.com",
        "toEmail": "={{ $json.data.customer.email }}",
        "subject": "=ScrapFlow Invoice \u2013 {{ $json.data.invoiceNumber ?? $json.data.ticketNumber }}",
        "emailType": "html",
        "message": "=<!DOCTYPE html><html><body style='font-family:Arial,sans-serif;max-width:600px;margin:0 auto;padding:20px'><h2 style='color:#1a56db'>ScrapFlow SA \u2014 Tax Invoice</h2><table width='100%' style='border-collapse:collapse;margin-bottom:20px'><tr style='background:#f3f4f6'><td style='padding:8px 12px;font-weight:bold'>Invoice Number</td><td style='padding:8px 12px'>{{ $json.data.invoiceNumber ?? $json.data.ticketNumber }}</td></tr><tr><td style='padding:8px 12px;font-weight:bold'>Date</td><td style='padding:8px 12px'>{{ $now.setZone('Africa/Johannesburg').toFormat('dd/MM/yyyy') }}</td></tr><tr style='background:#f3f4f6'><td style='padding:8px 12px;font-weight:bold'>Bill To</td><td style='padding:8px 12px'>{{ $json.data.customer.companyName ?? $json.data.customer.fullName }}</td></tr><tr><td style='padding:8px 12px;font-weight:bold'>Site</td><td style='padding:8px 12px'>{{ $json.data.siteName }}</td></tr><tr style='background:#f3f4f6'><td style='padding:8px 12px;font-weight:bold'>Net Weight</td><td style='padding:8px 12px'>{{ $json.data.netWeight }} kg</td></tr></table><h3>Line Items</h3><table width='100%' style='border-collapse:collapse'><thead><tr style='background:#1a56db;color:white'><th style='padding:8px 12px;text-align:left'>Material</th><th style='padding:8px 12px;text-align:right'>Weight (kg)</th><th style='padding:8px 12px;text-align:right'>Total (R)</th></tr></thead><tbody>{{ $json.data.lineItems.map((li, i) => `<tr style='background:${i%2===0?'#f9fafb':'white'}'><td style='padding:8px 12px'>${li.materialCode}</td><td style='padding:8px 12px;text-align:right'>${li.netWeight}</td><td style='padding:8px 12px;text-align:right'>${li.lineTotal}</td></tr>`).join('') }}</tbody><tfoot><tr style='background:#059669;color:white'><td style='padding:10px 12px;font-weight:bold' colspan='2'>TOTAL</td><td style='padding:10px 12px;font-weight:bold;text-align:right;font-size:16px'>R {{ $json.data.totalPrice }}</td></tr></tfoot></table><br/><p style='color:#9ca3af;font-size:12px'>ScrapFlow SA \u2014 Registered Second-Hand Goods Dealer. This is a system-generated invoice.</p></body></html>",
        "options": {}
      },
      "id": "4a2b3c4d-0003",
      "name": "Send Invoice Email",
      "type": "n8n-nodes-base.emailSend",
      "typeVersion": 2.1,
      "position": [
        650,
        200
      ],
      "credentials": {
        "smtp": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {},
      "id": "4a2b3c4d-0004",
      "name": "No Email \u2014 Skip",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        650,
        420
      ]
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Has Customer Email?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Has Customer Email?": {
      "main": [
        [
          {
            "node": "Send Invoice Email",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "No Email \u2014 Skip",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "04-customer-invoice-v1",
  "meta": {
    "templateCredsSetupCompleted": false
  },
  "tags": [
    {
      "createdAt": "2026-03-04T00:00:00Z",
      "updatedAt": "2026-03-04T00:00:00Z",
      "id": "scrapflow-tag",
      "name": "ScrapFlow"
    }
  ]
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

ScrapFlow - Customer Invoice (Outbound). Uses emailSend. Webhook trigger; 4 nodes.

Source: https://github.com/dev-k99/ScrapFlow/blob/170a655118347be55fcefd8f94f51747df8a9a35/n8n-workflows/04-customer-invoice.json — original creator credit. Request a take-down →

More Finance workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Finance

Stop copy-pasting invoice details!

Google Docs, Email Send, Google Drive
Finance

Tired of the standard, boring invoices from QuickBooks Online? This workflow completely automates the process of creating beautiful, custom-branded PDF invoices and emailing them directly to your clie

QuickBooks, HTTP Request, Email Send
Finance

Automated QuickBooks Invoice to Custom PDF & Email

QuickBooks, HTTP Request, Email Send
Finance

SP · 25 · Factura Email tras Pago. Uses emailSend. Webhook trigger; 5 nodes.

Email Send
Finance

It automatically saves new QuickBooks invoice PDFs directly into Google Drive, creating a reliable backup system. For perfect organization, the workflow uses keywords from the invoice, like the client

QuickBooks, Google Drive, HTTP Request