🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

Gmail to Discord, a daily PDF inbox digest

Lisa Granqvist Partner Workflow Automation Expert

Your inbox isn’t the problem. The constant “did I miss something important?” feeling is. Credentials arrive at random times, deadlines hide inside long threads, and OTPs show up when you’re already in the middle of something else.

This Gmail Discord digest automation hits marketing leads and agency owners hardest, honestly. But ops folks and solo consultants feel it too, because they’re the ones tracking logins, invoices, and last-minute client requests. The outcome is simple: one clean daily PDF brief your team can scan in a minute.

Below, you’ll see exactly what the workflow does, what it replaces, and how to make it your own without turning email into a second job.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: Gmail to Discord, a daily PDF inbox digest

The Problem: Important Emails Get Buried

Important emails don’t arrive neatly labeled “this matters.” They arrive mixed in with newsletters, CC’d threads, calendar noise, and random “quick question” replies. So you scan. Then you scan again later. And if you work with a team, you also forward messages or drop screenshots in chat, which is messy and easy to miss. The real cost isn’t just time. It’s the mental load of remembering what you saw, what you meant to act on, and what you never opened in the first place.

It adds up fast. Here’s where it breaks down in real life.

  • You end the day with 40+ “unread but probably fine” messages that still nag at you.
  • OTPs and credential emails get lost in the scroll, so logins take longer than they should.
  • Deadlines hide inside long email chains, which means tasks get started late.
  • Forwarding “important stuff” to a teammate is inconsistent, so nobody trusts the process.

The Solution: A Daily PDF Digest Posted to Discord

This n8n workflow turns the last 24 hours of important Gmail into a single, readable brief that lands where your team already pays attention: Discord. It runs automatically every day at about 8 PM, pulls messages from your inbox that are marked “INBOX” and “IMPORTANT,” and cleans up the content so it’s not full of broken formatting and ugly tracking URLs. Then an AI summarizer (GPT-4.1-mini) extracts the parts you actually need, like deadlines, action items, credentials, and OTPs. That summary becomes a tidy markdown report, gets rendered into HTML, converted into a professional PDF through PDF.co, and finally posted to your Discord channel via webhook.

The workflow starts on a schedule, not when you remember. Gmail emails are parsed and compiled into a digest-friendly format. AI produces a concise summary with “[Action Required]” callouts, then PDF generation and Discord delivery finish the job.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you receive about 25 “important” emails a day. Manually, you might spend 2 minutes each to open, skim, decide what matters, and forward key ones to a Discord channel or teammate, which is roughly 50 minutes daily. With this workflow, you spend maybe 2 minutes checking the PDF in Discord, then only open the handful that actually require action. The automation runs in the background on schedule, and the “waiting” time doesn’t steal your attention.

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • Gmail to fetch labeled emails via OAuth.
  • Discord to deliver the PDF to a channel.
  • PDF.co API key (get it from your PDF.co dashboard).

Skill level: Intermediate. You’ll connect accounts, paste a webhook URL, and tweak a couple of filters and prompts.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

A daily schedule kicks it off. The workflow runs automatically at about 8 PM and targets the last 24 hours, so you get a true “daily brief” instead of an endless stream of pings.

Gmail emails are retrieved and cleaned up. It pulls messages labeled “INBOX” and “IMPORTANT,” then parses out the useful fields (sender, subject, plain text) while stripping noise like extra whitespace and ugly URLs.

AI summarizes what matters. OpenAI generates a concise digest and flags urgency using “[Action Required],” which is the part most people end up doing manually in their head.

A PDF is generated and posted to Discord. The markdown summary is rendered into HTML, converted to a PDF via PDF.co, then a Discord webhook posts the file (or link) directly into your chosen channel.

You can easily modify the Gmail filters to include specific labels, senders, or keywords based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Schedule Trigger

Set up the daily schedule that initiates the workflow.

  1. Add or open Scheduled Daily Trigger.
  2. Set the schedule rule to run at triggerAtHour 20.
  3. Confirm Scheduled Daily Trigger outputs to Retrieve Recent Emails.

Step 2: Connect Gmail and Retrieve Messages

Pull emails from Gmail with specific labels and a 24-hour window.

  1. Add or open Retrieve Recent Emails.
  2. Credential Required: Connect your gmailOAuth2 credentials.
  3. Set Operation to getAll and Return All to true.
  4. Set Label IDs to INBOX and IMPORTANT.
  5. Set Received After to ={{$now.minus({days: 1}).toISO()}}.
  6. Connect Retrieve Recent Emails to Parse Mail Sections.

Step 3: Set Up Email Parsing and Aggregation

Extract clean, readable fields from the raw Gmail payloads and aggregate them for summarization.

  1. Open Parse Mail Sections and keep the provided JavaScript in jsCode as-is.
  2. Open Compile Mail Fields and set Include to specifiedFields.
  3. Set Aggregate to aggregateAllItemData.
  4. Set Fields to Include to subject, from, plainText.
  5. Confirm the flow Parse Mail SectionsCompile Mail Fields.

⚠️ Common Pitfall: If Gmail messages are HTML-only, the parsing logic may return empty plainText. Add HTML parsing or adjust Gmail settings if needed.

Step 4: Set Up AI Summarization and Formatting

Use the AI chain to summarize the aggregated emails into plain text and Markdown, then split the output for downstream use.

  1. Open Summarize Mail Digest and confirm the prompt under summarizationMethodAndPrompts is set to the provided text.
  2. Ensure OpenAI Chat Engine is connected as the language model for Summarize Mail Digest.
  3. Credential Required: Connect your openAiApi credentials in OpenAI Chat Engine (not in Summarize Mail Digest).
  4. Open Split Text and Markdown and keep the JavaScript that parses PLAIN TEXT and MARKDOWN sections.
  5. Confirm the flow Compile Mail FieldsSummarize Mail DigestSplit Text and Markdown.

Step 5: Generate PDF and Post to Discord

Convert the Markdown digest to HTML, render a PDF, fetch its URL, and post the plain-text summary to Discord.

  1. Open Render Markdown to HTML and set Mode to markdownToHtml.
  2. Set Markdown to = {{ $json.markdown }}.
  3. Open Generate PDF via PDFco and set Operation to URL/HTML to PDF and Convert Type to htmlToPDF.
  4. Set HTML to ={{ $json.data }}.
  5. Credential Required: Connect your pdfcoApi credentials.
  6. Open Fetch PDF Link and set URL to ={{ $json.url }}.
  7. Open Post Discord Update and set Authentication to webhook.
  8. Set Content to = {{ $('Split Text and Markdown').item.json.plainText }}.
  9. Credential Required: Connect your discordWebhookApi credentials.
  10. Confirm the flow Split Text and MarkdownRender Markdown to HTMLGenerate PDF via PDFcoFetch PDF LinkPost Discord Update.

⚠️ Common Pitfall: If Post Discord Update posts an empty message, verify that Summarize Mail Digest outputs both sections and that Split Text and Markdown matches the expected headings.

Step 6: Test and Activate Your Workflow

Run a manual test to confirm that emails are summarized, a PDF is generated, and a Discord message is sent.

  1. Click Execute Workflow to run the flow once.
  2. Verify Retrieve Recent Emails returns messages from the last day and that Parse Mail Sections extracts subject, from, and plainText.
  3. Confirm Summarize Mail Digest produces both plain text and markdown outputs, and Split Text and Markdown splits them correctly.
  4. Check Generate PDF via PDFco returns a URL and that Post Discord Update posts the plain text digest to your Discord channel.
  5. Toggle the workflow to Active for daily production use.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Gmail OAuth credentials can expire or need specific permissions. If things break, check the Gmail credential status inside n8n and re-authenticate the connected Google account first.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Discord webhooks get rotated or deleted more often than people expect. If the PDF stops posting, verify the webhook URL in your Discord server settings and update it in the “Post Discord Update” step.

Frequently Asked Questions

How long does it take to set up this Gmail Discord digest automation?

About 30 minutes if your Gmail and Discord accounts are ready.

Do I need coding skills to automate a Gmail Discord digest?

No. You will connect credentials and tweak a few settings in n8n.

Is n8n free to use for this Gmail Discord digest workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in OpenAI API costs (often a few cents per day for a single daily digest) and PDF.co usage based on your PDF volume.

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I customize this Gmail Discord digest workflow for a different label or schedule?

Yes. You can change the schedule in the “Scheduled Daily Trigger,” then adjust the Gmail search in “Retrieve Recent Emails” to target other labels, senders, or keywords. Many teams add a “VIP” label for client emails, or exclude newsletters completely. You can also tweak the summarization prompt in “Summarize Mail Digest” so it matches your brand voice and highlights only what you care about.

Why is my Gmail connection failing in this workflow?

Usually it’s expired Google OAuth authorization in n8n or the connected account lost permission. Reconnect the Gmail credential in n8n, then re-run the workflow. Also confirm the Gmail node is allowed to read the labels you’re filtering on, because label mismatches can look like “no data” failures. If you’re pulling a lot of mail, Google can throttle requests briefly, so retrying a few minutes later may succeed.

How many emails can this Gmail Discord digest automation handle?

A typical setup handles dozens to a few hundred emails per day comfortably, and the limiting factor is usually API rate limits and PDF generation volume. On n8n Cloud, your monthly execution allowance depends on your plan; self-hosting has no execution cap, but your server still has to do the work. If you expect heavy volume, filter aggressively (labels, senders, keywords) so the digest stays readable.

Is this Gmail Discord digest automation better than using Zapier or Make?

Often, yes, because this is more than “send email to Discord.” You’re doing parsing, cleanup, AI summarization, markdown-to-HTML rendering, PDF generation, and then posting the final artifact, which gets expensive or awkward in simpler tools. n8n also gives you branching and custom logic without nickel-and-diming you for every extra step. Zapier or Make can still work if you only want a basic notification, not a real digest. If you’re unsure, Talk to an automation expert and get a quick recommendation.

Once this is running, your inbox stops being a hiding place for urgent work. You get one daily brief in Discord, and the rest of your day feels a lot more manageable.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal