الدرس 1 · الوحدة 2: Your First Working AI Automation
Triggers, nodes and data flow: reading a no-code workflow in n8n
الفيديو قريبًا
Learn it with your tutor on the live board
أهم نقاط الفيديو
The inbox that never sleeps
- A small studio gets 40 messages a day
- Each one is copied, sorted and answered by hand
- One missed lead is lost money
- Automation moves this work to a workflow
What you will learn
- Spot the trigger that starts a workflow
- Name what each node does to the data
- Follow one item from start to finish
Meet n8n
- A visual tool for building workflows
- Free to self-host, or a paid cloud version
- Boxes on a canvas, joined by arrows
- Over 400 built-in app connections
The trigger starts everything
- Form trigger: someone submits your contact form
- Webhook: another app pings a URL
- Schedule: every Monday at 9am
- App event: a new row, email or payment
A workflow as a workshop
- Trigger: the request drops in
- Nodes: one worker, one job each
- Output: something leaves the workflow
Data travels as items
items = [
{"name": "Sara", "service": "logo", "budget": 300},
{"name": "Omar", "service": "website", "budget": 1200},
]
for item in items:
item["priority"] = "high" if item["budget"] >= 1000 else "normal"
print(item["name"], "->", item["priority"]) Expressions pull data forward
- Double curly braces mean "fill this in"
- $json is the current item's fields
- Green: n8n can fill it in; red: it cannot
To: {{ $json.email }}
Subject: Thanks, {{ $json.name }}!
Body: We got your {{ $json.service }} request. Worked example: Lina's lead flow
- Form trigger catches the request
- Set node cleans the fields
- IF node checks budget at least 1000
- True: add to Sheets and alert Lina
- False: send a polite auto-reply
Reading the execution log
- Every run is saved as an execution
- Click a node to see items in and out
- Green check: ran fine; red: failed here
- Item counts show where data went
Common mistake: one node, many runs
- A node runs once for every item
- 20 rows in means 20 emails out
- Check item counts before the email node
- Use Limit or Aggregate when you want one
Recap
- A trigger starts each workflow
- Nodes each do one job on the items
- Curly-brace expressions show which fields a node uses
- Follow items and counts to read any flow
Your exercise
- Open n8n templates and pick a lead or booking flow
- Name its trigger and every node's job
- Mark which fields each expression uses
- Count the email or message nodes
النص المكتوب
The inbox that never sleeps. Picture Lina, a freelance designer who runs a small online studio. Every day around forty messages land in her inbox through her contact form, email and Instagram. She copies each name into a spreadsheet, decides whether it's a real lead, and writes a reply. Last month one big website request sat unread for three days, and the client hired someone else. That's the problem automation solves. A workflow can catch every one of those messages the moment it arrives and do the copying for her. But before you build one, you need to read one. Today you'll learn to look at a workflow on screen and know exactly what it does.
What you will learn. Here's our map for this lesson. First, you'll learn to spot the trigger, the event that starts a workflow running. Second, you'll learn to read the nodes, the small boxes that each do one job, and say in plain words what each one does. Third, and most important, you'll learn to follow the data, one customer's details, as it travels from box to box. Once you can do those three things, any workflow someone sends you, from a template site or from a client's old setup, stops being a mystery. You'll read it the way you read a recipe.
Meet n8n. The tool we'll use all course is n8n, pronounced "n eight n". It's a workflow builder where you drag boxes onto a canvas and join them with arrows instead of writing code. You can run it free on your own computer or server, or pay for their hosted cloud version. It already knows how to talk to over four hundred apps, like Gmail, Google Sheets, Slack and Stripe. Other tools such as Zapier and Make use the same trigger-and-steps idea, so most of what you learn here carries over. If you've never opened it, that's fine. Today we're only reading.
The trigger starts everything. Every workflow starts with a trigger, and most have just one. Think of it as the shop doorbell. Nothing happens until it rings, and when it does, work begins. In n8n the trigger is the first box on the left, usually with a small lightning bolt. The most common one is a form trigger, which fires when a customer submits your contact form. There's also the webhook. A webhook is just a web address that waits for another app to send it a message, like a letterbox with its own address. When another app drops a note in that letterbox, your workflow wakes up. A schedule runs the workflow at set times, like every Monday morning to send a sales report. And an app event fires when a new row, email or payment appears in a connected app, for example when Stripe records a payment.
A workflow as a workshop. Let's walk through a workflow as if it were a tiny workshop. On the left is the Trigger, the inbox tray where a new customer request drops in. Then the paper moves to the middle, to a Node. A node is one worker with one job: stamp it, sort it, look something up, or ask an AI to summarize it. Real workflows have several nodes in a row, each passing its paper to the next. Finally, on the right, the Output, where something leaves the workshop: an email to the client, a new row in a sheet, or a booking in a calendar. Trigger, nodes, output. Every workflow you'll ever read is this shape.
Data travels as items. Now slow down, because this is the key idea. What moves along the arrows is data, and n8n packs it as a list of items. An item is one record, like one customer request. Each item is stored as JSON, which is simply labelled fields, a name next to a value, like a filled-in form: name Sara, service logo, budget three hundred. This little Python code imitates one node. It takes two items, adds a new field called priority, and passes them on. The for line means do this for each item, and the next line sets priority to high when the budget is one thousand or more, otherwise normal. Sara stays normal, Omar becomes high. That's exactly what an n8n node does: items in, the same items with changes out.
Expressions pull data forward. How does the email node know Sara's address? Through expressions. An expression is a blank in a template that n8n fills in from the item. You write it between double curly braces. Dollar sign json means the fields of the item that just arrived, so dollar json dot email becomes Sara's email, and dollar json dot name becomes Sara. It's the same idea as mail merge in a word processor. In the expression editor, a field that n8n can fill in turns green, and one it cannot find turns red. When you read a workflow, open each node and look for these curly braces. They tell you exactly which data that node depends on, and where it came from.
Worked example: Lina's lead flow. Let's read a real workflow for Lina. It starts with a form trigger, so it runs whenever someone fills in her contact form. Next, a Set node tidies the fields: it keeps only name, email, service and budget, and gives them clean names. Then comes an IF node, a fork in the road. It asks one question: is the budget at least one thousand? So where does Omar go with his twelve hundred? He takes the yes branch, gets added to a Google Sheet, and Lina gets an alert. Sara's three hundred takes the no branch and gets a friendly auto-reply. Six boxes, and you can now explain every one.
Reading the execution log. Here's the shortcut most beginners miss: n8n records every run for you. Each run is called an execution, and you can open any of them. Click a node and you'll see two panels, the items that came in and the items that went out. A green check mark means that node did its job, and a red mark shows exactly where things broke. Look at the small numbers on the arrows too. If ten items enter the IF node and three come out the yes side, you know three leads were big ones. Reading executions is how you check a workflow does what you think.
Common mistake: one node, many runs. Here's the trap that catches almost everyone. A node runs once for every item it receives. Imagine Lina builds a Monday sales report that reads twenty orders from her sheet, then sends an email. She expects one summary email. Instead her inbox fills with twenty envelopes, one per order, and Lina is left staring at twenty emails. The fix is to read the item count on the arrow going into any email or message node. If it's more than one and you want a single message, add an Aggregate node first, which squeezes many items into one, or a Limit node to keep just the first.
Recap. Let's pull it together. First, every workflow starts with a trigger, the doorbell. Second, nodes are workers with one job each, and expressions in curly braces show which fields they use. Third, data travels as items, and the fastest way to understand any workflow is to follow one item through it and watch the counts on the arrows. With just these three ideas, you can already read the lead flow we walked through and spot the twenty email trap before it happens.
Your exercise. Before the next lesson, try this. Go to the n8n templates library and pick one workflow about leads, bookings or customer messages. Don't build anything yet. In your notebook, write down its trigger, then one plain sentence for each node saying what it does. Next, open the nodes and note which fields their curly brace expressions use. Finally, find every node that sends an email or message and ask yourself how many items reach it. In the next lesson you'll build Lina's lead capture flow yourself, from web form to Google Sheets to email.
ملخص الدرس
- مشاهدة الفيديو
- A trigger starts each workflow
- Nodes each do one job on the items
- Curly-brace expressions show which fields a node uses
- Follow items and counts to read any flow