Updated . Built against the tool’s current screens and checked step by step. How we check this lesson
A homeowner's furnace is blowing cold air and the house is at 58 degrees. Your form should know that is an emergency. In this free lesson you build a service request form for Cedar Ridge Heating & Air in Lovable and connect it to an n8n AI agent that sorts the job, saves the lead to Google Sheets and emails a confirmation.
At a glance
| Question | Answer |
|---|---|
| What you build | Build a service request form in Lovable for Cedar Ridge Heating & Air and connect it to n8n — the AI agent sorts each job into repair, maintenance, install or emergency, saves the lead to Google Sheets and emails a confirmation. |
| Tools | Lovable and n8n |
| Time | About 15 minutes, 93 steps in 15 parts |
| Level | Advanced |
| Cost | Free |
| Ways to learn it | Practice it step by step, watch the video |
The 15 parts, in short
- Sign up: Get started with Lovable.
- Build the form: Click the prompt box, Describe the form, Open the mode picker, Keep Build mode, and 1 more step.
- New workflow: Start a new workflow.
- Webhook trigger: Add the first step, Webhook trigger, Change the response mode, Use a Respond node, and 1 more step.
- AI Agent: Add the next node, Add the AI Agent, Change the prompt source, Define it manually, and 5 more steps.
- Chat model: Give the agent a brain, Pick OpenAI, Open the credentials, Create a new credential, and 5 more steps.
- Sheets tool: Add a tool, Add Google Sheets.
- Create the spreadsheet: Back to the canvas, Open Google Sheets, Name the spreadsheet, Type the first column header, and 5 more steps.
- Sheets tool: Add a credential, Create a new credential, Sign in with Google, Choose your account, and 13 more steps.
- Gmail tool: Add another tool, Add Gmail, Add a credential, Create a new credential, and 10 more steps.
- Respond node: Add the respond node, Respond to Webhook, Back to the canvas.
- Publish: Publish the workflow.
- Add the secret: Open the webhook, Production URL, Copy the URL, Back to the canvas, and 7 more steps.
- Test the form: Open the form, Fill the form, Submit the form.
- Publish the app: Open Publish, Publish, Check the spreadsheet.
Start here first: Lovable + n8n: Build a Web App with an AI Backend. This HVAC version follows the same build with its own example business.
Build an AI Service Request Form for Your HVAC Company: video walkthrough
The whole lesson in 8:59, narrated step by step.
Simulated practice environment. Recorded in Stepthrough’s simulated practice environment, not the live tool. Practice it yourself free at learn.ynteractive.com.
Chapters
Click a chapter to jump the video there.
- 0:00 Intro: what you'll build
- 0:12 Sign up
- 0:26 Build the form
- 0:59 New workflow
- 1:11 Webhook trigger
- 1:55 AI Agent
- 3:12 Chat model
- 3:51 Sheets tool
- 4:05 Create the spreadsheet
- 4:44 Sheets tool
- 5:51 Gmail tool
- 6:44 Respond node
- 7:09 Publish
- 7:21 Add the secret
- 8:21 Test the form
Now do it yourself, free
Watching is the warm-up. The interactive lesson puts you in a practice copy of Lovable and n8n: you do every step yourself, it checks your work, and “Do it for me” finishes any step you get stuck on. Nothing touches your real accounts.
Practice “Build an AI Service Request Form for Your HVAC Company” step by stepFull transcript
Intro: what you'll build
0:00 It all comes together. A service request, form, in Lovable, proceed to ridge heating in air. Then an AI agent sorts each job, saves it to Google Sheets, and emails a confirmation. Let's build it.
Sign up
0:11 In the first module you built a Custom GPT. In the second, you built an AI agent inside n8n. Now you are going to combine a real web app with an AI-powered backend. Lovable is a tool that builds web apps from a text description. Click get started for free.
Build the form
0:26 This is your Lovable dashboard. Every project you build shows up here. Click start with a prompt to create a new one.
0:33 This prompt tells Lovable what to build: a clean service request form with name, email, what the customer needs, and phone, sending each request to an n8n webhook URL pulled from a secret config — not hardcoded. Click paste prompt.
0:47 Click build. Lovable reads your prompt, generates the code, and deploys a live web app. In a few seconds you have a working service request form. Now we build the AI workflow that handles each request.
New workflow
0:59 Now you are in n8n. This is the workflow automation tool you used in the last module. This time, instead of a chat trigger, we are going to use a webhook — so the form can send data directly to n8n. Click create workflow.
Webhook trigger
1:10 Every workflow starts with a trigger. Last time we used a chat trigger. This time we want a webhook — an HTTP endpoint the form can POST to. Click add first step.
1:20 On webhook call. A webhook is just a URL that waits for incoming data. When a homeowner submits the form, it sends their name, email, request, and phone as JSON to this webhook.
1:30 One important setting. By default, the webhook responds immediately, before the AI agent even runs. We need it to wait until the agent is done, so the form knows the submission succeeded. Click the respond dropdown.
1:41 Using respond to webhook node. This tells n8n: do not send a response yet. Wait until you hit a dedicated respond node further down the chain. That way the form gets a real confirmation after the AI agent has processed everything.
1:52 That is the webhook set up. Close the node.
AI Agent
1:55 Now we decide what happens when the form data arrives. Click the plus on the right edge of the webhook.
2:01 AI Agent. Same node as last time, but now it handles form submissions instead of chat messages. It will read the form data, save it to Google Sheets, and send a personalized reply via Gmail.
2:11 This time the prompt does not come from a chat trigger — it comes from the webhook. We need to change the source so we can write our own prompt template. Click the source dropdown.
2:20 Define below. This lets us write a prompt that pulls the form fields directly from the webhook data.
2:26 Here is the prompt template. Those double curly braces are n8n expressions that pull the name, email, request, and phone from the webhook body, so the agent gets the real details every time. Click paste prompt template.
2:39 Now we need a system message — the standing instruction that tells the agent what to do with every submission. Click add option.
2:46 System message. This is where we tell the agent to save the lead to Google Sheets and send a reply email via Gmail.
2:53 Here is the system message. It tells the agent to sort each request into repair, maintenance, install, or emergency, save the lead with the Google Sheets tool, and email a confirmation that names the job type. Click paste system message.
3:06 The agent is configured. It knows to save to Sheets and reply via Gmail. Close the node.
Chat model
3:11 The agent needs a model to think with. Click the plus under chat model.
3:15 OpenAI Chat Model. If you did the last module, this part will feel familiar.
3:19 Click the credential dropdown to connect your OpenAI API key.
3:23 Create new credential. If you already made one in the last module, you could pick it from the list. We will create a fresh one here.
3:28 Paste your OpenAI API key. If you followed the previous module, you already have one. If not, go to platform dot openai dot com, add credit, and create a key.
3:39 Hit save. n8n tests the connection and stores the key.
3:42 Now the model dropdown.
3:43 GPT five mini. Fast, cheap, and plenty smart for processing form submissions.
3:48 Model is wired up. Close it.
Sheets tool
3:50 Now the tools. The system message told the agent to use Google Sheets and Gmail — but it cannot do either until we give it the actual tools. Click the plus under tool.
4:00 Google Sheets Tool. This lets the agent save form submissions as rows in a spreadsheet.
Create the spreadsheet
4:05 Before we configure this node, we need to create the actual spreadsheet. Close this for now — we will come right back.
4:11 Switch to the Google Sheets tab. You need to create the spreadsheet that the Sheets node will write to.
4:16 Name it Leads — this is where every service request will go.
4:20 Now set up the column headers. These need to match the form fields. In A1, type Name.
4:24 B1 — Email.
4:26 C1 — Request.
4:27 And D1 — Phone. Four columns, matching exactly what the form sends: name, email, request, phone.
4:33 The spreadsheet is ready. Switch back to n8n and connect the Google Sheets node to it.
4:38 Double click the Google Sheets node to open it up again. Now we can connect it to the Leads spreadsheet.
Sheets tool
4:43 Click the credential dropdown to connect your Google account.
4:46 Create new credential. This one uses Google OAuth, so it opens a credential window.
4:51 Click sign in with Google. This opens the Google account chooser.
4:54 Pick the Google account that owns the Leads spreadsheet.
4:58 Google is asking for permissions. Check the first box — this lets n8n read and write your spreadsheets.
5:03 Second box — Drive access so n8n can find your spreadsheets by name.
5:08 Last one — this lets Google connect to n8n as an external service.
5:12 All three checked. Click continue and Google hands the credential back to n8n.
5:17 Now pick the spreadsheet. Click the document dropdown.
5:20 Leads — this is the spreadsheet where every form submission gets saved as a row.
5:25 Click the sheet dropdown.
5:27 Sheet one. That is the only tab.
5:29 Now the column mapping. Each column in the spreadsheet has a purple button. Click it and the AI agent figures out what data goes there. Click the purple button next to Name.
5:38 Email.
5:39 Request.
5:41 And Phone. All four columns are now set to defined automatically by the model.
5:45 Sheets tool is fully configured — credential, spreadsheet, sheet, and column mapping. Close it.
Gmail tool
5:51 The agent can save to Sheets now, but it also needs to send a reply email. Click the plus sign to add another tool.
5:56 Gmail Tool. This lets the agent send a personalized reply back to whoever submitted the form.
6:01 Click the credential dropdown. Gmail uses the same Google OAuth as Sheets.
6:06 Create new credential. Gmail needs its own Google OAuth credential.
6:10 Click sign in with Google. Same flow as before — Google account chooser then permissions.
6:15 Pick the Google account you want to send emails from.
6:18 Google is asking for permissions. Check the first box — this gives n8n full email access.
6:23 Second box — manage drafts and send emails.
6:26 Read, compose, and send.
6:28 View email message metadata.
6:30 View and modify but not delete.
6:32 Last one — view your email messages and settings.
6:35 All six checked. Click continue and Google hands the Gmail credential back to n8n.
6:40 Gmail is connected. The agent can now send emails. Close the node.
Respond node
6:44 One last piece. Remember we told the webhook to wait for a respond node before sending back a reply? We need to add that node now. Click the plus on the right edge of the agent.
6:52 Respond to Webhook. When the agent finishes processing — saving to Sheets and sending the email — this node sends a success response back to the form, so the user sees a confirmation message instead of an error.
7:04 Nothing to configure. This node just sends back the response. Close it.
Publish
7:08 The workflow is complete. Webhook trigger, AI agent with a model, Google Sheets, Gmail, and a respond node. Click publish to make it live. Once published, the webhook URL is active and ready to receive form submissions.
Add the secret
7:20 The workflow is published, but Lovable still needs the webhook URL. Open the webhook node to copy it.
7:26 Switch to the production URL tab. The test URL only works during testing. The production URL is the one your published workflow uses.
7:34 Click the URL to copy it to your clipboard. You will paste this into Lovable so the form knows where to send data.
7:40 Got the URL. Close the node.
7:42 Switch back to Lovable. We need to paste the webhook URL into a secret so the form can reach the workflow.
7:48 To add a secret in Lovable, click More in the toolbar. This opens the Cloud settings where you can manage secrets.
7:54 This is the secrets page. The prompt told Lovable to reference a secret config value called N8N WEBHOOK URL instead of hardcoding it. Click paste secret name.
8:04 Now paste the production URL you copied from the webhook node. This is the live endpoint your form will POST to. Click paste webhook URL.
8:12 Click save. The Lovable app now knows where to send form submissions. The webhook URL is stored as a secret, not in the source code — exactly how it should be.
Test the form
8:20 Time to test. Click Preview in the toolbar to see the form you built.
8:24 Fill out the form with sample data. Click the fill button to populate all the fields at once.
8:29 Click request service. The form posts the request to the n8n webhook. The agent sees a furnace blowing cold air in a cold house and tags it as an emergency, saves a row to Google Sheets, and emails a confirmation through Gmail. The respond node sends back a success message, and the form shows the confirmation.
8:46 The form submitted successfully. Now check the spreadsheet — click the Google Sheets tab to see the row the agent just wrote.
8:53 Simple as that. We show you and you do it. Sign up below to learn AI automation for free.
Watch the 30-second version
A short video from this lesson. Watch, then do it yourself in the free practice copy.
0:38AI Service Request Form in Lovable + n8n for HVAC, step by step
AI Service Request Form in Lovable + n8n for HVAC, step by step. A short from the free Stepthrough lesson “Build an AI Service Request Form for Your HVAC Company”: Build a service request form in Lovable for Cedar…

What you will build
Two pieces that work together. The front is a clean Request Service form built in Lovable with four fields: Name, Email, What do you need?, and Phone. The back is an n8n workflow: a webhook that receives each submission, an AI Agent that reads it, a Google Sheets tool that logs the lead in a sheet called Leads, a Gmail tool that emails the customer, and a Respond to Webhook node that tells the form it worked.
The agent sorts every request into one job type: Repair, Maintenance, Install or Emergency. No heat, no cooling in extreme heat, or water leaking from the system counts as an emergency. The confirmation email names the job type. If the customer mentions a gas smell, the email tells them to leave the house and call the gas company from outside.
Who this is for
HVAC owners and office managers who get requests through a website form, and want those requests sorted and answered even when nobody is at the desk. It is the third HVAC lesson, after the estimate writer and the follow-up agent. You do not need to write code, but it helps to have done the follow-up agent first.
Why it works
The form only collects facts. The AI does the judgment call a good dispatcher makes: a furnace running cold in a 58 degree house is not a routine repair. Keeping the webhook URL in a Lovable secret, not in the page code, means you can change the workflow without rebuilding the form. The Respond node makes the form wait until the agent has finished, so the customer sees 'Request received!' only after the lead is saved.
What the homeowner sees
The Lovable form is kept simple on purpose: a Request Service heading, one line asking what is going on with their heating or cooling, four required fields and a button. The email field is checked for a valid format. While it sends, the button reads Sending. When it works, the homeowner sees 'Request received!' and a note to check their email. If something fails, they see a friendly message asking them to call the office, so an emergency never disappears into a broken form.
A few minutes later a confirmation lands in their inbox that names the job type. For a no-heat call on a cold night, knowing the request was read and marked as an emergency is a big part of good service.
What you need
In the lesson, nothing: it is a practice copy. To build it for real you need a Lovable account for the form, an n8n account for the workflow, an OpenAI API key for the model, and a Google account for Sheets and Gmail. You will reuse the OpenAI key and Google connection from the follow-up agent lesson if you already made them.
How to use this in your HVAC business
Swap in your own company name, service area and emergency rules. During the first heat wave or cold snap, when requests arrive faster than anyone can read them, the emergency tag tells the office which calls to return first. Every lead lands in one sheet, so nothing is lost in an inbox. You can also change the job types to match how you dispatch, for example adding a separate type for maintenance plan members.
The same sheet shows you what kind of work your website brings in. In a mild spring it may be mostly tune-ups and install questions. In a heat wave it fills with no-cool calls. That pattern helps you decide when to push maintenance plans and when to keep a tech free for emergencies.
Try it yourself, free
Reading the steps is a start. Doing them is how it sticks. The interactive module walks you through every click in a practice copy of Lovable and n8n, checks each step, and never touches your real accounts.
Start “Build an AI Service Request Form for Your HVAC Company”Step by step: Build an AI Service Request Form for Your HVAC Company
All 93 steps of the interactive module, in order. In the module you watch each one, then do it yourself in a practice copy that checks your work.
1. Sign up
- Get started with Lovable. Lovable lets you build web apps by describing what you want. Click Get started for free.
In the first module you built a Custom GPT. In the second, you built an AI agent inside n8n. Now you are going to combine a real web app with an AI-powered backend. Lovable is a tool that builds web apps from a text description.
2. Build the form
- Click the prompt box. This is your Lovable dashboard. To start a new project, click the prompt box under What should we build, Alex?
This is your Lovable dashboard. Your projects show up along the bottom. To start a new one, you just describe it.
- Describe the form. This prompt tells Lovable exactly what to build — a service request form that sends data to an n8n webhook. Paste in the prompt on the box.
This prompt tells Lovable what to build: a clean service request form with name, email, what the customer needs, and phone, sending each request to an n8n webhook URL pulled from a secret config — not hardcoded.
Build a simple, clean service request form for a residential heating and air conditioning company. The page should be modern, minimal, and professional. Include these fields: Name Email What do you need? Phone Use a clear heading such as: Request Service Add a short supporting line like: Tell us what's going on with your heating or cooling and we'll confirm by email. WEBHOOK When the form is submitted, send the data as a POST request to the n8n webhook URL. The data should be sent as JSON with keys: name, email, request, phone. Do not ask me to paste the webhook URL into the page or source code. SUBMISSION STATES While submitting, change the button text to something like: Sending... After a successful submission, show: Request received! Check your email for a confirmation. If the webhook request fails, show a simple friendly error: Something went wrong. Please call the office. VALIDATION All four fields are required. Validate the email format. Make it responsive for desktop and mobile. Do not add unnecessary sections, navigation, pricing, testimonials, or other marketing content. The main purpose of this project is to send service requests from Lovable to an n8n webhook. IMPORTANT Do not hard-code any webhook URL. Reference the N8N_WEBHOOK_URL secret/config value when sending the form submission. The actual secret will be added manually later in Lovable Cloud, under Secrets.
- Open the mode picker. Next to the microphone it says Build. That is the mode picker. Click it.
Before you send it, look at the word Build next to the microphone. That's the mode picker.
- Keep Build mode. Build makes changes directly, Chat is for questions, Plan writes a detailed plan first. Click Build.
Build makes changes directly. Chat is for asking questions and exploring ideas, and Plan writes a detailed plan first, which helps on bigger projects. This form is simple, so click Build.
- Build the app. Click the send arrow. Lovable builds the app from your prompt and shows it in a preview. Then we switch to n8n to build the backend.
Lovable reads your prompt, generates the code, and builds a preview of the app. Nothing is public until you publish it. In a few seconds you have a working service request form. Now we build the AI workflow that handles each request.
3. New workflow
- Start a new workflow. Now you are in n8n. Click Create workflow to start building the backend.
Now you are in n8n. This is the workflow automation tool you used in the last module. This time, instead of a chat trigger, we are going to use a webhook — so the form can send data directly to n8n.
4. Webhook trigger
- Add the first step. Click Add first step… to choose a trigger.
Every workflow starts with a trigger. Last time we used a chat trigger. This time we want a webhook — an HTTP endpoint the form can POST to.
- Webhook trigger. Click On webhook call — the form will send data to this endpoint.
On webhook call. A webhook is just a URL that waits for incoming data. When a homeowner submits the form, it sends their name, email, request, and phone as JSON to this webhook.
- Change the response mode. By default the webhook responds immediately. We need it to wait. Click the Respond dropdown.
One important setting. By default, the webhook responds immediately, before the AI agent even runs. We need it to wait until the agent is done, so the form knows the submission succeeded.
- Use a Respond node. Click Using 'Respond to Webhook' Node — this lets the workflow finish before responding.
Using respond to webhook node. This tells n8n: do not send a response yet. Wait until you hit a dedicated respond node further down the chain. That way the form gets a real confirmation after the AI agent has processed everything.
- Back to the canvas. Webhook is configured. Close the node with the ×.
That is the webhook set up. Close the node.
5. AI Agent
- Add the next node. Click the + on the right edge of the webhook node.
Now we decide what happens when the form data arrives.
- Add the AI Agent. Click AI Agent — it will process the form data, save it to a sheet, and send an email.
AI Agent. Same node as last time, but now it handles form submissions instead of chat messages. It will read the form data, save it to Google Sheets, and send a personalized reply via Gmail.
- Change the prompt source. This time we are not using a chat trigger. Click the Source dropdown.
This time the prompt does not come from a chat trigger — it comes from the webhook. We need to change the source so we can write our own prompt template.
- Define it manually. Click Define below so we can write a custom prompt template.
Define below. This lets us write a prompt that pulls the form fields directly from the webhook data.
- Write the prompt template. This template pulls the form fields from the webhook data. Paste in the prompt template.
Here is the prompt template. Those double curly braces are n8n expressions that pull the name, email, request, and phone from the webhook body, so the agent gets the real details every time.
- Add an option. Scroll down and click + Add Option to add a system message.
Now we need a system message — the standing instruction that tells the agent what to do with every submission.
- System Message. Click System Message.
System message. This is where we tell the agent to save the lead to Google Sheets and send a reply email via Gmail.
- Write the system message. This tells the agent to sort the job, save the lead to Sheets and email a confirmation. Paste in the system message.
Here is the system message. It tells the agent to sort each request into repair, maintenance, install, or emergency, save the lead with the Google Sheets tool, and email a confirmation that names the job type.
You are the service request assistant for Cedar Ridge Heating & Air, a residential HVAC company. Sort each request into one job type: Repair, Maintenance, Install, or Emergency. No heat, no cooling in extreme heat, or water leaking from the system counts as Emergency. Use the google sheets tool to add the lead to the google sheet. Use the gmail tool to email the customer a short confirmation that names the job type. If they mention a gas smell, tell them to leave the house and call the gas company from outside.
- Back to the canvas. The agent knows what to do. Close the node with the ×.
The agent is configured. It knows to save to Sheets and reply via Gmail. Close the node.
6. Chat model
- Give the agent a brain. The agent still needs a language model. Click the + under Chat Model.
The agent needs a model to think with.
- Pick OpenAI. Click OpenAI Chat Model.
OpenAI Chat Model. If you did the last module, this part will feel familiar.
- Open the credentials. Click the Credential dropdown.
- Create a new credential. Click + Create new credential.
Create new credential. If you already made one in the last module, you could pick it from the list. We will create a fresh one here.
- Paste the key. Paste in the API key to drop in your OpenAI key. No key yet? Make one at platform.openai.com (add credit first), or in your own n8n pick Gateway credits and skip this step.
If you followed the previous module, you already have one. If not, go to platform dot openai dot com, add credit, and create a key. Or skip it: new n8n accounts include free credits, so in your own n8n you can pick gateway credits instead.
- Save the credential. Click Save.
n8n tests the connection and stores the key.
- Pick the model. Click the Model dropdown.
Now the model dropdown.
- gpt-5-mini. Pick gpt-5-mini — fast and cheap.
GPT five mini. Fast, cheap, and plenty smart for processing form submissions.
- Back to the canvas. Close the model node with the ×.
Model is wired up. Close it.
7. Sheets tool
- Add a tool. The agent needs tools to do things. Click the + under Tool.
Now the tools. The system message told the agent to use Google Sheets and Gmail — but it cannot do either until we give it the actual tools.
- Add Google Sheets. Click Google Sheets Tool.
Google Sheets Tool. This lets the agent save form submissions as rows in a spreadsheet.
8. Create the spreadsheet
- Back to the canvas. Before configuring this, create the spreadsheet it will write to. Close the node for now.
Before we configure this node, we need to create the actual spreadsheet. Close this for now — we will come right back.
- Open Google Sheets. Click the Google Sheets tab to create a new blank spreadsheet.
Switch to the Google Sheets tab. You need to create the spreadsheet that the Sheets node will write to.
- Name the spreadsheet. Click the title and rename it to Leads.
Name it Leads — this is where every service request will go.
- Type the first column header. In cell A1, type Name.
Now set up the column headers. These need to match the form fields. In A1, type Name.
- Email. In cell B1, type Email.
B1 — Email.
- Request. In cell C1, type Request.
C1 — Request.
- Phone. In cell D1, type Phone. That is all four columns — matching the form.
And D1 — Phone. Four columns, matching exactly what the form sends: name, email, request, phone.
- Back to n8n. The spreadsheet is ready. Click the n8n tab to go back and connect it.
The spreadsheet is ready. Switch back to n8n and connect the Google Sheets node to it.
- Open the Sheets node. Double-click the Google Sheets node to configure it.
Double click the Google Sheets node to open it up again. Now we can connect it to the Leads spreadsheet.
9. Sheets tool
- Add a credential. Click the Credential dropdown.
- Create a new credential. Click + Create new credential to sign in with Google.
Create new credential. This one uses Google OAuth, so it opens a credential window.
- Sign in with Google. Click Sign in with Google to connect your account.
This opens the Google account chooser.
- Choose your account. Click your Google account to continue.
Pick the Google account that owns the Leads spreadsheet.
- Allow Sheets access. Check See, edit, create, and delete all your Google Sheets spreadsheets.
Google is asking for permissions. Check the first box — this lets n8n read and write your spreadsheets.
- Allow Drive access. Check See, edit, create, and delete all of your Google Drive files.
Second box — Drive access so n8n can find your spreadsheets by name.
- Allow external service. Check Connect to an external service.
Last one — this lets Google connect to n8n as an external service.
- Sign in. Click Continue to complete the Google sign-in.
All three checked.
- Pick the spreadsheet. Click the Document dropdown.
Now pick the spreadsheet.
- Leads. Click Leads — the spreadsheet where service requests go.
Leads — this is the spreadsheet where every form submission gets saved as a row.
- Pick the sheet tab. Click the Sheet dropdown.
- Sheet1. Click Sheet1.
Sheet one. That is the only tab.
- Map the Name column. Under Values to Send, click the ✦ button next to Name — the AI agent will fill this in automatically.
Now the column mapping. Each column in the spreadsheet has a purple button.
- Map the Email column. Click the ✦ button next to Email.
Email.
- Map the Request column. Click the ✦ button next to Request.
Request.
- Map the Phone column. Click the ✦ button next to Phone.
And Phone. All four columns are now set to defined automatically by the model.
- Back to the canvas. Google Sheets is configured. Close the node with the ×.
Sheets tool is fully configured — credential, spreadsheet, sheet, and column mapping. Close it.
10. Gmail tool
- Add another tool. The agent also needs to send emails. Click the + next to Google Sheets to add another tool.
The agent can save to Sheets now, but it also needs to send a reply email.
- Add Gmail. Click Gmail Tool.
Gmail Tool. This lets the agent send a personalized reply back to whoever submitted the form.
- Add a credential. Click the Credential dropdown.
Gmail uses the same Google OAuth as Sheets.
- Create a new credential. Click + Create new credential to sign in with Google.
Create new credential. Gmail needs its own Google OAuth credential.
- Sign in with Google. Click Sign in with Google to connect your account.
Same flow as before — Google account chooser then permissions.
- Choose your account. Click your Google account to continue.
Pick the Google account you want to send emails from.
- Allow email access. Check Read, compose, send, and permanently delete all your email from Gmail.
Google is asking for permissions. Check the first box — this gives n8n full email access.
- Allow drafts. Check Manage drafts and send emails.
Second box — manage drafts and send emails.
- Allow compose. Check Read, compose, and send emails from your Gmail account.
Read, compose, and send.
- Allow metadata. Check View your email message metadata.
View email message metadata.
- Allow modify. Check View and modify but not delete your email.
View and modify but not delete.
- Allow view. Check View your email messages and settings.
Last one — view your email messages and settings.
- Sign in. Click Continue to complete the Google sign-in.
All six checked.
- Back to the canvas. Gmail is connected. Close the node with the ×.
Gmail is connected. The agent can now send emails. Close the node.
11. Respond node
- Add the respond node. One more node. Click the + on the right edge of the AI Agent.
One last piece. Remember we told the webhook to wait for a respond node before sending back a reply? We need to add that node now.
- Respond to Webhook. Click Respond to Webhook.
Respond to Webhook. When the agent finishes processing — saving to Sheets and sending the email — this node sends a success response back to the form, so the user sees a confirmation message instead of an error.
- Back to the canvas. Nothing to configure here. Close the node with the ×.
Nothing to configure. This node just sends back the response. Close it.
12. Publish
- Publish the workflow. The workflow is complete. Click Publish to make it live.
The workflow is complete. Webhook trigger, AI agent with a model, Google Sheets, Gmail, and a respond node. Once published, the webhook URL is active and ready to receive form submissions.
13. Add the secret
- Open the webhook. Double-click the Webhook node to get its production URL.
The workflow is published, but Lovable still needs the webhook URL.
- Production URL. Click the Production URL tab — this is the live URL your form will POST to.
Switch to the production URL tab. The test URL only works during testing. The production URL is the one your published workflow uses.
- Copy the URL. Click the URL to copy it. You will paste it into Lovable as a secret.
You will paste this into Lovable so the form knows where to send data.
- Back to the canvas. URL copied. Close the webhook node.
Got the URL. Close the node.
- Back to Lovable. Click the Lovable tab. We need to give it the webhook URL.
Switch back to Lovable. We need to paste the webhook URL into a secret so the form can reach the workflow.
- Open More. Your app is open in the Lovable editor: chat on the left, preview on the right. In the toolbar at the top, click More (the stacked icon right after Code).
Here is your app in the Lovable editor, with the chat on the left and the preview on the right. Secrets live in the More view. In the toolbar at the top, click the stacked icon right after the code brackets. That's More.
- Open Cloud. More holds your project tools. Click Cloud in the list on the left.
More holds the tools for running your app, starting with Analytics. Secrets belong to Cloud, Lovable's built-in backend.
- Open Secrets. Cloud opens on its Overview. Click Secrets in the list.
Cloud opens on its overview, and its pages are listed on the left.
- Name the secret. Paste in the secret name — this matches what the Lovable app expects.
This is the secrets page. The prompt told Lovable to reference a secret config value called N8N WEBHOOK URL instead of hardcoding it.
- Paste the webhook URL. Paste in the webhook URL to drop in the production URL you just copied.
This is the live endpoint your form will POST to.
- Save the secret. Click Save. The Lovable app can now reach the n8n workflow.
The Lovable app now knows where to send form submissions. The webhook URL is stored as a secret, not in the source code — exactly how it should be.
14. Test the form
- Open the form. Click Preview (the globe icon) in the toolbar to test the form.
Time to test.
- Fill the form. Click Fill with test data to populate the form fields.
Fill out the form with sample data.
- Submit the form. Click Request Service. The form sends the data to n8n; the agent sorts the job, saves it to Sheets and emails a confirmation.
The form posts the request to the n8n webhook. The agent sees a furnace blowing cold air in a cold house and tags it as an emergency, saves a row to Google Sheets, and emails a confirmation through Gmail. The respond node sends back a success message, and the form shows the confirmation.
15. Publish the app
- Open Publish. The test went through. The preview is only for you, so click Publish at the top right to put the form online.
The test went through. But the preview is only for you. To put the form online, click Publish at the top right.
- Publish. Lovable suggests a free lovable.app address (you can change it) and runs a quick security scan. Click Publish.
Lovable suggests a free web address ending in lovable dot app, and you can change it before you publish. It also runs a quick security scan. The live app uses the same secret, so it sends to your workflow too.
- Check the spreadsheet. Your app is live. Click the Google Sheets tab to see the data the agent saved from your test.
Your app is live. Now check the spreadsheet.
Screenshots




Frequently asked questions
- Can AI tell which HVAC requests are emergencies?
- In this lesson the agent follows written rules: no heat, no cooling in extreme heat, or water leaking from the system is an emergency. You set the rules, so you can match them to how your company dispatches.
- Is it free to build this?
- Stepthrough is free. Doing it for real needs your own Lovable, n8n, OpenAI and Google accounts, and some of those cost money for ongoing use. Check each tool's pricing.
- Where does the job type go?
- The sheet stores what the customer typed: name, email, request and phone. The AI's job type goes in the confirmation email.
- How does the interactive lesson work?
- Each step is shown to you first on the left (Watch). Then you do it yourself in a practice copy on the right (Your turn), and every click is checked. If you get stuck, press Do it for me. It is a practice copy, so no real accounts are touched.
- What if a customer reports a gas smell?
- The system message tells the agent to include a safety line in the email: leave the house and call the gas company from outside.
More Lovable and n8n tutorials
n8n AI Agent Tutorial: Save Social Media Ideas to Google SheetsBuild an AI agent for BrightPath Marketing that generates social media post ideas and saves them to Google Sheets — chat trigger, AI Agent, system prompt, model…
Free · Live ~12 min Intermediate
AI Receipt Extractor: Receipts to Google Sheets with n8nDrop a photo of a receipt into an n8n chat. An AI agent reads it, pulls out the date, vendor and amount, picks a category, and adds a row to Google Sheets.
Free · Live ~12 min Intermediate
n8n AI Email Responder: Draft Gmail Replies AutomaticallyBuild an n8n agent that watches your Gmail, reads each new customer email, and writes a reply as a draft in the same thread, ready for you to check and send.
Free · Live ~12 min Intermediate
Daily Job Alerts: Email Each Tech Their Jobs from Google Sheets with n8nEvery morning at 7, n8n reads a plumbing company's jobs sheet, skips anything not assigned yet, and emails each job to the tech it's assigned to — customer, address…
Free · Live ~10 min Intermediate
Gmail AI Triage: Auto-Label Every Email and Draft RepliesBuild an n8n workflow that reads each new email, sorts it as a lead, a client or an invoice with a Text Classifier, adds the matching Gmail label, and drafts a reply to…
Free · Live ~18 min Advanced
A Support Agent That Answers from Your Own DocsTurn an n8n chat agent into a support agent that answers only from your policies in a Google Doc, refuses what it should, and hands off to a person by email.
Free · Live ~13 min Advanced
From the blog
Automatic Confirmation Emails for Form SubmissionsWhat an automatic confirmation email for a form submission should say, fixed vs AI-written confirmations, and how to set one up and test it with n8n.
Oct 28, 2026 6 min read
What Is Lovable? Build a Web Form from a Written PromptWhat is Lovable? A plain guide to the tool that builds web apps from a written prompt: how it works, what it's good for, what it costs and where n8n fits.
Oct 1, 2026 6 min read
AI for Contractors: How to Book More Jobs With AI (Free)How HVAC, plumbing and electrical contractors can use AI to book more jobs: triage, quotes and follow-ups, with free lessons for each trade.
Oct 1, 2026 6 min read
Visual guides
This lesson’s key ideas as quick visual guides: swipe through the slides, or read the same guide as text.
A service request form that spots emergenciesA homeowner's furnace is blowing cold air and the house is at 58 degrees. Your form should know that's an emergency.
Prompt to copy One graphic
Build a web form with an AI backend, no codeMost website forms just land in an inbox and wait. This one does the work. You describe the form in Lovable, and it builds it.
Step-by-step guide 7 slides
Mistake to Avoid: Testing an Unpublished n8n WorkflowA visual tip: an n8n production webhook URL only works once the workflow is published. Publish first, then copy the URL into your app.
Mistake to avoid One graphic
Free cheat sheets
Print it or save the PDF: the key steps and checks from this lesson on one page, free.
Lovable + n8n Form Flow Cheat SheetA free one-page cheat sheet: a Lovable form posts to an n8n webhook, and an AI Agent logs it in Google Sheets and replies by Gmail.
Lesson cheat sheet Free PDF
AI Glossary Cheat Sheet: 30 Terms in Plain EnglishA free one-page cheat sheet of 30 AI and automation terms in plain English: models, prompts, n8n workflows, apps and data.
Topic cheat sheet Free PDF
n8n Basics Cheat Sheet: Triggers, Items, WebhooksA free one-page cheat sheet of n8n basics: triggers, expressions, items, executions, the workflow timezone and webhook test vs production URLs.
Tool cheat sheet Free PDF
All free printable cheat sheets
Terms in this lesson
Plain-English definitions, each with an example from a free lesson.
Related prompts
- AI agent test messages prompt: Test an AI agent before launch with realistic messages: normal requests, borderline cases, missing details and tricky ones, each…
- "What do I do until you get here?" prompt: Answer an emergency caller with safety first: your approved wording for calling 911 or the utility, what to stay away from, and…
- Lovable web form prompt: Write a Lovable prompt for a web form that posts to n8n: fields, validation, button states, a thank-you message, and a webhook…
- Service appointment confirmation prompt: How to write an appointment confirmation email or text: a free ChatGPT prompt and examples with the day, arrival window, prep…
More terms on this topic
More prompts on this topic
- Weekly leads summary prompt: Paste a week of form leads from your Google Sheet and get counts by type, who is still waiting, patterns with row numbers and…