Skip to content
FlowHubFluxonLab
A
AI Automationfree

Score mortgage loan risk from Google Drive PDFs with OpenAI and Gmail

by Rahul Joshiadapted from n8n official workflow galleryUpdated Aug 2026
RequiresAAI AgentCCodeGmailGmailGoogle DriveGoogle DriveOpenAI Chat ModelOpenAI Chat ModelSlackStructured Output ParserStructured Output Parser
Share Post Share
GDWatch Loan Applications FolderWatch Loan Appl…Download Application PDFDownload Applic…EFExtract PDF TextAgExtract Applicant Data (AI)Extract Applica…GPT-4o-mini: Data ExtractionGPT-4o-mini: Da…OPParse Applicant Data SchemaParse Applicant…AgScore Applicant Risk (AI)Score Applicant…GPT-4o-mini: Risk ScoringGPT-4o-mini: Ri…OPParse Risk Score SchemaParse Risk Scor…AgGenerate Lending Summary (AI)Generate Lendin…GPT-4o-mini: Lending SummaryGPT-4o-mini: Le…AgIssue Underwriting Decision (AI)Issue Underwrit…GPT-4o-mini: Final DecisionGPT-4o-mini: Fi…OPParse Decision SchemaParse Decision …CoAssemble Final ReportAssemble Final …Email Report to Loan OfficerEmail Report to…Slack Alert: Extraction FailedSlack Alert: Ex…Slack Alert: Risk Scoring FailedSlack Alert: Ri…ErOn Workflow ErrorOn Workflow Err…Slack: Error AlertSlack: Error Al…12345678910111213141516171819
1/5
FLOWS
STEPS · 19
Starts on a Google Drive event

Quick overview This workflow monitors a Google Drive folder for new loan application PDFs, extracts text, and uses OpenAI (GPT-4o-mini) to structure applicant data, score risk, generate a lending summary, and produce an underwriting recommendation, then emails the final report via Gmail and posts Slack alerts on failures. How it works Triggers when a new PDF is created in a specified Google Drive folder. Downloads the PDF from Google Drive and extracts its text content. Uses OpenAI (GPT-4o-mini) to extract key applicant and loan fields into a validated JSON structure. Uses OpenAI (GPT-4o-mini) to calculate a risk score, risk level, approval confidence, and key findings in JSON. Uses OpenAI (GPT-4o-mini) to write a plain-text lending summary and then generate a final underwriting decision (approve/conditional approval/further review/decline) with reasoning and conditions. Assembles a single report from the extracted data, risk analysis, summary, and decision, and sends it to the loan officer via Gmail. If extraction or risk scoring fails, sends a Slack alert and retries by re-downloading the application PDF.

Tags

n8nreference-onlyagentgmailgoogle-drivelm-chat-open-aioutput-parser-structuredslack
Connects
AAI AgentCCodegmailGmailgoogledriveGoogle DriveopenaichatmodelOpenAI Chat ModelSlack
CategoryAI Automation
Triggermanual
Complexityadvanced
Nodes20
AddedJun 24, 2026

Related workflows

See all AI Automation
ACgmailW
free

Send weekly blended ad performance reports with Meta Ads, Google Ads, GA4 and OpenAI

Quick overview This workflow runs every Monday at 8am, pulls last-7-days performance data from the Meta Ads API, Google Ads API, and Google Analytics 4, calculates blended KPIs, uses OpenAI to generate a client-friendly insight summary, and delivers an HTML report by Gmail while posting status update to Slack. How it works Runs every Monday at 8am on a schedule trigger. Fetches the last 7 days of spend and engagement metrics from the Meta Ads Insights endpoint. Fetches the last 7 days of campaign cost, clicks, and conversions from the Google Ads API using a streamed search query. Fetches the last 7 days of conversions and revenue by default channel group from the Google Analytics 4 Data API. Combines the three datasets and calculates blended totals for spend, conversions, revenue, and ROAS. Sends the blended metrics to OpenAI to generate a 3–4 sentence plain-language weekly performance summary. Builds a simple HTML report and sends it to the client via Gmail while posting a short “report sent” summary to a Slack channel. If the workflow execution fails, posts the error message to an ops Slack channel. Setup Add credentials and replace the placeholders for your Meta Ads token and ad

by Redowan Ahmed Farhan
ACDgmail
free

AI: Summarize podcast episode and enhance using Wikipedia

The workflow automates the process of creating a summarized and enriched podcast digest, which is then sent via email. Note that to use this template, you need to be on n8n version 1.19.4 or later.

by n8n Team
ACgmailsheets
free

Recommend supplier consolidation with Google Sheets, Groq, Slack and Gmail

Quick overview This workflow runs weekly to read supplier spend data from Google Sheets, detect overlapping suppliers across departments, estimate potential consolidation savings, and use Groq-hosted LLM analysis to assess risk and produce recommendations that are sent to Slack and emailed via Gmail. How it works Runs every week on a scheduled trigger. Reads supplier records from a Google Sheets spreadsheet and keeps key fields like supplier name, department, spend, risk rating, and stakeholder email. Groups and normalizes supplier names to find suppliers used by multiple departments and calculates estimated savings and an opportunity level. Sends each consolidation opportunity to a Groq chat model to evaluate risk versus savings and return a JSON decision and recommendation. Parses the AI JSON output, merges it with the calculated savings data, and formats a final recommendation record. Posts the recommendation to a Slack channel and emails a formatted report to the supplier stakeholder email address. Setup Connect your Google Sheets OAuth account and update the spreadsheet ID and sheet/tab to match your supplier records. Add a Groq API credential for the chat model used to evalua

by WeblineIndia