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 →
{
"name": "SP \u00b7 25 \u00b7 Factura Email tras Pago",
"nodes": [
{
"parameters": {
"httpMethod": "POST",
"path": "pago-registrado",
"responseMode": "lastNode",
"options": {}
},
"id": "sp25inv-0001",
"name": "Webhook \u00b7 Pago registrado",
"type": "n8n-nodes-base.webhook",
"typeVersion": 2,
"position": [
240,
300
]
},
{
"parameters": {
"respondWith": "json",
"responseBody": "={ \"ok\": true }"
},
"id": "sp25inv-0002",
"name": "Responder OK",
"type": "n8n-nodes-base.respondToWebhook",
"typeVersion": 1,
"position": [
460,
500
]
},
{
"parameters": {
"conditions": {
"conditions": [
{
"leftValue": "={{ $json.email }}",
"rightValue": "",
"operator": {
"type": "string",
"operation": "notEquals"
}
}
]
}
},
"id": "sp25inv-0003",
"name": "\u00bfTiene email?",
"type": "n8n-nodes-base.if",
"typeVersion": 2,
"position": [
460,
300
]
},
{
"parameters": {
"jsCode": "const d=$input.first().json;\nconst imp=parseFloat(d.importe||0).toFixed(2);\nreturn [{ json: { ...d,\n asunto: `Factura ${d.numFactura||''} \u2014 ${$vars.CLINICA_NOMBRE}`,\n cuerpo: `Estimado/a ${d.nombre},\\n\\nFactura por los servicios recibidos:\\n\\nN\u00ba Factura: ${d.numFactura||'Ver adjunto'}\\nConcepto: ${d.tratamiento||'Servicios dentales'}\\nImporte: ${imp}\u20ac\\nFecha: ${d.fechaStr||new Date().toLocaleDateString('es-ES')}\\nForma de pago: ${d.formaPago||'\u2014'}\\n\\nGracias por su confianza.\\n${$vars.CLINICA_NOMBRE}\\n${$vars.CLINICA_TELEFONO}`\n} }];"
},
"id": "sp25inv-0004",
"name": "Preparar email factura",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
680,
220
]
},
{
"parameters": {
"fromEmail": "={{ $vars.SMTP_USER }}",
"toEmail": "={{ $json.email }}",
"subject": "={{ $json.asunto }}",
"emailType": "text",
"message": "={{ $json.cuerpo }}",
"options": {}
},
"id": "sp25inv-0005",
"name": "Email \u00b7 Factura",
"type": "n8n-nodes-base.emailSend",
"typeVersion": 2.1,
"position": [
900,
220
],
"credentials": {
"smtp": {
"name": "<your credential>"
}
}
}
],
"connections": {
"Webhook \u00b7 Pago registrado": {
"main": [
[
{
"node": "\u00bfTiene email?",
"type": "main",
"index": 0
},
{
"node": "Responder OK",
"type": "main",
"index": 0
}
]
]
},
"\u00bfTiene email?": {
"main": [
[
{
"node": "Preparar email factura",
"type": "main",
"index": 0
}
],
[]
]
},
"Preparar email factura": {
"main": [
[
{
"node": "Email \u00b7 Factura",
"type": "main",
"index": 0
}
]
]
}
},
"active": false,
"settings": {
"executionOrder": "v1"
},
"id": "sp-invoice-doctor-025"
}
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.
smtp
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
SP · 25 · Factura Email tras Pago. Uses emailSend. Webhook trigger; 5 nodes.
Source: https://github.com/Manzanedodelgado/SmilePro-Studio/blob/7a67a0777c43ab52ee492a48d0c1616b905b49a2/n8n-workflows/25-invoice-doctor.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
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
Automated QuickBooks Invoice to Custom PDF & Email
ScrapFlow - Customer Invoice (Outbound). Uses emailSend. Webhook trigger; 4 nodes.
Stop copy-pasting invoice details!
This workflow automates the entire process of receiving a product/service order, checking or creating a customer in QuickBooks Online (QBO), generating an invoice, and emailing it — all triggered by a