- email.ts: POST to N8N_EMAIL_WEBHOOK_URL instead of Resend API - env.ts: replace RESEND_API_KEY with N8N_EMAIL_WEBHOOK_URL - .env.example: document new env var - Add n8n workflow JSON (Webhook -> Gmail -> Respond) ready to import
72 lines
1.5 KiB
JSON
72 lines
1.5 KiB
JSON
{
|
|
"name": "Naturcalabacera - Email Relay",
|
|
"nodes": [
|
|
{
|
|
"parameters": {
|
|
"httpMethod": "POST",
|
|
"path": "naturcalabacera-email",
|
|
"responseMode": "responseNode",
|
|
"options": {}
|
|
},
|
|
"id": "webhook-naturcalabacera",
|
|
"name": "Webhook (POST email)",
|
|
"type": "n8n-nodes-base.webhook",
|
|
"typeVersion": 2,
|
|
"position": [240, 300]
|
|
},
|
|
{
|
|
"parameters": {
|
|
"sendTo": "={{ $json.body.to }}",
|
|
"subject": "={{ $json.body.subject }}",
|
|
"emailType": "html",
|
|
"message": "={{ $json.body.html }}",
|
|
"options": {}
|
|
},
|
|
"id": "gmail-send",
|
|
"name": "Gmail — Enviar",
|
|
"type": "n8n-nodes-base.gmail",
|
|
"typeVersion": 2.1,
|
|
"position": [520, 300]
|
|
},
|
|
{
|
|
"parameters": {
|
|
"respondWith": "json",
|
|
"responseBody": "={{ { success: true, id: $json.id } }}",
|
|
"options": {}
|
|
},
|
|
"id": "respond-ok",
|
|
"name": "Responder OK",
|
|
"type": "n8n-nodes-base.respondToWebhook",
|
|
"typeVersion": 1.1,
|
|
"position": [800, 300]
|
|
}
|
|
],
|
|
"connections": {
|
|
"Webhook (POST email)": {
|
|
"main": [
|
|
[
|
|
{
|
|
"node": "Gmail — Enviar",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
]
|
|
]
|
|
},
|
|
"Gmail — Enviar": {
|
|
"main": [
|
|
[
|
|
{
|
|
"node": "Responder OK",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
]
|
|
]
|
|
}
|
|
},
|
|
"settings": {
|
|
"executionOrder": "v1"
|
|
}
|
|
}
|