Auto Estate Generator

Automatic n8n pipeline that retrieves content from emails and industry links, decodes DOCX/HTML attachments, translates and cleans texts using OpenAI models, then creates ready-formatted posts/records in Notion for Estate FM.

Auto Estate Generator Project

Overview

The workflow starts with Gmail Trigger, fetches full email content with attachments, detects article links, resolves tracking URLs (e.g., ses.prsts.de/CL0/), and fetches clean innerText through an API fetcher. Two LLM paths then translate and organize the text (a "clean summary" version and a "LinkedIn with emoji" version), after which texts are composed, split into parts, and saved to Notion database as ContentPart1..4 with title and date preserved.

The pipeline also handles DOCX attachments: changes metadata to ZIP, unpacks, extracts document.xml, converts XML paragraphs to clean text, decodes entities, and passes to translation.

Technology Stack

  • n8n: Gmail Trigger, HTTP Request, Code (Node.js), Merge, Compression, Extract from File, Notion node, LangChain LLM, Structured Output Parser
  • AI: OpenAI gpt-4o-mini for PL→EN translation and LinkedIn post formatting
  • Notion API: Automatic page creation (Title, Date, ContentPart1..4)

Key Features

  • Intelligent link detection and cleaning: parsing href/onclick/data-href, filtering tracking domains, decoding ses.prsts.de to destination URL
  • Content extraction: fetching innerText via external fetcher; DOCX→XML→text support
  • Two LLM layers: clean business translation and structured LinkedIn version with emoji, ISO date, and header
  • Notion publication: splitting long text into 2–4 parts and saving properties with metadata
  • Direct DOCX processing from email attachments without manual conversion

Results & Outcomes

  • Elimination of manual copying/formatting: ready posts in Notion in English
  • Higher consistency: uniform newsroom style and automatic date normalization
  • Seamless DOCX handling: direct processing from email attachments

Visualizations

n8n Workflow Diagram

Complete workflow showing main branches (Gmail, Link Decode, Fetch, LLM, Notion) and DOCX processing pipeline

n8n Workflow Diagram — Gmail Trigger, DOCX parsing, OpenAI translation, Notion output

← Back to Projects


Related Projects