# WhatsApp to Chatwoot message forwarder with Postgres and Redis: n8n workflow

> Started by an event in a connected app, and works across Postgres and Redis. 31 steps, 8 branches, 1 loop or waits: large, and worth reading before you...

Source: https://millionrounds.com/workflow/whatsapp-to-chatwoot-message-forwarder-with-postgres-and-red (Millionrounds; every figure on the page links to its filing or article)

[Automation library](https://millionrounds.com/workflows) · [Customer support](https://millionrounds.com/workflows?category=Customer+support#library)

# WhatsApp to Chatwoot message forwarder with Postgres and Redis

Started by an event in a connected app, and works across Postgres and Redis. 31 steps, 8 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%2Fwhatsapp-to-chatwoot-message-forwarder-with-postgres-and-red)

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

**8** Branches: places the flow splits

**1** Loop or waits

**2** Services it connects to

## The flow

Starts it 1 Logic 18 Service 12

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

- 1 **When Executed by Another Workflow** Execute Workflow trigger *Starts it*
- 2 **Wait** Wait *Logic*
- 3 **PARAMETERS** Set *Logic*
- 4 **CODE - MESSAGE OBJECT** Code *Logic*
- 5 **TIPO MENSAGEM VÁLIDO?** If *Logic*
- 6 **IS THE PHONE NUMBER VALID?** If *Logic*
- 7 **REDIS - EVOLUTION MSG - GET** Redis *Service*
- 8 **MESSAGE SENT?** If *Logic*
- 9 **REDIS - EVOLUTION MSG - SET** Redis *Service*
- 10 **LOAD CONTACT** Chat Woot *Service*
- 11 **IS THERE CONTACT ON CHATWOOT?** If *Logic*
- 12 **EXISTING CONTACT CODE** Set *Logic*
- 13 **CREATE CONTACT** Chat Woot *Service*
- 14 **CONTACT - ID** Set *Logic*
- 15 **NEW CONTACT CODE** Set *Logic*
- 16 **Get Conversations** Postgres *Service*
- 17 **IS THERE CONVERSATION ON CHATWOOT?** If *Logic*
- 18 **EXISTING CONVERSATION CODE** Set *Logic*
- 19 **CREATE CONVERSATION** Chat Woot *Service*
- 20 **CONVERSATION - ID** Set *Logic*
- 21 **NEW CONVERSATION CODE** Set *Logic*
- 22 **WAS IT THE NUMBER ITSELF THAT IS CONNECTED TO EVOLUTION THAT SENT THE MESSAGE?** If *Logic*
- 23 **SEND OUTGOING MESSAGE** Chat Woot *Service*
- 24 **SEND INCOMING MESSAGE** Chat Woot *Service*
- 25 **SENT FILE?** If *Logic*
- 26 **EVOLUTION - GET FILE** Evolution Api *Service*
- 27 **CHECK FILE TYPE** Switch *Logic*
- 28 **BASE64** Code *Logic*
- 29 **SEND OUTGOING MESSAGE EXTENSION NOT ALLOWED** Chat Woot *Service*
- 30 **Convert to File** Convert To File *Service*
- 31 **SEND CHATWOOT FILE** Http Request *Service*

## How it's built

- **Starts on:** An event in a connected app
- **Steps:** 31, with 8 branches, 1 loop or waits
- **Size:** Large: read it before trusting it with anything live
- **Connects to:** Postgres, Redis
- **Model:** None. This is plumbing, not judgement

## Questions

What does it need to run?

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

What starts it?

It starts on an event in a connected app.

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 31 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 31 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%2Fwhatsapp-to-chatwoot-message-forwarder-with-postgres-and-red)
- **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.

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

## Workflows like it

Also customer support, with the same services where possible, closest in size first.

- [**Advanced Telegram bot, ticketing system, liveChat, user** 31 steps · Redis, Telegram](https://millionrounds.com/workflow/advanced-telegram-bot-ticketing-system-livechat-user)
- [**Automate B2B SaaS renewal risk management with CRM** 30 steps · Gmail, HubSpot](https://millionrounds.com/workflow/automate-b2b-saas-renewal-risk-management-with-crm)
- [**Answer FAQs and route Telegram users to support with Postgres** 29 steps · Postgres, Telegram](https://millionrounds.com/workflow/answer-faqs-and-route-telegram-users-to-support-with-postgre)
- [**Answer HR questions with OpenAI and PostgreSQL** 26 steps · calls a model · Pinecone, Postgres](https://millionrounds.com/workflow/answer-hr-questions-with-openai-and-postgresql)
- [**WhatsApp AI customer service chatbot – handles text, voice** 37 steps · calls a model · Google Drive, Postgres](https://millionrounds.com/workflow/whatsapp-ai-customer-service-chatbot-handles-text-voice)
- [**Auto-reply to FAQs on WhatsApp with Postgres** 22 steps · Postgres, WhatsApp](https://millionrounds.com/workflow/auto-reply-to-faqs-on-whatsapp-with-postgres)
