Automation library · Content

Automated blog publishing with Google Trends and OpenAI

Started by a clock, and works across Google Sheets and WordPress. It hands the judgement calls to OpenAI. 20 steps, 1 loop or waits: a working afternoon to understand properly.

MediumCalls a model: OpenAI

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

The flow

Starts it 1Model 3Logic 6Service 10

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

  1. 1Structured Output ParserOutput Parser StructuredModel
  2. 2OpenAI Chat ModelLm Chat Open AiModel
  3. 3Schedule TriggerSchedule triggerStarts it
  4. 4AI AgentAgentModel
  5. 5Main ConfigSetLogic
  6. 6Update row in sheetGoogle SheetsService
  7. 7GoogleTrendsHttp RequestService
  8. 8Search Pexels ImageHttp RequestService
  9. 9XMLXmlLogic
  10. 10Cleanup the AICodeLogic
  11. 11Filter Scraped KeywordsCodeLogic
  12. 12Create posts on WordpressWordpressService
  13. 13Loop Over ItemsSplit In BatchesLogic
  14. 14Add watermark to imageHttp RequestService
  15. 15Get row in sheetGoogle SheetsService
  16. 16Append or update row in sheetGoogle SheetsService
  17. 17Upload mediaHttp RequestService
  18. 18Grab one random keywordCodeLogic
  19. 19Set image ID for the postHttp RequestService
  20. 20Update image metadataHttp RequestService

How it's built

Starts on
A clock
Steps
20, 1 loop or waits
Size
Medium: a working afternoon
Connects to
Google Sheets, WordPress
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Google Sheets and WordPress 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.