{ "id": "CNOMivCLJRGfZnUM", "meta": { "instanceId": "31e69f7f4a77bf465b805824e303232f0227212ae922d12133a0f96ffeab4fef", "templateCredsSetupCompleted": true }, "name": "🦜✨Use OpenAI to Transcribe Audio + Summarize with AI + Save to Google Drive", "tags": [], "nodes": [ { "id": "3918995a-a587-40c1-828c-97e75b988a9f", "name": "Gmail User for Approval", "type": "n8n-nodes-base.gmail", "disabled": true, "position": [ 360, -20 ], "webhookId": "c46cf421-ddb6-45a8-b83b-80b381666f0e", "parameters": { "sendTo": "={{ $env.EMAIL_ADDRESS_JOE }} ", "message": "=A new was just created in the Audio Recordings folder on Google Drive. Would you like to continue the workflow and Transcribe the audio file and generate reports.", "options": { "limitWaitTime": { "values": { "resumeUnit": "minutes", "resumeAmount": 45 } } }, "subject": "=💡New Audio File Created - Approve Transcription Service", "operation": "sendAndWait", "approvalOptions": { "values": { "approvalType": "double" } } }, "credentials": { "gmailOAuth2": { "id": "1xpVDEQ1yx8gV022", "name": "Gmail account" } }, "typeVersion": 2.1 }, { "id": "44aa6e99-9b4a-4af4-93e3-4b1a50fc7628", "name": "Sticky Note", "type": "n8n-nodes-base.stickyNote", "position": [ -320, 680 ], "parameters": { "color": 3, "width": 260, "height": 280, "content": "## 3️⃣ Transcribe Audio" }, "typeVersion": 1 }, { "id": "cbf765b5-b888-4e22-b4a2-1d430b557109", "name": "Set Config", "type": "n8n-nodes-base.set", "position": [ 0, 780 ], "parameters": { "options": {}, "assignments": { "assignments": [ { "id": "2f5cef95-a26b-46ff-ab9a-501187ce4211", "name": "text", "type": "string", "value": "={{ $json.text }}" }, { "id": "ac623698-1263-4b83-8c59-159863d950b9", "name": "datetime", "type": "string", "value": "={{ $now }}" } ] } }, "typeVersion": 3.4 }, { "id": "bd9cd4aa-6afc-4875-a487-df4f0d3a4a29", "name": "Transcribe with OpenAI", "type": "@n8n/n8n-nodes-langchain.openAi", "position": [ -240, 780 ], "parameters": { "options": {}, "resource": "audio", "operation": "transcribe" }, "credentials": { "openAiApi": { "id": "jEMSvKmtYfzAkhe6", "name": "OpenAi account" } }, "typeVersion": 1 }, { "id": "4d91f6f7-a89e-44d9-9433-4d9a1df368a2", "name": "Sticky Note1", "type": "n8n-nodes-base.stickyNote", "position": [ 180, 580 ], "parameters": { "color": 5, "width": 1560, "height": 280, "content": "## 4️⃣ Process Transcript and Generate Structured JSON Report" }, "typeVersion": 1 }, { "id": "64421d13-0aff-46f8-bf3e-5fac89ec9c46", "name": "Sticky Note2", "type": "n8n-nodes-base.stickyNote", "position": [ 180, 900 ], "parameters": { "color": 6, "width": 1560, "height": 280, "content": "## 5️⃣ Process Transcript and Generate Structured JSON -> Markdown Report" }, "typeVersion": 1 }, { "id": "769ca5a4-2a54-4ed8-85af-4359b97755bc", "name": "Sticky Note3", "type": "n8n-nodes-base.stickyNote", "position": [ 1000, 1220 ], "parameters": { "color": 2, "width": 460, "height": 280, "content": "## 6️⃣ Save Raw Transcript to Google Drive" }, "typeVersion": 1 }, { "id": "aa612f37-f7cd-4cf7-919c-87564f03eef1", "name": "Sticky Note4", "type": "n8n-nodes-base.stickyNote", "position": [ -100, 240 ], "parameters": { "color": 4, "width": 300, "height": 300, "content": "## 1️⃣ Start Transcription Service" }, "typeVersion": 1 }, { "id": "1e520267-6275-4d07-bba8-9ebaf0afbc68", "name": "Sticky Note5", "type": "n8n-nodes-base.stickyNote", "position": [ -100, -140 ], "parameters": { "width": 700, "height": 340, "content": "## Wait for Google Drive Trigger and Send for User Approval to Proceed (Human in the Loop)\n(optional)" }, "typeVersion": 1 }, { "id": "1f07fa9c-ecfc-4534-a0b2-569eca1a3092", "name": "Sticky Note6", "type": "n8n-nodes-base.stickyNote", "position": [ 680, 240 ], "parameters": { "color": 2, "width": 880, "height": 300, "content": "## 2️⃣ Search and Download Audio File from Google Drive\n💡Note: Adjust Filter and Limit settings for your needs" }, "typeVersion": 1 }, { "id": "b769d523-6b1f-45f2-98b1-4d0f8eb2d7f4", "name": "Filter by .m4a extension", "type": "n8n-nodes-base.filter", "position": [ 980, 340 ], "parameters": { "options": { "ignoreCase": true }, "conditions": { "options": { "version": 2, "leftValue": "", "caseSensitive": false, "typeValidation": "loose" }, "combinator": "and", "conditions": [ { "id": "420e1a9c-2145-4845-b4b0-31a82855a78c", "operator": { "type": "string", "operation": "endsWith" }, "leftValue": "={{ $json.name }}", "rightValue": ".m4a" } ] }, "looseTypeValidation": true }, "typeVersion": 2.2 }, { "id": "5a67182e-4f13-4b6f-a3e2-863e18af31b0", "name": "Limit to last file", "type": "n8n-nodes-base.limit", "position": [ 1180, 340 ], "parameters": { "keep": "lastItems" }, "typeVersion": 1 }, { "id": "f42b4efc-6e04-49a1-8bd8-252ebd3dbf42", "name": "Download audio file", "type": "n8n-nodes-base.googleDrive", "position": [ 1380, 340 ], "parameters": { "fileId": { "__rl": true, "mode": "id", "value": "={{ $json.id }}" }, "options": {}, "operation": "download" }, "credentials": { "googleDriveOAuth2Api": { "id": "UhdXGYLTAJbsa0xX", "name": "Google Drive account" } }, "typeVersion": 3 }, { "id": "4313e19f-ca7a-4982-b3b4-1680c674e696", "name": "Search Google Drive", "type": "n8n-nodes-base.googleDrive", "position": [ 780, 340 ], "parameters": { "filter": { "folderId": { "__rl": true, "mode": "list", "value": "1Wqd4zEEb847gFYKoDBbNnXsWEc-kCAm2", "cachedResultUrl": "https://drive.google.com/drive/folders/1Wqd4zEEb847gFYKoDBbNnXsWEc-kCAm2", "cachedResultName": "Audio Recordings" }, "whatToSearch": "files" }, "options": {}, "resource": "fileFolder" }, "credentials": { "googleDriveOAuth2Api": { "id": "UhdXGYLTAJbsa0xX", "name": "Google Drive account" } }, "typeVersion": 3 }, { "id": "e25655b0-9d30-40d4-9051-bffe38fb41e0", "name": "Sticky Note7", "type": "n8n-nodes-base.stickyNote", "position": [ 2020, 700 ], "parameters": { "width": 660, "height": 480, "content": "## 7️⃣ Send Transcription Report Links to User" }, "typeVersion": 1 }, { "id": "38ff9906-41af-430a-9de9-0500577826a5", "name": "Send Telegram Message", "type": "n8n-nodes-base.telegram", "position": [ 2460, 980 ], "webhookId": "bb40ede7-03cf-493d-b051-196b96725925", "parameters": { "text": "=Audio Transcribed and Reports Generated\n{{ $json.id_json.webViewLink }}\n{{ $json.id_markdown.webViewLink }}", "chatId": "={{ $env.TELEGRAM_CHAT_ID }}", "additionalFields": { "parse_mode": "HTML", "appendAttribution": false } }, "credentials": { "telegramApi": { "id": "pAIFhguJlkO3c7aQ", "name": "Telegram account" } }, "typeVersion": 1.2 }, { "id": "5b6aedaa-897f-4b76-84d8-3ca18d06cc5c", "name": "Send Gmail Message", "type": "n8n-nodes-base.gmail", "position": [ 2460, 800 ], "webhookId": "0a81b95a-cd82-465d-8450-cf38518a4cbb", "parameters": { "sendTo": "={{ $env.EMAIL_ADDRESS_JOE }} ", "message": "={{ $json.message.content }}", "options": { "appendAttribution": false }, "subject": "Audio Transcribed and Reports Generated" }, "credentials": { "gmailOAuth2": { "id": "1xpVDEQ1yx8gV022", "name": "Gmail account" } }, "typeVersion": 2.1 }, { "id": "4500efdb-7a70-40da-97b6-e4668af21a19", "name": "Email Content Formatter", "type": "@n8n/n8n-nodes-langchain.openAi", "position": [ 2100, 800 ], "parameters": { "modelId": { "__rl": true, "mode": "list", "value": "gpt-4o-mini", "cachedResultName": "GPT-4O-MINI" }, "options": {}, "messages": { "values": [ { "content": "=Prapare this HTML template using the following: \n{{ $json.id_json.toJsonString() }}\n{{ $json.id_markdown.toJsonString() }}\n\nEnsure that the 'webViewLink' is always provided.\n\nRespond only with HTML and avoid any preamble or further explanation. Remove all ``` or ```html from final response.\n\n\n\n
\n