{ "name": "SendGrid Bounce Alert", "nodes": [ { "parameters": { "content": "Placeholder for SendGrid Bounce Alert", "height": 530, "width": 1100, "color": 5 }, "id": "33c24c3f-fbf8-4461-b748-983270488128", "name": "Sticky Note", "type": "n8n-nodes-base.stickyNote", "typeVersion": 1, "position": [ -480, -240 ] }, { "parameters": { "httpMethod": "POST", "path": "sendgrid-bounce-alert" }, "id": "a3b0ea8e-7b9b-40d8-b942-857e800281b2", "name": "Webhook Trigger", "type": "n8n-nodes-base.webhook", "typeVersion": 1, "position": [ -300, 0 ] }, { "parameters": { "chunkSize": 400, "chunkOverlap": 40 }, "id": "0e37fa2c-1524-46f4-8809-c469faef23bc", "name": "Text Splitter", "type": "@n8n/n8n-nodes-langchain.textSplitterCharacterTextSplitter", "typeVersion": 1, "position": [ -130, 0 ] }, { "parameters": { "model": "text-embedding-3-small", "options": {} }, "id": "bd0a5c1f-6add-4133-9d92-73491a90e45d", "name": "Embeddings", "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi", "typeVersion": 1, "position": [ 70, 0 ], "credentials": { "openAiApi": { "id": "OPENAI_API", "name": "OpenAI" } } }, { "parameters": { "mode": "insert", "options": {}, "indexName": "sendgrid_bounce_alert" }, "id": "f73cb3be-a874-4a02-a997-3953032b3de5", "name": "Weaviate Insert", "type": "@n8n/n8n-nodes-langchain.vectorStoreWeaviate", "typeVersion": 1, "position": [ 270, 0 ], "credentials": { "weaviateApi": { "id": "WEAVIATE_API", "name": "Weaviate account" } } }, { "parameters": { "indexName": "sendgrid_bounce_alert" }, "id": "b21ab497-8f7d-4420-8584-c1ccf7243d63", "name": "Weaviate Query", "type": "@n8n/n8n-nodes-langchain.vectorStoreWeaviate", "typeVersion": 1, "position": [ 270, -180 ], "credentials": { "weaviateApi": { "id": "WEAVIATE_API", "name": "Weaviate account" } } }, { "parameters": { "name": "Weaviate", "description": "Vector context" }, "id": "16a0a9d0-3851-46b9-8830-83c3c75a28ac", "name": "Vector Tool", "type": "@n8n/n8n-nodes-langchain.toolVectorStore", "typeVersion": 1, "position": [ 450, -180 ] }, { "parameters": {}, "id": "ede2aa4c-94e5-4890-ac9e-41d6c24e1779", "name": "Window Memory", "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow", "typeVersion": 1.3, "position": [ 450, -40 ] }, { "parameters": { "options": {} }, "id": "79910783-a249-4d46-9fe8-f8d763e030d9", "name": "Chat Model", "type": "@n8n/n8n-nodes-langchain.lmChatAnthropic", "typeVersion": 1, "position": [ 450, -340 ], "credentials": { "anthropicApi": { "id": "ANTHROPIC_API", "name": "Anthropic" } } }, { "parameters": { "promptType": "define", "text": "Handle data", "options": { "systemMessage": "You are an assistant for SendGrid Bounce Alert" } }, "id": "8c19f7ba-df58-44c6-8a70-70d747b0e2b9", "name": "RAG Agent", "type": "@n8n/n8n-nodes-langchain.agent", "typeVersion": 1, "position": [ 720, -40 ] }, { "parameters": { "operation": "append", "documentId": { "__rl": true, "value": "SHEET_ID", "mode": "list", "cachedResultName": "SendGrid Bounce Alert" }, "sheetName": { "__rl": true, "value": "Log", "mode": "list", "cachedResultName": "Log" }, "columns": { "mappingMode": "defineBelow", "value": "Status", "schema": [] } }, "id": "adc64b6e-f045-4d6c-a38b-41c33af872f2", "name": "Append Sheet", "type": "n8n-nodes-base.googleSheets", "typeVersion": 4, "position": [ 930, -40 ], "credentials": { "googleSheetsOAuth2Api": { "id": "SHEETS_API", "name": "Google Sheets account" } } }, { "parameters": { "channel": "#alerts", "text": "SendGrid Bounce Alert error: {$json.error.message}" }, "id": "dce8248e-a281-492c-bac7-fca5243ec8e5", "name": "Slack Alert", "type": "n8n-nodes-base.slack", "typeVersion": 1, "position": [ 930, 120 ], "credentials": { "slackApi": { "id": "SLACK_API", "name": "Slack" } } } ], "connections": { "Webhook Trigger": { "main": [ [ { "node": "Text Splitter", "type": "main", "index": 0 }, { "node": "Window Memory", "type": "main", "index": 0 } ] ] }, "Text Splitter": { "main": [ [ { "node": "Embeddings", "type": "main", "index": 0 } ] ], "ai_textSplitter": [ [ { "node": "Weaviate Insert", "type": "ai_textSplitter", "index": 0 } ] ] }, "Embeddings": { "ai_embedding": [ [ { "node": "Weaviate Insert", "type": "ai_embedding", "index": 0 }, { "node": "Weaviate Query", "type": "ai_embedding", "index": 0 } ] ] }, "Weaviate Insert": { "ai_document": [ [] ] }, "Weaviate Query": { "ai_vectorStore": [ [ { "node": "Vector Tool", "type": "ai_vectorStore", "index": 0 } ] ] }, "Vector Tool": { "ai_tool": [ [ { "node": "RAG Agent", "type": "ai_tool", "index": 0 } ] ] }, "Window Memory": { "ai_memory": [ [ { "node": "RAG Agent", "type": "ai_memory", "index": 0 } ] ] }, "Chat Model": { "ai_languageModel": [ [ { "node": "RAG Agent", "type": "ai_languageModel", "index": 0 } ] ] }, "RAG Agent": { "main": [ [ { "node": "Append Sheet", "type": "main", "index": 0 } ] ], "onError": [ [ { "node": "Slack Alert", "type": "main", "index": 0 } ] ] } }, "settings": { "executionOrder": "v1" }, "triggerCount": 1 }