This workflow corresponds to n8n.io template #6201 — we link there as the canonical source.
This workflow follows the Agent → Gmail recipe pattern — see all workflows that pair these two integrations.
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 →
{
"id": "ZQemp67V5rZZ1mML",
"meta": {
"templateCredsSetupCompleted": true
},
"name": "Birthday Email",
"tags": [],
"nodes": [
{
"id": "230640a2-4c18-4f3e-bc7f-c201effe75ec",
"name": "Schedule Trigger",
"type": "n8n-nodes-base.scheduleTrigger",
"position": [
-320,
-40
],
"parameters": {
"rule": {
"interval": [
{
"triggerAtHour": 9
}
]
}
},
"typeVersion": 1.2
},
{
"id": "4d24e522-849d-44d5-a9f1-ee8fcabc73c2",
"name": "Get row(s) in sheet",
"type": "n8n-nodes-base.googleSheets",
"position": [
-100,
-40
],
"parameters": {
"options": {},
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1fTGWkzIMdq1G3v2R3tRsRWIgEByPBeKsKXIJTcsxWwk/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1fTGWkzIMdq1G3v2R3tRsRWIgEByPBeKsKXIJTcsxWwk",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1fTGWkzIMdq1G3v2R3tRsRWIgEByPBeKsKXIJTcsxWwk/edit?usp=drivesdk",
"cachedResultName": "Birthday"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 4.6
},
{
"id": "c385dff5-57ad-424d-8579-ee4916024f7c",
"name": "Filter",
"type": "n8n-nodes-base.filter",
"position": [
120,
-40
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "f264376f-683f-40e4-bdc2-05ced56f3b3b",
"operator": {
"type": "dateTime",
"operation": "equals"
},
"leftValue": "={{ $json.DOB.split('/').slice(0,2).join('-')}}\n",
"rightValue": "={{ $now.toFormat(\"dd-MM\") }}"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "ea549cc4-e261-4a76-b17e-f70e85604b4e",
"name": "AI Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
340,
-40
],
"parameters": {
"text": "=use below name for birthday wishes.\n\nname:{{ $json.name }}\ndob:{{ $json.DOB }}\n\nwrite email according to you and best regards by parth.",
"options": {
"systemMessage": "You are an assistant that writes warm and personalized birthday emails. Use the user\u2019s name to begin the email. Keep it short, friendly, and positive. Add one emoji. End with best wishes and the sender\u2019s name.\n\n"
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 2
},
{
"id": "97c2ee5a-1379-4c3e-af3e-fc0f4e2b7340",
"name": "OpenRouter Chat Model",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
"position": [
340,
160
],
"parameters": {
"model": "openai/gpt-4o-mini",
"options": {}
},
"credentials": {
"openRouterApi": {
"name": "<your credential>"
}
},
"typeVersion": 1
},
{
"id": "73d4c61e-90bb-498c-b3bb-f0cff5852261",
"name": "Send a message",
"type": "n8n-nodes-base.gmail",
"position": [
700,
-40
],
"parameters": {
"sendTo": "={{ $('Filter').item.json.EMail }}",
"message": "={{ $json.output.body }}",
"options": {
"appendAttribution": false
},
"subject": "={{ $json.output.subject }}",
"emailType": "text"
},
"credentials": {
"gmailOAuth2": {
"name": "<your credential>"
}
},
"typeVersion": 2.1
},
{
"id": "08230bd2-a4e5-46ee-9577-fa78cd01f925",
"name": "Structured Output Parser",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
500,
160
],
"parameters": {
"jsonSchemaExample": "{\n\"subject\": \"Happy Birthday, Keyur! \ud83c\udf89\",\n\"body\" :\"Dear Keyur,\\n\\nHappy Birthday! I hope your special day ... \\nParth\"\n\n\n}"
},
"typeVersion": 1.3
}
],
"active": false,
"settings": {
"executionOrder": "v1"
},
"versionId": "8317f9c1-21c4-4fee-8236-c9dd54bcbb04",
"connections": {
"Filter": {
"main": [
[
{
"node": "AI Agent",
"type": "main",
"index": 0
}
]
]
},
"AI Agent": {
"main": [
[
{
"node": "Send a message",
"type": "main",
"index": 0
}
]
]
},
"Schedule Trigger": {
"main": [
[
{
"node": "Get row(s) in sheet",
"type": "main",
"index": 0
}
]
]
},
"Get row(s) in sheet": {
"main": [
[
{
"node": "Filter",
"type": "main",
"index": 0
}
]
]
},
"OpenRouter Chat Model": {
"ai_languageModel": [
[
{
"node": "AI Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Structured Output Parser": {
"ai_outputParser": [
[
{
"node": "AI Agent",
"type": "ai_outputParser",
"index": 0
}
]
]
}
}
}
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.
gmailOAuth2googleSheetsOAuth2ApiopenRouterApi
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
This workflow contains community nodes that are only compatible with the self-hosted version of n8n.
Source: https://n8n.io/workflows/6201/ — 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.
This n8n template demonstrates how to use AI to fully automate the generation and scheduling of X (formerly Twitter) content based on a specific, predefined persona.
This workflow automatically fetches the latest public grant information from the Ministry of Health, Labour and Welfare (MHLW) RSS feed. It uses AI to summarize and structure each grant post into a cl
This n8n automation workflow automates the creation, scripting, production, and posting of YouTube videos. It leverages AI (OpenAI), image generation (PIAPI), video rendering (Shotstack), and platform
Created by: Peyton Leveillee Last updated: October 2025
This n8n workflow turns a script and character/setting description from Google Sheets into a complete stitched UGC-style video ad, fully automated from intake to final delivery.