Content & SocialFREEVerified · July 18, 2026

Auto-Promote Your Content Library on X Every Day — AI-Written, Never-Repeating Posts

An n8n workflow that reads your sitemap, picks a page it hasn't shared yet, has AI write a fresh angle every time, posts it to X at US prime time, and logs everything to Google Sheets. This exact workflow runs FlowRecipesHub's own X account — you're reading proof that it works.

difficulty Intermediatesetup 30 minresult One unique, AI-written promotional post to X every day, pulled straight from pages you've already published, with zero repeats and zero manual writing.

This isn't a demo. FlowRecipesHub's X account (@flowrecipeshub) is run by this exact JSON — every daily post you see there came from this workflow.

See it live on X
  1. 1

    Set the daily trigger

    Add a Schedule Trigger node set to run once a day at 16:00 on an instance set to Europe/Istanbul — that's 9AM US Eastern, the best slot for B2B/tech content on X. Adjust the cron (or your instance timezone) to match your own audience's prime time.

  2. 2

    Pull every URL from your sitemap

    Add an HTTP Request node pointed at https://YOURSITE.com/sitemap.xml, then a Code node that regex-matches every <loc> tag into a plain list of URLs. This list is your whole content library, refreshed automatically every time the workflow runs — you never maintain it by hand.

  3. 3

    Read the posting log and exclude what's already gone out

    In parallel, add a Google Sheets node reading your log sheet (columns: posted | title | url | description). On this node, turn Settings → Always Output Data ON — without it, the workflow stops dead the first time the log is empty, which happens on the very first run. Filter the sitemap URLs against the log's url column so nothing gets posted twice; this row-per-post history is what stops the whole thing from turning into a spam bot repeating the same three pages.

  4. 4

    Pick one random unposted page

    Add a Code node that takes whatever's left after the exclusion filter and picks a single random entry. One page, one post, once a day — this is what keeps the account feeling like a person sharing things, not a firehose.

  5. 5

    Fetch that page and parse its OG tags

    Add an HTTP Request node for the chosen URL, then a Code node that pulls og:title, og:description, and og:image straight out of the page's <head>. The page's own metadata is the raw material — nothing to write by hand.

  6. 6

    Send it to an LLM that never repeats itself

    Add an HTTP Request node calling https://api.anthropic.com/v1/messages with your Anthropic API key (swap the URL and body for OpenAI's /v1/chat/completions if you prefer — both variants are documented in the node's notes). The system prompt tells the model to randomly pick ONE of five angles every time — pain point, mini story, surprising number, how-it-works one-liner, or hot take — so posts about the same page never read the same way even months apart.

  7. 7

    Post to X

    Add an X (Twitter) node with your OAuth2 credentials, posting the generated text plus the page URL. X unfurls the link using the page's og:image, so the post shows up as a large image card without attaching any media manually. Turn on Retry On Fail (3 tries) on this node so a single API blip doesn't skip your only post of the day.

  8. 8

    Log it so it never repeats

    Add a final Google Sheets node in append mode that writes the url, title, description, and today's date back to the same sheet. That row is the whole trick — it's what makes step 3 possible next time, and it doubles as a plain-English posting history you can skim in five seconds.

Frequently asked questions

Does it work with any CMS?

Yes — anything that outputs a sitemap.xml and sets og:title/og:description/og:image on its pages qualifies. That covers WordPress, Webflow, Ghost, Next.js sites, Shopify, and most static site generators out of the box.

Can it post to LinkedIn too?

Yes — add n8n's LinkedIn node right after the `Parse AI copy` step, feeding it the same generated text and URL. You can run both the X and LinkedIn nodes off the same generated copy, or add a second LLM call with a LinkedIn-specific prompt if you want different phrasing per platform.

Will X ban this account for automation?

One quality post a day with genuinely unique copy each time is normal usage, not spam — it's well within X's free API write limits and doesn't resemble the repost/repeat patterns that get accounts flagged. The anti-repeat log is part of what keeps it looking like a person, not a bot.

What does this actually cost to run?

About $0.001/day if you use a small, cheap model for the copywriting step — under a dollar a year. X's free API tier allows roughly 500 writes a month, which is far more than the one post a day this workflow makes, and Google Sheets and the sitemap fetch are free.

About this recipe. Recipes on FlowRecipesHub are written for business owners, not developers, and are tested before publishing — how recipes get made. Some ingredient links are affiliate links that cost you nothing — full disclosure.