# Automated workflow backup with GitHub: n8n workflow template

> Started by a clock, and works across GitHub and Telegram. 28 steps, 4 branches, 1 loop or waits: large, and worth reading before you trust it with anything...

Source: https://millionrounds.com/workflow/automated-workflow-backup-with-github (Millionrounds; every figure on the page links to its filing or article)

[Automation library](https://millionrounds.com/workflows) · [Documents and files](https://millionrounds.com/workflows?category=Documents+and+files#library)

# Automated workflow backup with GitHub

Started by a clock, and works across GitHub and Telegram. 28 steps, 4 branches, 1 loop or waits: large, and worth reading before you trust it with anything live.

Large

[Download free](https://millionrounds.com/login?next=%2Fapp%2Fworkflow%2Fautomated-workflow-backup-with-github)

**28 steps** Large: read it before trusting it with anything live

**4** Branches: places the flow splits

**1** Loop or waits

**2** Services it connects to

## The flow

Starts it 1 Logic 19 Service 8

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

- 1 **Schedule Trigger** Schedule trigger *Starts it*
- 2 **Configuration** Set *Logic*
- 3 **Assert GitHub config** If *Logic*
- 4 **Get all workflows** N8n *Service*
- 5 **List files** Github *Service*
- 6 **Stop on empty config** Stop And Error *Logic*
- 7 **Encode N8N workflows** Code *Logic*
- 8 **Get files** Github *Service*
- 9 **Merge** Merge *Logic*
- 10 **Extract workflow parameters** Code *Logic*
- 11 **Loop Over Items** Split In Batches *Logic*
- 12 **Is Telegram configured?** If *Logic*
- 13 **Decide changes** Code *Logic*
- 14 **Build summary arrays** Code *Logic*
- 15 **Router** Switch *Logic*
- 16 **Anything changed?** If *Logic*
- 17 **Delete old file** Github *Service*
- 18 **Merge after delete (rename)** Merge *Logic*
- 19 **Update file content and commit** Github *Service*
- 20 **Merge after update** Merge *Logic*
- 21 **Create new file** Github *Service*
- 22 **Merge after create** Merge *Logic*
- 23 **No Operation, do nothing** No Op *Logic*
- 24 **Stop and Error** Stop And Error *Logic*
- 25 **Render summary** Code *Logic*
- 26 **Merge after create (rename)** Merge *Logic*
- 27 **Create new file (rename)** Github *Service*
- 28 **Send a message** Telegram *Service*

## How it's built

- **Starts on:** A clock
- **Steps:** 28, with 4 branches, 1 loop or waits
- **Size:** Large: read it before trusting it with anything live
- **Connects to:** GitHub, Telegram
- **Model:** None. This is plumbing, not judgement

## Questions

What does it need to run?

An n8n account, plus your own GitHub and Telegram accounts. You connect your own accounts after importing it; none are included.

What starts it?

It starts on a clock.

Does it use AI?

No. Every step is fixed logic or a call to a service, so it does the same thing every time.

How long does it take to set up?

Take your time. At 28 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 28 steps before you point it at anything that matters.

## Run it in n8n

- **Create your n8n account** Free to start. n8n is where the workflow runs. [Create an n8n account ↗](https://millionrounds.com/n8n)
- **Download the workflow** Free with a Millionrounds account. [Download free](https://millionrounds.com/login?next=%2Fapp%2Fworkflow%2Fautomated-workflow-backup-with-github)
- **Paste it into n8n** Open a new workflow in n8n and paste. Then connect your own accounts.

Stored with the author's traces removed: canvas notes, instance identifiers, saved credential names and any live document they had left behind.

## Connects to

Each opens the other workflows that use it.

[GitHub](https://millionrounds.com/workflows?service=GitHub#library)[Telegram](https://millionrounds.com/workflows?service=Telegram#library)

## Workflows like it

Also documents and files, with the same services where possible, closest in size first.

- [**Provide academic OCR and RAG answers on Telegram with Gemini** 28 steps · calls a model · Google Drive, Google Sheets](https://millionrounds.com/workflow/provide-academic-ocr-and-rag-answers-on-telegram-with-gemini)
- [**Automated n8n workflow backup to GitHub** 27 steps · GitHub](https://millionrounds.com/workflow/automated-n8n-workflow-backup-to-github)
- [**Backup n8n workflows to GitHub with Discord** 27 steps · Discord, GitHub](https://millionrounds.com/workflow/backup-n8n-workflows-to-github-with-discord)
- [**Extract text from Google Drive files to Google Sheets** 25 steps · Google Docs, Google Drive](https://millionrounds.com/workflow/extract-text-from-google-drive-files-to-google-sheets)
- [**Extract text from images & PDFs with Telegram and Mistral** 32 steps · Telegram](https://millionrounds.com/workflow/extract-text-from-images-and-pdfs-with-telegram-and-mistral)
- [**PDF RAG agent with Telegram** 32 steps · calls a model · Google Drive, Telegram](https://millionrounds.com/workflow/pdf-rag-agent-with-telegram)
