
Lessons From a Bananahead: Building a Price-Scraping Spreadsheet Bot With AI and a Few Doh Moments

Ah, spreadsheets. Those unassuming grids that somehow manage to be both the backbone of modern business and a maze of existential dread. This post is a behind-the-scenes look at building a Google Sheets automation system that pulls product data from an external UPC lookup service. Spoiler: I learned a lot, made a few missteps, and emerged (mostly) victorious.
The Mission: AI-Powered Price Fetching
I wanted a bot that could read a list of UPC codes from a Google Sheet, fetch data like product name, price, and image from an API, and then update the sheet accordingly — one row per product. Easy enough in theory.
Here was the setup:
Google Sheet with UPCs.
Automation platform (n8n in my case, but Make or Zapier would work too).
Schedule trigger to run the automation regularly.
An HTTP module to fetch data from Barcodelookup.com.
Append/Update module to write the data back.
Doh Moment #1: Referencing the Wrong Pills
For the longest time, I couldn't figure out why the Append or Update Row In Sheet module wasn't returning the right results. Turns out, I was referencing the sheet's UPC from within the loop, instead of pulling the UPC from the HTTP response.
Fix (edited by Editor): Where I specify which unique identifier's column to match, I rather mapped the UPC from the HTTP Request output. Of course I can't tell n8n to reference a cell's value to itself, that won't make sense. Honestly, it was like trying to butter toast with the wrong side of the knife.
Doh Moment #2: Row Filtering Woes
I initially tried filtering rows based on empty cells to decide what needed updating. But Make/n8n doesn’t always play nice when looping through items with certain filters applied.
Fix: I added a “Status” column in the sheet. Once a row is successfully processed, the automation marks it as "Done". Then, the automation filters out anything already marked.
Bonus: It made debugging easier — I could see what had and hadn’t run at a glance.
Doh Moment #3: Overengineering It
At first, I added conditional routers, extra HTTP calls, and multiple parsing steps. It was a glorious tangle.
Editor chiming in once more: While ChatGPT helped me immensely with this build and he wrote this article on my behalf - mostly because I forgot most of this stuff and asked him to turn all my learnings into a blog post - I will edit here and mention that he wanted to go all in and have loops and merge modules and all that when something was broken. Instead of doing the simplification stuff that experienced human coders do all the time... and total n00bs like myself are learning to do.
Like, you'd expect ChatGPT to go, "hey, let's rather look and see what you squishy fleshbag did that caused this error." But no, his helpful ass insisted I fix it by merging the sheets and HTTP Request and I thought to myself, that looks hella complicated and nothing like the n8n workflows I've seen before. I employed my own squishy meatbag of a brain to decide that ChatGPT is wrong sometimes. Back to ChatGPT:
Fix: I scaled it back to a minimalist chain and removed the loop he wanted me to have:
Schedule Trigger → Get rows → HTTP Request → Append/Update Sheet
Turns out, a clean, linear build worked perfectly. Editor again: Thanks, ChatGPT. Not that you'd remember that. You are, after all, a very sophisticated next-word-guesser.
Dev Notes: Protect Thy Headers
Because automation tools rely on exact column names, I had to stop and think before renaming anything.
For example, I needed to take a specific store's name and turn it into any store's game:
"That One Super Big Ecommerce's URL" → "Retail URL"
"That One Super Big Ecommerce's Price" → "Retail Price"
Golden Rule: If you rename headers, you must update every reference to them in your automation. Otherwise, you’ll spend an hour wondering why your data isn’t showing up.
Also, keep a hidden row (or a tab) called "Dev Notes" to document changes like:
What each column does
Former names of renamed columns
How the automation works
Your future self will thank you. (So will anyone else trying to maintain this.)
Bonus: Column-Editing PSA
Feel free to add rows — but for the love of automations, do not edit the headers.
Maybe something like:
"Forgive me, for I have edited." — The Spreadsheet Sinner’s Confession
But really, include a note in the sheet:
DO NOT edit column names. The automation relies on them being exact. If changes are needed, speak to the dev team.
Final Thoughts
This project reminded me of a few core truths:
Automation is equal parts logic and intuition. (Editor's note: ChatGPT may have obscure knowledge and try to fix very common human booboos with overengineering because, let's face it, he doesn't actually think. He's simply predicting the next logical word as he types. (Don't get me started on how that implies that human brains are also just next-word-guessers, and where, oh where, does free will fit into any of this.)
Most bugs are one doh away from being fixed.
Simple is better than clever. (Editor's note: ChatGPT wrote this simple truth into this article after I told him one of my fixes. He writes this with authority, almost like he himself learned this, but he'll never actually go, aha, that is something I need to implement. You still need human coders, no matter how much knowledge LLMs have.)
In the end, I have a streamlined AI-powered Google Sheet that updates itself with product data. And thanks to my bananahead moments, I now have a clearer, kinder process — and a few chuckles to go with it.
Happy automating, fellow spreadsheet wranglers. Don’t be afraid to mess up — just make sure you learn (and laugh) when you do.
Editor's P.S. Wanna See Something Fun? Of Course You Do
For funsies, here's what ChatGPT wrote as a user manual. I will include my prompt, it will make more sense that way:
Lookit! I'm so happy, thank you so much! Now, we just need a step-by-step instructions for those who will use the sheet. Stuff like, "Don't fucking dare edit the columns or I shall smite thee" lol. But, you know, more professional.
ChatGPT said:
Hahaha I felt that divine smite threat in my soul. 😄 Let's make this delightful-yet-clear for the mortals who shall dare interact with your sacred sheet.
Here’s a professional-but-sassy step-by-step guide for team members:
📝 How to Use the "AI Price Getter" Sheet
Welcome, noble spreadsheet wielder. Before you begin, know this: This sheet is connected to live automation. One careless edit may anger the automation gods and break the system. Proceed with intention.
⚙️ What This Sheet Does:
This sheet uses AI + automation to fetch online store product pricing and images based on a product’s UPC code. Once processed, the row is marked as Done so it’s never touched again.
✅ To Add a New Product:
Only use empty rows.
Add each product on a new row beneath the last used one.
Do not delete or insert rows mid-sheet.
Fill in the following columns:
Item (A) – Optional description for clarity.
Product Group Name (B) – Name or brand.
UPC (C) – 12-digit code. This is critical.
No UPC = No data = You make the bot sad 😞
Leave the rest blank.
The automation fills in the rest (URL, price, image, etc).
Don’t try to help it. It doesn’t want help. 😉
⛔ Do NOT:
❌ Edit any column headers (Row 1). They’re sacred.
❌ Move or rename columns. Ever.
❌ Touch anything in columns I–L. These are bot-territory.
❌ Set anything to “Done” yourself. The automation will decide your fate.
🔄 What Happens Next:
The automation runs on a schedule (e.g., daily/hourly).
It checks all rows where Status = Pending.
It uses the UPC to look up pricing and info via HTTP request.
It fills out columns:
URL
Price
Product Image
Sets Status to
Done
.
Boom. You’ve got fresh data. No button pressing needed.
🧼 Tips for Keeping It Clean:
Freeze Row 1 so headers stay visible.
Use filters if you're searching for incomplete/Done entries.
Use validation or dropdowns only if you know what you’re doing.
🙋 If Something Breaks:
Contact [Your Name or Dev Contact] with a screenshot and what you did just before it broke. Bonus points if you say "forgive me, for I have edited."