Automation library · AI assistants

AI-powered multi-channel customer journey with SMS and OpenAI

Started by another system calling it, and works across Gmail and Twilio. It hands the judgement calls to OpenAI. 24 steps, 2 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAI

24 stepsLarge: read it before trusting it with anything live
2Branches: places the flow splits
0Loops or waits
2Services it connects to

The flow

Starts it 2Model 6Logic 6Service 10

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

  1. 1Touchpoint Event WebhookWebhookStarts it
  2. 2Journey Optimization ScheduleSchedule triggerStarts it
  3. 3OpenAI Model - State BuilderLm Chat Open AiModel
  4. 4Customer State SchemaOutput Parser StructuredModel
  5. 5OpenAI Model - OptimizerLm Chat Open AiModel
  6. 6Journey Action SchemaOutput Parser StructuredModel
  7. 7Workflow ConfigurationSetLogic
  8. 8Fetch Performance DataHttp RequestService
  9. 9Customer State Builder AIAgentModel
  10. 10Journey Optimizer AIAgentModel
  11. 11Fetch CRM DataHttp RequestService
  12. 12Fetch Email HistoryHttp RequestService
  13. 13Fetch Chat HistoryHttp RequestService
  14. 14Fetch Purchase HistoryHttp RequestService
  15. 15Aggregate Journey ResultsAggregateLogic
  16. 16Journey Stage RouterSwitchLogic
  17. 17Save Customer State to DatabaseHttp RequestService
  18. 18Action Type RouterSwitchLogic
  19. 19Merge Customer DataMergeLogic
  20. 20Update Customer StateSetLogic
  21. 21Send Email CampaignGmailService
  22. 22Send SMS CampaignTwilioService
  23. 23Create Retargeting CampaignGoogle AdsService
  24. 24Log Performance MetricsHttp RequestService

How it's built

Starts on
Another system calling it
Steps
24, with 2 branches
Size
Large: read it before trusting it with anything live
Connects to
Gmail, Twilio
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Gmail and Twilio accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on another system calling it.

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?

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