Templates / Route farmer SMS intents using OpenAI GPT-4.1-mini classification

Route farmer SMS intents using OpenAI GPT-4.1-mini classification

Ready for 3.0

by Alassane ✓ · 5 views · created 2026-07-03 · Support Chatbot, AI Chatbot

Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 49 nodes and runs when an HTTP POST request hits its webhook URL. Along the way it connects OpenAI.

How it runs

Trigger: When an HTTP POST request hits its webhook URL.

  1. Normalize Incoming SMS (Edit Fields (Set)): sets 4 fields: phone, message_text, received_at…
  2. Lookup Farmer (Code): runs custom JavaScript code
  3. Merge: merges the data from its input branches
  4. Farmer Exists (If): checks a condition and branches into true / false
  5. Route SMS Intent (Switch): routes items into 7 branches
  6. Is Registration Message? (If): checks a condition and branches into true / false
  7. Get Weather Forecast (Code): runs custom JavaScript code
  8. Build Fire Reply (Code): runs custom JavaScript code
  9. Lookup Seed Suppliers (Code): runs custom JavaScript code
  10. Lookup Equipment Suppliers (Code): runs custom JavaScript code

…plus 38 more steps. See the full node list below.

Services it uses

OpenAI

Before you upgrade to n8n 3.0

Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.

Nodes used (7)

From the author

Quick overview This demo workflow receives an SMS-style request through a webhook, routes common farmer commands while it uses OpenAI for unknown messages. It is designed for African SMS-first farming contexts but can be adapted anywhere. How it works 1.…

Excerpt from Alassane 's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.