Automation library · Content

Send article digests from Discord to Gmail with OpenAI

Started by a clock, and works across Discord, Gmail and Google Sheets. It hands the judgement calls to OpenAI. 20 steps, 2 branches: a working afternoon to understand properly.

MediumCalls a model: OpenAI

20 stepsMedium: a working afternoon
2Branches: places the flow splits
0Loops or waits
3Services it connects to

The flow

Starts it 1Model 1Logic 6Service 12

The steps in the order they run, from what starts it.

  1. 1Every 15 MinutesSchedule triggerStarts it
  2. 2Get Discord MessagesDiscordService
  3. 3Process MessagesCodeLogic
  4. 4Route by TypeSwitchLogic
  5. 5Get Existing URLsGoogle SheetsService
  6. 6Get Unsent RowsGoogle SheetsService
  7. 7Filter New URLsCodeLogic
  8. 8Build DigestCodeLogic
  9. 9Fetch ArticleHttp RequestService
  10. 10Has Digest ContentIfLogic
  11. 11Analyze ArticleOpen AiModel
  12. 12Post Ingestion ErrorDiscordService
  13. 13Send Digest EmailGmailService
  14. 14Digest Empty NoticeDiscordService
  15. 15Save ArticleGoogle SheetsService
  16. 16Expand Rows To UpdateCodeLogic
  17. 17Digest Error NoticeDiscordService
  18. 18Confirm SavedDiscordService
  19. 19Mark Rows SentGoogle SheetsService
  20. 20Confirm Digest SentDiscordService

How it's built

Starts on
A clock
Steps
20, with 2 branches
Size
Medium: a working afternoon
Connects to
Discord, Gmail, Google Sheets
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Discord, Gmail and Google Sheets accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on a clock.

Does it use AI?

Yes. It calls OpenAI. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Plan an afternoon. 20 steps is enough that you should read each one before running it.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 20 steps before you point it at anything that matters.