You no longer have to be a programmer to automate real work. Scraping a site, processing the data, and turning it into a readable summary used to mean writing a script or hiring someone to write one. With the right tools you can wire the whole thing together yourself on a visual canvas instead.
This guide shows you how to build an Amazon AI agent with n8n and Crawlbase: a workflow that takes a product keyword, pulls public Amazon search results through Crawlbase, hands them to an AI model for analysis, and emails you the insights. A form collects the keyword, the Crawling API fetches the listings behind a real browser and a trusted IP, the AI summarizes trends and prices, and the result lands in an inbox. It is a clean automated loop that runs without you babysitting a scraper or a proxy pool.
What the agent does and who it is for
Each node has one job. The form trigger collects a keyword and the recipient's details, Crawlbase retrieves the Amazon listings as clean structured data, a switch node retries on a failed request, the AI model writes the analysis, and an email node delivers it. Wired together, the workflow turns "what's selling for this keyword" into a summary in your inbox seconds later.
That is useful for product researchers sizing up a niche, ecommerce teams tracking competitors, agencies validating a category, or anyone who would rather read a short brief than scroll through listings by hand. The same pattern covered in automating ecommerce product research applies here; this is the Amazon-specific build of it.
Scrape Amazon responsibly
Before any code, the boundary. This workflow is scoped to public Amazon product data: the titles, prices, ratings, review counts, and Prime status anyone can see on a search results page without logging in. Read this section before you point the agent at production volume.
Amazon's terms of service restrict automated access, so scraping can run against those terms no matter how careful your tooling is. None of the setup here changes that; it just makes the technical part work. A few lines worth holding to: collect only public listing data, respect Amazon's robots.txt and its stated rate expectations, and keep request volume low enough that you are not straining anyone's servers. If you plan to reuse the data commercially, get permission or an official data agreement rather than assuming silence is consent.
What this guide does not cover, on purpose: anything behind a login, account or order data, personal data tied to identifiable buyers or reviewers, any authentication bypass, and any purchase or account action. If your project needs more than public listings, the right move is an official Amazon API or a data agreement, not a cleverer scraper.
The line that keeps this work defensible is the login wall. Everything this agent reads is visible to any anonymous visitor on a search page. The moment a task needs an account, an order history, or a buyer's personal details, it is out of scope here and belongs behind an official API or data agreement.
What you need before you start
Get these in place first and the rest of the build moves quickly:
- A Crawlbase account and token. This fetches the Amazon results. After signing up, copy your Normal token from the dashboard. Crawlbase does not charge for failed requests, which the retry logic relies on.
- An n8n instance. Self-hosted or n8n Cloud both work; it is where you wire the nodes together.
- An AI provider key. The analysis step needs a model. Any provider with a chat or message endpoint works; this guide uses OpenAI.
- An email-sending account. To deliver the summary. A service such as SendGrid on its free tier is plenty.
- Basic n8n familiarity. If you can drag nodes onto the canvas and fill in fields, you are set.
How the data flows through the workflow
Rather than write an HTTP integration with headers, parsing, and retry logic by hand, you let each node do one part:
- The Form Trigger collects the product keyword and the recipient's name and email.
- The HTTP Request node sends the keyword to the Crawling API and gets back parsed Amazon listings.
- The Switch node checks the response status and loops back to retry on failure.
- The AI model node reads the listings and writes the analysis.
- The email node sends the summary to the address from the form.
Because Crawlbase returns Amazon search results already parsed into clean JSON, the AI step reads structured fields instead of wrestling with raw HTML. That is the same engine behind the Crawling API, exposed here as a scraper parameter on the Crawling API call.
Step 1: Start with a form trigger
Create a new workflow in n8n, click Add first step, and choose On form submission from the trigger list. This gives you a hosted form that kicks off the workflow when someone submits it. Configure the trigger with these values:
- Authentication: None
- Form Title: Amazon SERP AI Agent with n8n and Crawlbase
- Form Description: Enter a product keyword to analyze on Amazon. n8n uses Crawlbase to extract titles, prices, and ratings, then an AI agent summarizes the results.
- Respond When: Workflow Finishes
Add three form elements so the workflow has a keyword to search and somewhere to send the result:
Product Keyword | Text | placeholder: wireless earbuds | required Your Name | Text | placeholder: John Doe | required Email | Email | placeholder: [email protected] | required
Scroll down to Options and, under Form Response, set Respond With to "Form Submitted Text" and Text to Show to something like "Please check your email." That is what the visitor sees after submitting, while the workflow runs in the background.
Step 2: Fetch Amazon results with the Crawling API
Click the plus (+) button after the form trigger, search for HTTP, and add an HTTP Request node. It sends the keyword to Crawlbase and gets back the Amazon search results as parsed JSON. Set it to make a GET request to the Crawling API endpoint with query parameters supplied from fields below:
Method: GET URL: https://api.crawlbase.com Send Query Parameters: Yes Specify Query Parameters: Using Fields Below
Then scroll to the Query Parameters tab and add three of them. The scraper parameter is what tells Crawlbase to return parsed Amazon SERP data instead of raw HTML, so the AI step gets clean fields:
token | YOUR_CRAWLBASE_NORMAL_TOKEN url | https://www.amazon.com/s?k={{ $json['Product Keyword'] }} scraper | amazon-serp
For the url value, type the expression by hand or drag the Product Keyword field from the left panel into the box and n8n inserts it for you. That builds an Amazon search URL from whatever keyword the visitor entered.
Amazon renders results client-side and challenges automated traffic hard, so a plain request hands you an empty shell. The Crawling API renders the page behind a real browser and a trusted IP, and the amazon-serp scraper returns the listings already parsed into a products array with names, prices, ratings, and Prime status. That means the AI never has to parse HTML, and your selectors never drift.
Step 3: Retry failed requests with a switch node
Add the plus (+) button after the HTTP Request node and search for Switch. The idea is simple: if Crawlbase returns anything other than a clean success, loop back and try again. Since Crawlbase does not bill for failed requests, you only move forward once a valid result is in hand.
Set the node's Mode to Rules, then add two routing rules that branch on the response status:
{{ $json.original_status }} | is equal to | 200 | output: success {{ $json.original_status }} | is not equal to | 200 | output: failed
Set the comparison type to Number. This matters: leave it as a string and the equality check can misbehave, breaking the retry logic. Then connect the failed output back to the start of the HTTP Request node so a bad response triggers another attempt automatically. The success output carries on to the AI step.
Amazon needs a rendered page behind a trusted IP, and ideally the listings already parsed. The Crawling API does both in one call: pass your token plus scraper=amazon-serp, and it renders the search page in a real browser, rotates through residential IPs server-side, and returns clean JSON, so your n8n agent reads structured products without a headless fleet or a proxy pool. Failed requests are not billed, which is what makes the retry loop free. Start on the free tier and point it at a public search.
Step 4: Analyze the data with an AI model
With the retry loop in place, click the plus (+) button on the success output of the switch node. Search for your AI provider, for example OpenAI, and choose Message a model. This node takes the parsed product data from Crawlbase and asks the model to summarize trends, price ranges, common brands, and review averages, or whatever insights you want.
If you have not added your provider credentials to n8n yet, the node will prompt you. Configure it to send a single user message to a current chat model:
Credential: your configured AI provider key Resource: Text Operation: Message a Model Model: a current chat model (for example gpt-4o) Role: User
In the message box, paste a prompt that maps the Crawlbase products array into a readable list and asks for a focused analysis. The expression pulls the keyword from the form and the product fields from the HTTP Request output:
You are a product research analyst. Here is the data from an Amazon search for "{{ $('On form submission').item.json['Product Keyword'] }}": {{ $('HTTP Request').item.json.body.products.map((item, index) => "\n" + (index + 1) + ". " + item.name + " | " + item.price + " | " + (item.isPrime ? "Amazon Prime" : "Not Amazon Prime") + " | " + item.customerReview + " | " + item.boughtInfo) }} Analyze this data and summarize the key insights: - Top 3 popular brands - Average price range - Notable deals or trends - Short market summary (3 to 4 sentences)
The prompt does a few things on purpose. It sets the role so the model stays terse, names the exact insights you want so output is consistent across runs, and feeds the model a clean list of parsed fields rather than raw HTML.
Step 5: Send the summary by email
The analysis is done; the last step is delivery. Click the plus (+) button after the AI node, search for your email service, for example SendGrid, and under Mail Actions choose Send an email. It sends the summary to the address from the form, so make sure your email credentials are configured.
Fill in the node by pulling values from earlier steps. The recipient and sender name come from the form, the subject reuses the keyword, and the body is the model's output:
Credential: your configured email-service key Resource: Mail Operation: Send Sender Email: the verified sender you set up with the service Sender Name: {{ $('On form submission').item.json['Your Name'] }} Recipient Email: {{ $('On form submission').item.json.Email }} Subject: Amazon analysis for '{{ $('On form submission').item.json['Product Keyword'] }}' Mime Type: Plain Text Message Body: {{ $json.output[0].content[0].text }}
Once everything is wired, the workflow comes together cleanly: the form collects the keyword, Crawlbase fetches and parses the listings, the switch handles retries, the AI summarizes, and the email node sends it out.
Test the workflow end to end
Activate the workflow, open the Production URL from the On form submission node, and you get a hosted form with the three fields you defined. Enter a keyword such as "wireless earbuds," add a name and email, and submit.
Give it a few seconds. The keyword goes to Crawlbase, the parsed products come back, the switch confirms a clean response, the model writes the analysis, and the email node sends it. You should receive a short brief: top brands for that keyword, an average price range, any notable deals, and a few sentences of market summary. If nothing arrives, open the execution log to see which node stopped and what it returned.
Where to take this next
You have built a product research assistant that runs on autopilot. From here it is up to you. Run it on a schedule to track competitor pricing over time. Send the output to a Slack channel or a database instead of email. Swap the form trigger for a list of keywords and analyze a whole category in one pass.
And Crawlbase is not only for Amazon. The same scraper parameter handles other major sites, and for anything without a dedicated parser the Crawling API returns rendered HTML or LLM-ready markdown an AI step can read directly. If you would rather the agent reach for crawl tools on its own, connecting n8n with Crawlbase Web MCP shows the agent-driven version using the Web MCP server, and building AI agent workflows with Crawlbase Web MCP goes deeper on multi-step agents. For custom builds outside n8n, the Crawling API and Smart Proxy give you the same engine to call directly.
The appeal is that it works without code: n8n drives the automation, Crawlbase does the crawling and parsing, and the AI does the reading. Crawlbase is trusted by over 70,000 developers, so the crawling layer under your workflow is the same one that powers production scrapers at scale.
Key takeaways
- Five nodes, one loop. Form trigger, HTTP Request to Crawlbase, switch for retries, AI model, email. Each does one job and the data flows straight through.
-
Let Crawlbase parse Amazon. Pass
scraper=amazon-serpso the listings come back as clean JSON; the AI reads structured fields instead of raw HTML, and selectors never drift. - Retries are free. Crawlbase does not bill failed requests, so the switch node can loop back on a non-200 status until it gets a valid result.
- The AI does the analysis. A focused prompt that names the exact insights you want produces a consistent brief on every run.
- Stay on public data. Respect Amazon's ToS and robots.txt; no accounts, no order or personal data, no auth bypass, no purchase actions.
Frequently Asked Questions (FAQs)
Do I need to write any code to build this Amazon AI agent?
No. The entire workflow is built visually in n8n by dragging nodes onto the canvas and filling in fields. The only "code" is a short expression in the AI prompt that maps the Crawlbase product array into a readable list, and you can paste that as-is. Crawlbase handles the scraping and parsing, the AI model handles the analysis, and n8n connects the two.
Why use Crawlbase instead of a plain HTTP request to Amazon?
Amazon renders its results client-side and challenges automated traffic aggressively, so a bare request usually returns a 200 with no product data. The Crawling API renders the page in a real browser behind a trusted residential IP, and the amazon-serp scraper returns the listings already parsed into JSON. You get clean fields without running a headless browser or a proxy pool yourself.
What Amazon data can the agent collect?
Public search-results data only: product titles, prices, ratings, review counts, Prime status, and similar fields anyone can see without logging in. It does not collect account data, order history, personal information tied to buyers or reviewers, or anything behind a login. Keep the agent scoped to public listings and respect Amazon's terms of service and robots.txt.
Why does the switch node retry failed requests?
Occasionally a request returns a non-200 status. The switch node checks original_status and routes anything other than 200 back to the HTTP Request node to try again, so the workflow only advances once it has a valid result. Because Crawlbase does not charge for failed requests, this retry loop costs nothing. Make sure the comparison type is set to Number or the equality check can misbehave.
Can I use an AI provider other than OpenAI?
Yes. The analysis step works with any model that n8n supports through a chat or message node. Swap the OpenAI node for your provider's node, add its credentials, and keep the same prompt. The rest of the workflow, including the Crawlbase fetch and the email delivery, stays exactly the same.
How do I send the results somewhere other than email?
Replace the email node with whatever destination you want. n8n has nodes for Slack, Google Sheets, databases, webhooks, and many more. Point the AI model's output at that node instead, and you can post the summary to a channel, append it to a sheet, or store it for later. The form, Crawlbase fetch, switch, and AI steps do not change.
Crawl any site at scale, without fighting infrastructure.
Crawlbase handles proxies, fingerprints, and CAPTCHAs so your team ships data pipelines instead of maintaining crawl plumbing. 1,000 requests free, no card required.

