Automation library · Content

Generate AI News LinkedIn Posts with OpenAI and NewsAPI

Started by a clock, and works across Gmail, Google Sheets and Qdrant. It puts OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 25 steps, 1 branch: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAIRetrieval

25 stepsLarge: read it before trusting it with anything live
1Branch: places the flow splits
0Loops or waits
3Services it connects to

The flow

Starts it 2Model 5Logic 10Service 8

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

  1. 1Schedule TriggerSchedule triggerStarts it
  2. 2Gmail TriggerGmail triggerStarts it
  3. 3OpenAI Chat ModelLm Chat Open AiModel
  4. 4Structured Output ParserOutput Parser StructuredModel
  5. 5Generate Vector EmbeddingsEmbeddings Open AiModel
  6. 6Set Linkedin IdSetLogic
  7. 7Set Input Data (Topic/Company/Tone)SetLogic
  8. 8Retrieve the messageGoogle SheetsService
  9. 9confirmationGmailService
  10. 10Generate Linkedin PostsAgentModel
  11. 11RetrievePostExamplesVector Store QdrantModel
  12. 12Merge1MergeLogic
  13. 13News APIHttp RequestService
  14. 14UnreadGmailService
  15. 15Capture Email DecisionSetLogic
  16. 16FormatLinkedInPayloadCodeLogic
  17. 17Publish LinkedIn PostHttp RequestService
  18. 18Split ArticlesCodeLogic
  19. 19Gmail1GmailService
  20. 20MergeMergeLogic
  21. 21Send Email with News ArticlesGmailService
  22. 22Edit Fields1SetLogic
  23. 23IfIfLogic
  24. 24Log Email ActivityGoogle SheetsService
  25. 25ExtractLatestEmail2CodeLogic

How it's built

Starts on
A clock
Steps
25, with 1 branch
Size
Large: read it before trusting it with anything live
Connects to
Gmail, Google Sheets, Qdrant
Model
OpenAI
Retrieval
Answers are drawn from documents you supply, not from the model alone

Questions

What does it need to run?

An n8n account, plus your own Gmail, Google Sheets and Qdrant 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. Its answers draw on documents you give it, not on the model alone. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 25 steps it is large: read it before trusting it with anything live.

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 25 steps before you point it at anything that matters.