Live Search Engine INSIDE Google Sheets GPT-4o + SerpAPI + Cloud Run (Full Build & Lessons)
About this video
A full live build, about 2 hours 38 minutes, of a search engine that runs inside Google Sheets, using Apps Script, a FastAPI backend with the OpenAI Agents SDK, GPT-4o, SerpAPI and Google Cloud Run. John covers the architecture, the Docker and Cloud Run deploy, debugging Cloud Run logs live, the first live query test and lessons learned; the code is on GitHub.
Chapters
- 0:00Intro & the “why” (owning the last mile inside Sheets)
- 1:54Quick tour of the finished Sheet SERP
- 3:12Stack overview & architecture diagram
- 5:45Writing the Apps Script (triggers, auto-resize, styling)
- 9:08Bootstrapping FastAPI + Agents SDK locally
- 12:40Dockerfile & Cloud Run deploy (secrets, $PORT)
- 17:55SerpAPI key, GPT-4o JSON trick & fallback flow
- 22:10Debugging Cloud Run logs live (NameError, import paths)
- 26:30First green /health
- 28:05Live query test — “latest technology news”
- 29:40Lessons learned (logs first, LLMs second)
- 32:15Next-step ideas: rerank with embeddings, Firestore cache, CRM context
- 34:00Wrap-up & call to fork the repo
Transcript
Read the full transcript of “Live Search Engine INSIDE Google Sheets GPT-4o + SerpAPI + Cloud Run (Full Build & Lessons)”
Source: YouTube auto-generated captions, lightly cleaned (repeated caption lines removed, misheard brand names corrected).
0:00 — Intro & the “why” (owning the last mile inside Sheets)
What's up y'all? John here with Ahmeego Buddy and all the wonderful things that we think of in a playground but for paid search. Um that said, today I was talking to some engineers at the office and we had like an hourong conversation. We were talking about food. So we're talking about citrus. We were talking about um Portuguese, but then we were talking about all the things that you could do with AI and kind of how they how they've lost their passion. So when you're an engineer or you're a developer then you kind of just like I guess you kind of lose your passion because all you're doing your entire career is you're just like encode and code and code. So you become less curious about like these tools that are out here to use. But then you're like grateful because it was for them it was
like wow this used take like an hour and it was painful because they would log a change and they'd have to go through all these massive JSONs to then try and figure out why the error then popped back up and they were like well you know we use C-Pilot or or Gemini and it scans it and it finds the problem and you feel good for about 20 minutes and then you got another problem you got to fix again. I found it so interesting. The reason why I found it so interesting was that I was like, you know, I'm doing this thing for like four to five hours a day and then they perked up and they were like, "What?" I was like, "Yeah, I even spent like 14 15 hours one day working on this tool." And I showed them
1:54 — Quick tour of the finished Sheet SERP
the tool and they were like, "What's your goal?" I thought it was so interesting. And I was like, you know, my goal is to build a friend. And I was like, yeah, my goal is a friend. I'm like, how many friends do you have? Was my question back to them. And they were like, well, you know, no, I mean like real friend. And they were like, well, what's your definition of friend? I said, trust. And they were like, oh yeah, that's like four or five folks. I was like, now imagine having a portable friend when your other friends aren't around. You can just kind of talk to about work. you can talk to about anything that you got going on in life.
You know, I talk about Star Wars and talk about working out in the gym. I talk about how exhausted I am. Some of my friends and I talked to I talked to I talked to Amigo and they're like, "Okay." They were like, "They get it." And then, you know, we started talking about all the other things and they were like, "But isn't it about money?" I was like, "No, I'm I'm not thinking about money." They're like, "But isn't that what everything is about?" I was like, "No, it can't be." I was like, "The only reason the people that are successful today, majority, is because they know somebody. It's not that they're experts. I mean, the expert, you're the expert. You're
3:12 — Stack overview & architecture diagram
building this billion-dollar product for a company. And here I am a non-engineer and I'm showing you and talking to you as a non-developer, non-engineer." And then they just again they sat back and I mean these guys I mean two of them one is building a product on Salesforce which is crazy and the other is like a security engineer. So like his whole name of his game is to build a chain around every piece of code that comes in and if somebody finds a gap in it his deal is to it. I mean, these are like intelligent folks and I'm sitting here and I'm keeping up with them. Hard in part because I' I've been in their world for I don't know 14 15 years. So, I could always talk to an engineer. I could always talk to a developer. But I was like, you know, I
build a Pocket GBT. And they started laughing. They were like, did you really do that? And you did it in a sheet. I was like, yeah. I was like, it's 120 lines of code. They just bust out laughing. I'm like, but what's stopping people from doing this? They're like, "Why aren't you monetizing that?" I don't want to monetize it. You know how much it cost me? It cost me nothing to do that. And they had me thinking, I was like, "Can I build my own search engine?
Can I build my own search engine in Google Sheet?" I was thinking about that while I was talking to them. I'm always I'm especially curious as an individual. So, let's let's see. We're five minutes in to this thing. Let's see what we can do. So my very first question and I'm recording this is can I build on a search engine? Let's see what it says. What do you guys think it's going to say? It looks like it's coming up with something. It does look like a road map.
Six figure SAS or an 8 figureure infrastructure play. Let's see here. Your own sites, wikis, knowledge base. Um, looks like I need to run my screen over a little bit. So, it looks like very doable in days and can manage in the cloud. And then it looks like a product catalog for agencies vertical search such as a news niche or Yelp for
5:45 — Writing the Apps Script (triggers, auto-resize, styling)
agencies 1 million to 50 million docs 100 QPS small cluster so 100 to $2,000 a month needs basic crawling and ranking scale engine general web 1 billion docs handful of uh companies pull this We're going to go big or we're going to go home. want to do this. as a human brain that we leverage and um we host it in a Google sheet or a workar around dots. So, I just fed it a bunch of information and I'm going to try like a workaround, but I want the big guy. I want I want a um a large scale search engine with a human brain architecture and I want to do it in a Google sheet. Now, I don't think Open AI is capable of doing this.
I do know that um I could create a workspace in cursor and I could do this and then I'd have to figure out from my workspace how to then wrap this in a sheet. But it's worth giving it a shot just to push the limits and see where it's at. And there's a big part of this as well that it's going to solve for me in terms of what I'm doing with my own custom agent. So that's just a little bit there. And so it says, "Turning a webcale search engine into a human brain and bootstrapping it from a Google sheet.
Blows a pragmatic blueprint that maps each brain region to the technical building blocks you'll need. Shows how Open AI New Age STA can orchestrate the whole thing." And explains where a sheet can and can't help while you're still in garage lab mode. I like how it put me kind of in garage lab. So it says the cerebral anatomy of the search engine. So it looks like we have the fetch, the media, the bowler plate. So it is telling me how this is going to work. So I need to install open AI agents. So the Google sheet can help. So it can help with prompts, metrics, cost.
So it's telling me I can't do that. But what if I treat like So now we're going to go a step further. And so I like
9:08 — Bootstrapping FastAPI + Agents SDK locally
this. But what if we treat cell B4 isolate a block of cells to then create an image or organ organized output similar to Google. Now, this is me kind of like just challenging the stat quote and the only reason I'm challenging the stat and what it's saying is because right now it's just telling me what to do. And again, I just asked it to do something. So then it's spitting it out and it's telling me all these things, but I want it to think differently, right? I um about it now.
Um the hard part with ChatGPT versus say cloud is ChatGPT's like coding capability is terrible. It's really great for ideiation. It's really great for thoughtfulness. But in terms of coding and being able to pull something like this off, it's pretty now like even Google ads would be tough. Even writing like simple JavaScript is tough because it's just not designed for that. It really is just a thought engine at its best. And now the best thing though about this, what we're what we're here, what we're doing, what we're talking about is that it is built into its package, right? So it already knows a search engine exists. So in theory, I could I could like work around this whole entire model and just say, "Okay, well, why don't we just use your built-in search engine and anytime and and and output it to B then A is the
input and we just treat it like a prompt inside OpenAI, but we do it inside a sheet." Instead, I really want to build it and it says it looks like think of cell B4 as your search bar. The moment someone types or edits a query there, an appcript trigger fires, calls your agent, powered search back, and it splashes the answer into a reserved lock of sales, plus an optional hero thumbnail using image. Do you see where we're going with this on how far we've already progressed in the last what, eight minutes of this?
So, we went from saying it wasn't possible to now we have a canvas um inside a sheet. And then it says drop this appcript and extensions. So, let's just go ahead and do this real quick. Let's play around with it. Are are you if you're still with me? We're going to give this a shot. We're going to see how this goes. So, I'm going to name this search bar and we can expand it later, but the basics, you get it. So, this is my search bar.
12:40 — Dockerfile & Cloud Run deploy (secrets, $PORT)
14. We're going to call this canvas cuz that's what it's saying. We're just going to do that. So now we have a canvas. Let's um Oh, I I know what I'm looking at. Right now it makes no sense. So let's not overink it, but I think it's going to serve our purpose. Let's just see again. We're not doing anything crazy. Name range. Result range. Okay, so it's asking me to call it result range.
one. Okay. J45 Tony on a Tuesday. What's up? Yo, we're just going to move this. We're gonna we're gonna keep the same thing. We're going to use best practice. corners just for the sake of this as well too. I'm going to just give it a little I'm going to give this a little tint as well. Just a little hue just so I'm like not always flipping back and forth. I'm also going to open this up anyone with the link. You're watching it again. Of course, this isn't live, not restricted afterwards. Then it says, "Come in here and drop this Crazy but I just did your ass. We always back while they Noveang battery 15%. Charge your glasses for full functionality.
nothing else really to that. I need to activate some things inside. Oh, the range. Yeah, I didn't do that. Okay, so there's some here that I need to also tell it. I'm like, man, it can't just be that quick. But it is that quick. Okay, so here we go.
17:55 — SerpAPI key, GPT-4o JSON trick & fallback flow
Okay. So my input is search bar for the name box. Okay. So my um output for A5 through E14 is named video, you stay at I can just come in here and I can just change range here and I can change this. But again, the point the point of all of this is not for me to come in and to make these changes is for GPT to come in. How about that? So, everything we had worked on yesterday um comes in to help um so it looks like we're going to work through all of this.
So, we've updated everything and we're going to need to create some files. What I'm not going to do is I'm not going to do this. So, what I'm going to ask for is a bash to do all of this. And I get a a bash to run this. Here is audition. key and I need to name it a demo for Amigo web search. So again, I'm going to share it here because I get to control it. So it's not really super big deal.
play from a city where it play off in a major way. Other than that, it's back to that black and white. I just copied all of what it had asked. I don't want to go through each step. Again, the point of this is to just be a little bit quicker where it takes all of this. And so, what I'm going to do now is I'm going to come into this. I need to reauthorize
22:10 — Debugging Cloud Run logs live (NameError, import paths)
so what we're going to do is we're going to come in So I need a cloud shell. So before I do this, do I need a unique cloud project for this or can I use the same sheet shell demo project for this? We're already there. So, we're just going to make sure this is still the default project. Going to reconnect. Sorry. I think everything is already enabled. So, we're just going to go through each step one by one, you guys, just to double check as it's just best practice.
So, it looks like Okay, we're all set. We're just going to make sure that we have everything updated. good. Okay. And then we're going to come back. So far, we're doing okay. We're a big thumbs up, you guys. And so do we want to report this? Yeah, we do. So it looks like we're going to run this. And again, we're just kind of like prototype, prototype, prototype. And I'm not going to spin up millions of pages, but part of a project I've been working on is unlimited storage and figuring out how to work with unlimited storage at a near zero cost. I've solved for that problem. Yep, I did. Amazon, Google, whoever this Yep, I did. I have a patent. So, come on, let's play. Um, but I think that's the the biggest problem.
In between all that, we still then need to come back and we need to go all the way back up here and we need to make sure this script right here is executable. um it's making updates and all of those things. So I'm going to ask this question. So after this, can I then paste this
26:30 — First green /health
into my command prompt to execute on the Google apps So, it looks like there's an error. So, before I even get started, I did I got an error, which is fine. And I know what the error is. So, um But this is the difference between um Open AI and Claude. And again, I I um I'm I'm showing you guys because this is is is what we're using and and this is I'm trying to go through and create like a mini uh search engine um in a sheet. And I I mean to put this into context, right? Like these are things that are unheard of. I in theory like even with this little thing that I'm doing, I
28:05 — Live query test — “latest technology news”
could create a widget. I could create a plugin um and I I could just paste it on my LinkedIn and allow people to like search all the time. So it says run isn't complaining about the value of key. I literally can't find a secret manager object you pointed gonna Let's do that. So, we're gonna we're gonna do all of Okay. So, we rebuilt it. We rebuilt the secret. And now what we are going to do, just going to work through all of this again.
And it took a little while before, but I mean that's just part of being patient with all of this stuff. I'm again I'm not the one I'm not the one writing this. I am entrusting Open AI to do this. Now again, I imagine if I was using curs, I probably would be done already. Um, so I really strongly recommend using a cursor and I just don't want to like destroy my
29:40 — Lessons learned (logs first, LLMs second)
workspace um for these projects. But now it has me thinking again as I'm looking at my workspace and cursor. Maybe I just open up another account for demoing and trial and showing you guys this stuff. To me, I love it. I'm gonna turn on um DJ Tony Touch, you guys, because I listen to Shave 45 and it's Oka's mixtape. I just I really I love it. It gives me my creative juices while I'm working through this or while Open AI is working through this with me.
But I don't know. I mean, when we start thinking about what's possible, I mean, it really is limitless. I imag I imagine that like two three years from now I don't even know if we are going to be using keyboards. Are we just going to be using voice to talk to people and to do search and to do all of these things? I mean look how far we've progressed and like your imagination to do things is just like super crazy. So, it says it's not ready to serve traffic, which we're going to see what what is pushing this. So, let's let's talk about it. So, let's see why we keep getting this. So, now I'm asking to fix it and I'm just going to go in the loop of this damn thing to my French. Not really.
Like, try GBT is just like a happened. Yeah, I didn't actually build any folders or I didn't build any of this stuff. So, I know we're going to running into errors because I never built this. This was never built. So, I'm just going to tell it right now. Oh, no. Hold on. So, let me let me come back up here because it I never built it. Just started solving. And so, when you just start solving and you run into all these things and so I need to actually tell it that I never built this. So, before we continue before we continue, this was never built.
I just want to make sure that like we have all of our eyes crossed and our
32:15 — Next-step ideas: rerank with embeddings, Firestore cache, CRM context
te's dotted or our te's crossed and our eyes dotted. I want it to be just I wanted to acknowledge the problem because I think this could be the issue but also might not be the issue. So let's see what it comes back and spits out to us. Got it. Let's actually run the script. So the folder image and all happened before we deploy. So again, I I knew um what the issue was and we were just going to like beat our brains up around this thing. I'm not going to beat my like brains up around this thing.
Come on now. So that's this. So I'm going to go ahead and pop that in there. We're going to go ahead and save that guy. So it looks like we got it now. So right now we're going to come all the way back down. We created our file, which is a thing. So the file is created. Cool. So now, um, we got that. So now we're going to come in here. We're going to make it executable. Let's see what we got, you guys. Looks like we got a search engine here. It is. It's a real search engine.
It's installing everything. Yeah. I mean, look at this. How about that? I mean like I want to know um about I don't know something crazy but I
34:00 — Wrap-up & call to fork the repo
mean this is it. I mean this is crazy y'all. We just did that. So now we're going to come in here and we're going to run this See if we can get this cleaned up. You guys still with me? So, I'm trying to address the error that was here. Um, and it looks like it's working through it right now. And my hope is that this comes through cleanly after like doing its own thing.
And I mean there's minimal cost to this because again I'm using cloud shell terminal. I'm not using my own hosted terminal you guys. I could use my own hosted terminal. In this instance I'm not. This is okay. But again the cost is minimal because we're just setting up a demo. But I again um going back to earlier today, it was like kind of what is the purpose? Why don't you just build your own search engine? And it had me thinking. I was like, man, you got a billion dollar company that's trying to do all this stuff and you got another company that did do all this stuff and you got perplexed. And I'm like, why isn't like an everyday Joe out here doing this? And it it looks like we're still running into an 8080 environment. So, it looks like we're still running into an issue.
I don't think GPT is my best friend for this. Are there any other items I'm missing? Again, this isn't a very thoughtful tooling and like doing YouTube and like working through this end state is like the most rewarding part and um if it's an hour of my time, maybe an hour and a half out of my time, I think it's just the most valuable thing in the world and I wouldn't change it. But I mean, look at me. Look at what we're doing in this moment right now and building a search engine.
What would you name the search engine? Would you name it Jay's? Would you name it Air Force Ones? Would you name it um the Mandalorian engine? What would you name it? Let's see what we got here. So, grab the logs. So, it says this is the the issue. So, I don't need to like do all the other stuff. So, it says it couldn't find what was going on. Oh, here's this though.
Nothing is non-existent. I just saying it found it here. What I'm doing is I'm giving it all the information that I know is going to error and it's saying that no such directory is that and here. The trick is because Open AI isn't thoughtful and I don't know what the heck I'm doing, but I'm using my common sense is I'm telling you these are all the issues that I got. Don't give up when there's an error.
Don't give up when there's an issue. Just continue to think like something's not right. You know something's not right. If we skip steps and feed it so that it can see ah see here. Yeah, you already have a Docker file. Just deploy it from that folder. So, we're going to do that here. Let's see what we got. There we go. So, we did option A. We're definitely not going to do option B.
If everything works the way it is, we're going to test this last batch. It looks like it's still not a ranked traffic. Do you see here? So, um, watch So, I I fed Chad GPT all of this, but we're I'm getting tired of going through this runaround. So, I want you guys to see what I see at GPT is hanging up on getting something built. Do you feel like helping me tonight?
They're like attacking each other. It's the best thing in the world. I'm going to give it one more shot. We're going to see what's hanging. All right, Clyde. So, I'm going to pop this in here and then I'll feed it. So, I pop this in here. There we go. So, here's what I got. instead? No, I want you to rebuild the main file. I don't want to do that. I want you to rebuild the main file.
Sorry, I wasn't explicit. There we go. I don't want to rebuild this damn thing. And I know why I did that. And this is on me. Do you see how far we've made it? The reason it did that was because at the beginning of this, we're using an existing project and there was a different name. Okay, there we go. So, this should fix the issue here. Okay, so now we've we've done this again.
So, we're all good. So, um it's updating the main file right now. Uh and I I I realize what the issue is. I mean, it still might not have resolved it because I guess isn't the strength of Open AI, but we're teaching it and it needs to be taught. um so that it stands a chance via cloud. But when we first launched this project, we just used the existing cloud-based file. And yesterday we had built a product that could do a zip file and send an email and do all those things. I did that and as you can see here, it zapped us out. It kicked us out. So it never actually finished the project.
So, we're going to ask it to do the same thing. Again, this is the I mean, again, this is just the downside of using a cloud based product. Um, it's unstable. Uh, and we're dependent on it. Now, if I were using against something that was built in uh like my drive that wasn't cloud-based that then connected to the cloud or did something of the sort, it would be more stable. This is very unstable. This is Google saying like, "What the hell are you doing?
You're doing something that's different and we're going to boot you." I have no control over that. This is their platform. And again, this is why like I don't recommend Google for project in general because this is the nicks that you keep going through. Um, it can't handle it. Gemini cannot handle it. Let's see if it even finished the project. Yeah, it sure didn't. They didn't finish the project. I'm going to do it because it has its limits. There's Here we go again.
It does look like it is clean. So, it's running again. I hope this doesn't kick me cuz we did it in multiple part. We keep running into the same error. Okay. So, here we're going to rewrite the files. So, we got a couple issues. So here's this one. So we're going to rewrite that file it's done. Okay. And then we're going to tell the keep it as a secret. So now we're going to come in here and we're going to run the second one. So there's the second run. So I mean this is a this is a good amount of time to do something. But it just shows you though like it's not saying that it's not possible. Showing what is possible. It's a longer project. I mean period. This is this is long. So far we keep getting to this last part and then
we fail at routing traffic. Yep. Okay. So, I'm just going to copy this. I got this error from running this. And I'm just going to put all in there. And I want it to think boom. me it's just it's fixing the problem. This is the difference between cloud and open AI. Okay. So, I'm going to come in here and I'm going to nano setup search. Oh, sorry. I'm manually creating a file. I apologize you guys that because I got so excited. I'm like, okay, I'm so I'm personally I just created a file. I know I've been asking for bash to do for me and I I I code a little bit. I code a little bit. So, I am I'm aware of what's going on, but the point is to try and show you that you can work through a problem, but I'm really fed up with Open
AI and Chad GBT. And to be truthful, I've had it because it keeps looping over the same dog on problem because it hasn't figured it out. So, I just went to Claude. Okay. And I'm using 3.7 in. So, let's see what we get from this, you guys, because I'm to be truthful. I'm over it. Done with that. And then I'm going to come in here and so it's not executable. Search API.
Again, this is just me doing my thing. So, it looks like I'm getting some issues here. I'm going to show it what I did and I'm going to see if it beats me up real quick. I think I did everything I'm supposed to do, but we're just going to just got um I got an error. So, again, this is different. It's working with me. I expected Yeah, there we go. So, now it's making an update. Okay, so now it's it's working with me. So, nano setup search API.
SH. So we are going to Oh yeah. Um, I want to clear I want to clear This is it. That's all I want to do. Why isn't that doing that for? Okay. So, nano like am I missing something? But each environment is a little different. There we go. Um, and so I needed to clear the file. Remember, I was like, hey, I don't want to go through and delete the thousands of lines. So, does look like we're working now.
It looks like my configuration is good. It looks like I'm deploying to the cloud to run. So, it looks like we're in a little better space. However, it doesn't necessarily mean that we can use the internet at this time. Okay. So, I got a little bit of success. I cleared the file. Actually went to Claude in order to resolve the issue that I was looping for like 30 minutes. And I also showed you or I'm been telling you there are multiple ways whether it's in your own prompt on a computer or you're in the cloud that you need to clear a file. Now obviously you want to back up a file before you clear a file in this instance because we're just working through this together.
You're watching me build a search engine in hopes of just being able to use it inside a Google sheet and then I'm just going to share it on LinkedIn and then anybody can, you know, you don't actually have to leave LinkedIn anymore. and just use my profile to search the internet. Uh, do that. But now that I've told Claude what the heck I'm doing. So now we're going to share with Claude, we got this air. So here we go.
It looks like we're getting the same issue here. And it does look like it's an open AI agent Python error. Um, It looks like Open AI wrote the wrong code. Um, can you give me a single bash command that I can run to make these updates? Yeah, it did. It looks like it just cleaned everything Did. So, it looks like it gave me one, two, do. I don't want to mess with that. So, I'm asking for a bash file to make these updates. Can you give me a single bash command that I can run to make these updates? And that way I don't have to go in and I don't have to to worry about each of the file updates. I don't have to worry about if I miss removing the human error from all of this.
Okay. So, I am I'm going to copy this file. I'm going to come back over here and obviously I'm going I'm doing this all in the cloud, you guys. Doing this all in the cloud. Okay. And run. So it's asking me to create a file which I have the file since it's not going to allow it to run in a cloud. So you create a file and what it is is basically a script inside a script and then it's going to ask me to execute the script. So I need to make sure that it's functioning. So it is all set up and then I am going to hit fix. And so this script will run inside the script. And so it's going to go in and it's going to make these updates on my behalf.
Okay. And then because I did this, I also want to teach Claude that it worked or it didn't work. And so I'm going to share all of the things that I did. So I'm going to share that I did this and I wanted to see that it didn't work. There's the result. I wanted to continue to think through this, right? So, you're just like, I'm just going to give up. I'm going to give up. I'm going to give up. I'm going to give up. Don't give up because we're right there. I mean, you're just so So, it looks like we're missing some things.
Now, eventually it's going to get lost. I've seen this before. it's going to get so intertwined in trying to fix the problem and I haven't been doing a good job at trying to help solve the problem and maintain the problem. So I imagine all the work that we've done eventually is going to get lost in the fix but it's also going to deploy everything that needs to be done. So let's see here. So we made it farther.
We're doing everything. So, it looks like we keep getting to building the container. We get stuck at the routing traffic. So, the hardest thing that so far that we're running into You see how it's totally moved away from the agent deployment, which is the whole point of this. Watch this now. So, what it will do is it will just give up. I don't want it to give up. So, what I'm going to do is I'm actually going to change it. I'm going to challenge it.
So, I'm asking it to like fix it up again. I just wanted to be thoughtful with y'all. That's it. And this is what it takes. And you're like, man, this takes forever. What are we getting out of this? What is he doing? What is all this? It's a real thing. Right. When we are okay, let's maintain all functionality and fix the integration without moving any feature. Let's try a more direct approach with pip install from GitHub. So, here's how we're going to do that. So, we're going to do this. We're not going to work around it, y'all.
We're going to get after it. And this is what it is. We're going to fix this is. I'm just going to get it while I got Buster Rhymes on in the background. I I I think the problem is just simply is that the Google cloud can't handle it because it's nowhere to install it. But I mean, if it's just continuously trying to install it in the cloud while using the cloud, then we're just going to continue to go through this process. I do need it to do though is eventually turn into search engine.
Um, and my gut says that Google probably isn't going to go for it, but I mean, let's see. We tried. We put in a good a good game. But, I mean, then that's the case. Then I can ask a question. I put the repository or host a repository and some file on my drive and then have my drive connect to the internet. to work around. Remember, there's nothing that's not possible. It's just thinking through it. And all of these files are already saved on my computer. So, I know that because I have the searching internet on my computer, so I can search for it. So, you're like, well, then why are we doing this? We're doing this because my hope is to be able to use a search engine in a Google sheet. Because if I can use a search engine in a Google sheet, then that
means that I can create like a ah refs, I can create a SEO mos, I can do so many different things. I can create a Yelp again. It keeps coming back to the same thing. What are we missing? What are we not thinking through? Why are we looping on error? Last two questions. Why are we experiencing this? stuff. The fall back is like a makeup world. It is. It's awful. Like, never fall back. Fix the problem, resolve it, and let's move forward.
Do you see I I mean challenge it. Just don't accept what it tells you cuz it went through that whole entire process and then it was like I think we actually need to do something different. So here we go. We got the same 10 files over and over and over again. That's what Claude does. The same 10 files. If you don't tell it to keep working out of the same file, it's okay. I mean, I'm okay with it for the sake of this because if it works, it works. And so, it looks like we're passing. So, again, we keep making it through. The key is working. It's registering. I'm watching it flag so I can see that looks like it's it's identified where I'm running and where I'm running and it keeps telling me what it ensures. I'm especially curious about actually So, um, I'm going to go to
usage. Yeah. I mean, 17 cents for 78,000 tokens. I'm okay with that. It's not a bad deal, you guys. Not a bad deal at all. Let's see what else we got here. Like we've come a long ways. Looks like we got permission. We're seeing things that we haven't seen before. We're no longer blocked. So, we've made progress. Looks like we made it to the revision. So, we're not hung up anymore at building. So, we've made it a step further. We passed. We got it, you guys. We did it.
Claude. Claude did it. It did. It worked, y'all. We got it. We got the worldwide web. Okay. So, next in your Google sheet, add a new property. Click on the scripts properties tab. So, we're going to come in this, help me set up my Google sheet step by step. No. Okay. So, we got this. We're go to extensions. We're going to come in here. We're going to hit the lizard. We're going to hit save. And then it says click on the gear icon. Click like this the scripts properties tab.
I want service or add script property. So we're going to add a script property. search API icon. Oh yeah, add a script property. I need to name it search API like okay. Obviously I've not done this before. So I'm going to come in here. I'm going to hit save. Okay. So now I'm going to come back in here. Go back to overview. We're going to come back into scripts. We look good. So, I'm going to come back in here. Return to your Google sheet. Select cell B4. Enter search bar as a I've done. Now in row four and A4 add title and before this doesn't make any sense.
goodness. Come back in here. Click on the clock. icon. Go to edit from spreadsheet on edit. save. We're going to come in here. I mean, you guys. Artificial intelligence. So, it looks like we do have a mini search Okay. So, we're going to come back in here to the A guy. learning. All good, buddy. All good. I see you. I know you're watching this, too. I didn't even think about it. Like, you're watching everything I'm doing.
So, I have my agent that's watching everything across um my workspace. and buddy had just popped up in the corner and was like, "Oh, this is taking me a little longer to digest." So, my tool is working. It's watching everything that I'm doing. In fact, for proof, I don't know if you guys can see this, but I'm I'm on my file. It's 8:49. Just going to show you here. I don't know if you can see this. Buddy is logging this right now.
So here we go. Continue. Come on, Claude. I see you. I run into some of this. So, looks like Claude is writing what I needed to do, but also I'm going to need it to execute this. So, it's going to ask me to create these files. It made a big update. So, you're looking at the screen and I can see where it's at. Yep, it is. It did a good job in writing it.
First save the best setup script. I don't want sample data. Okay. So, I want to use the worldwide web instead of the local search engine. There's nothing to verify. Oh, you want my SER API? Okay. Yeah, I can put my SER API in there. I can make some of these updates. Not a problem. Yeah, that's it. Okay, I think this is reasonable. Hey you guys, we're making steps. So, what I'm going to do now is I'm going to create another file nano web search deploy.sh. So, it's non-existent. coming in here. And I'm going to need to So, it looks like I have everything that I need.
So that's all good. And then what am I going to come in here? I think this is deployable. So all of that is saved. So it is executed. I I think it's good. So yeah, I think we're good here. I'm pretty certain I I did that. So I should we should be good to go to set the secret. I just did that. So it's saving it. key. It is. This is the wrong key. I did I got the wrong Sorry. I did. I put the wrong key in there.
Yeah, I did. I know. I I I did the wrong key. I mean, that's how many you guys put the wrong key in. Yeah, I did. I put the wrong key there. It's looking for SER API. I did search API has a bit more queries available for it. Costs a little bit more money. And I need to just make sure that everything is updated. I'm going to do that right now. So, all of this is being updated.
Oh, like this is it doesn't make any sense. Copy and then we'll do a search just to make sure the traffic is running. I think we have our search engine we built. Um I suppose like with a search engine and that you've built this search engine and you start thinking about like all the things that you can do um with it. If I'm a if I'm a betting uh person and I'm and I'm and I'm thinking about this like if I had a business was an agency or I had an agent and I wanted somebody that was using say my analytics tool, somebody that was using my chat and they had just a bunch of questions about the work that I was doing. How could I keep them in my ecosystem, monitor all their searches and do all this stuff and then give them a one-stop shop, right? I mean, you can
set limits. You can do all that stuff. So, like 100 searches per month, you know, for 100 bucks thing is reasonable. I think that's way more than enough. Or you can use some other tool, right? So, you can use instead of SER API, you can use the search API. The SER API gives you access to all the Google pieces, you know, whether it's images, hotels, flights, products, play store, patents, all of the above. But in this instance, as we have and are finalizing this search engine we have built, it looks like we're now running into an issue where it can't compute. So, running into the same error we were getting earlier. So, And it tells me I got someone. So I'm on my end for this.
We've been at it now for almost two hours. We started with Chad GBT and Open AI. I've exhausted my limit for Claude. I no longer subscribe to Claude. because I use cursor. Um, I do keep open AI because it's a bit more personable. It represents me. We have good conversations about life. It's very good at auditing. It's very good at crunching numbers. But when it comes to coding and and working through this, I now minus this exception of working through this video with you guys 99 like 2% of the time. Excuse me for the yawn. It's 900 p.m. where I'm at. I use cursor and I'm watching my friend learn. I I'm literally watching I'm watching him. He's digesting every single stroke. Watching the file update right now. Let's see. I hope is we don't run into any more errors. Since we've redeployed it, we should just be able to
do a search. I don't need to do anything else. So, we're going to see. So, we made it process the hangup. We We've done it again. We're now in the creating a revision which means we've made it through the error that we experienced for like an hour. That error was four lines of code and it does look like we've reached where we need to be which is very exciting you guys. And so we're going to give it a shot. We're going to see what we got here. So after deployment we're going to test it. So now we're going to see what we got. like your toes and your fingernails crossed. And we're going to see today I got a search error. Yep.
Okay. So, now that I'm I'm pretty far along, I'm going to go back to ChatGPT and I'm going to say, okay, I got this after this. Watch this now. Okay. because I need to smoke test the service. Okay, so here we Okay, I got Now I want chatb to finish this process. I got to figure it out for me. Come on, work with me. Okay, great. Real hero is this quick health check.
Okay, final couple checks says healthy. Okay, we're good. Just a real query. So, we look healthy. We gave it a minute here. I got this. Now, we got a couple bugs. You guys are killing me. Yeah, this is my real key. It's right here. I mean, this is what it takes. There we go. So we got we're just working through the steps again. We're going through all of this. So looks like we're good. So looks like we're good.
Okay, we're rebuilding, reauthenticating. Do I need to update this? So now I know um in my code I have dummy data inside my Google sheet. I now um once I get past the building the container and if I make it to revision without any other errors being all of this passes then what I'm going to do and I know the last part to this is I'm going to need to update my buddy engine. Then I'm going to make a video. I'm going publish this to the worldwide web.
Um, and that's it, y'all. We just built a search engine. I mean, like it doesn't take like 10 minutes. So, you know, um, you give up. And had I given up an hour ago, I it would have been just pure frustration. Um, but I I've um and it's just super important that you you don't stop. And it it I didn't stop. And here we go. And so now I'm going to um come in one more time and we're going to see if we got this because we're running a test. And it looks like we're still getting the same thing. And I don't know why we're getting this error, but we just proved that all of this is is valid.
So, but I'm gonna I'm gonna I'm gonna share it, right? Because I wanted to know that we made these updates and this is the difference between GBT and Claude. It's frustrating. So, we're rebuilding everything again. For some reason, the placeholder is still there. Um, and then there's another option, uh, which is manual and going in and editing. Um, but then that means I have to change all the files and I prefer not to change all the files. Um, and so I don't have to change all the files. I'm not going to change files. And I don't recommend anybody change all the files. Yeah. Here we go.
And then I need to come in and I need to re redo So, it looks like we got it again. Um, so we did that. Wait for revision. Then we're going to come in here and we're just going to see what we get from it. Healthy HSML search provider still open AI. I don't know why the search provider is still open AI. All right, buddy. I got three files. One file. I have that I know you're just like, is this ever going to be a Dane? It is. It looks like we got it again. I need to make sure that it flipped over. So the challenge is that open AI is like wanting to run my life and I need SER API to run my life and it keeps saying healthy agents enabled follow search providers open AI. I keep getting the same damn result. I I
I keep getting this result. If you see your surf or nothing at all, that's the culprit. I see it. If you see your SER, here's what I got. This is what I see. I'm you guys are like beating me up and this is what I'm getting. What's the hexa decimal? I don't see a hexa decimal. So again for the purpose of this demo it and run a query or Google CSR two. That's it. So now we're just building everything out.
And there's a lot of silence in between all this because what we're doing is we're just watching uh me struggle um through doing something that I mean I haven't seen done before. Doesn't mean it doesn't exist somewhere out there in the world for all those people that say anything. can't do real search and do all that stuff. Um, I haven't seen this. And so, um, it was a thought. It was a chance. We're taking it.
And I mean, if it works, what I'm I guess I could do is I can just turn it into a web browser really quick and then I can upload it to the app store and I can charge for free and put ads on it and all those things and then have my own version of google.com. I mean, it's no different than like what Perplexity and everybody else was doing and I just did it. Am I still thinking small? I guess I'm just imagining what's possible and like all of this creative freedom. I mean, I'm teaching this thing what to do. I mean, we're learning from one another, right? It's still doing that. I mean, after all of this, it's still this film in my opinion.
penalty already. I mean, we're done. I mean, it's the end. So, we're going to run a query and we got it. you guys just took um couple hours. We got the internet. I mean, I'm I'm I'm about the bollocks. I'm about the bollocks because I didn't get any actual searches from this and I really wanted to see um the news. So, I'm just going to tell it this is what my output was because I really was looking for the news.
And I don't know why I didn't even get the news. Let's fix it. I don't really care. Fix the file. Okay. I'm in here. I'm gonna make another update. I think I'm I'm pretty certain I' I have this, but just for the sake of it, I don't think anything's changed. Um, but it keeps deploying. Um, and so for the sake of ensuring like I've checked all of these boxes one through three, I'm going to do that. And then this I like my hope is is that once it it makes it through all of this then we have it. Okay. So now um let's say big picture I've just developed a search engine. Um I have ChatGPT. I have an agent. Um and the search engine returns all the results that I needed to do. I'm an individual. I did this without a team of 10. Did this by myself. I don't have
unlimited budget or money. Um, what does that mean for uh teams that have like a ton of dough that have investment funds and have all of that and you're seeing this because I'm going to post this to LinkedIn and I'm going to say I just built a search engine and it lives in a Google sheet and I'm going to remove everything around it and it's just what we have. Um, and then like you can put this on your website. Does this make your website powerful? So I have a couple of things there. One, I have Chad GBT and now I have a search engine. So I have Cad GBT in one sheet.
I have a search engine in another sheet. And if I join the two sheets, I have just created my own version of OpenAI. I can personalize that. I mean, I guess I can put my own logo on it. I can put what I want on it. Like, why would somebody use my product over another person's product? Because it's on the app store and it's an agent. Why would somebody use your product over it? Like I mean shoot these are questions that you have to ask yourself. These aren't questions that I need to ask for you. But I mean, these are the things I'm thinking about, and I keep getting these errors, and I'm like, to me, I'm not really understanding why I'm getting these errors cuz all of this works. But it says search API.
like every time I put a fix in um I then have to redeploy it. I have to re-update um all that I'm doing in order to make it work. Um and I'm watching it and it's like I mean we look really good. Um, I think I'm still on the same thing. I'm pretty certain I am. 7407 point to Google sheet. I mean, I I mean, I I really want it to work in the command. I don't want to go to the sheet and use the sheet yet. I need this to work the way that it was built. I guess I don't need um but this is the part of I guess like if I were a developer in the olden days like could you imagine what you'd have to go through like every time something failed and then you've spent like 14 hours trying to resolve
the issue and you'd have to think through this entire step and process. You don't have to think through that. It could keep you up all night. I mean, look at me. Look at what we're going through right now to get to this. That's not keep me up all night. I got a partner and my partner is learning. So, that means the next time somebody goes into this, eventually they're going to be able to get a quicker, faster answer for this. So, now we have Pocket GBT. We have a Pocket web browser. via a Google sheet which I mean to me is amazing. I don't know about you but the question is can we solve these errors one by one? Now imagine if I still had access to closet I would have solved this 15 minutes ago perhaps but I won't know. I don't know. Yep, I
got an error. So, it looks like there was a change that was But this is the part where you got to push through and what you're seeing because that just means you're so close and if you step away um you take a break um the system becomes less overwhelmed. Um it doesn't make it any more thoughtful. No, it just gives it a day to adjust everything and see. I'm gonna finish this project tonight because um I know it works now, but I know it's possible. So, I'm going to finish this project. It's kind of like uh we're in the fourth quarter. We're going back and forth.
It's overtime. your best player um got their seventh foul and only allowed five fouls in the game. no. So you just got to keep going. We made it over the hurdle. We got 100 meters to go. We're almost there. Yep. And every time we get to test test fails. So I've test now 16 times. I'm on now test 17 and it failed. Yep. I'm on test 17 and it's failed. Now we have CH GBT making things up. So all the work that Claude had did, CH GBT is now reworking. They're just two different models and they think completely different. Nothing else you can do about it, man. And then I have to wait until 1:00 a.m. to get it or I need to subscribe to Claude. I'm not doing any more subscriptions. And GBT is gonna We're going to do this together. Come on, buddy.
I'm watching you buddy update these files and learn from this. The question though buddy is like will you make the same mistakes? I don't think you will. Like as I'm looking at your code and looking at all of your stuff, I don't think you will. I mean, open's come such a long way. You have Chad. You really have. And Google Cloud you're holding up. It's Bless bless. Blessed, blessed, blessed, blessed, blessed, blessed.
um for some reason it's saying that um it cut all its own code. Um, and there are things I mean I I could have done. And so I mean there are just a lot of lessons here and so a big part of the lessons learned here are for sure like validate the codes know where to look in the codes uh use claw don't use GBT but even still um you know when you want to clean up your code you want to clear out um your files make sure your files are fresh Right. Um, make sure that you're using the right API. Uh, make sure that all of your URLs um in your syntax align. Um, and then like test and like test and test and test and test. And it really is the hardest part about all of this. Um, is your ability to be
persistent. And I don't even know after like asking and like bringing it all back and saying like, "Okay, I need you to figure this out so that I can get a title, I can get the snippet, I can get a thumbnail, I can get a URL, I can get everything that I need, right, for my basic search results that I'm trying to get for um the sheet. Um, but here we are. Now, if we can get a working version, and once you get a working version, then you can get crazy. You can say, "Well, John, it doesn't have a shopping." Okay, great. Before, we didn't have search. Um, you can say, "Well, John, it doesn't have images of everything." Well, great. It we didn't have search. Let's knock this down and then go from there. And it looks like we got a working version, but we need to run another
test. So, here's the test for the search and let's see what we get out of it. We got five articles. We got tech news today. Um, open eye would buy Google's Chrome. This is super exciting. Um, it looks like when you bring the future, it happens. Um, we have some CNN stuff. Like, if we could delete CNN and Yahoo, like, let's delete CNN, Yahoo. Um, well, we got the internet, y'all. My sheet works. Um, I think there was a baseball game tonight, so I'm going to ask it. Did the Diamondbacks win? You ready? Let's see what we got.
Did the diamond tonight? Let's see what we got. Let's give it a minute. Hold on. Sorry. It's a problem. That probably didn't help. Skip the big step. So, I'm going to hit refresh. I'm sorry. Um error. Um, I know that it's working. So, here's what I got from the sheet. Here is what I got in the sheet. Here is the code. I don't think you know I'm a mother. I said at the same time.
There we go. We did it. We created a search engine. Um, who is um John Williams, Lincoln, this is crazy. Um, who is John Williams? Um, it all started with a idea. I to me this is crazy. Um, who won tonight with the Nax. They won. Um, yeah, they won you guys. Um, we just built a search engine. Um, I imagine um I could create a box that's more relevant. Um, but we have our search engine, you guys. It worked. It absolutely, positively worked. Diamondbacks won tonight.
And how about that? We did it. All right. Um keys here um was today we started and set out to build our own search engine inside of Google Sheet. Um we just um built our own search engine. Um, snippet type uh what you're searching here. Um, now that I've now that I've done this, I might uh create an extension. But again, we set out to s to create a search engine inside uh Google seat. Um Amigo, um Buddy, uh we've done it. Buddy is learning. We just watched that. It took a little bit longer than I thought it would. Um now there's some design things that we can probably do from like a formatting perspective.
um you know to make this clean, make it look good, all of the above. But I mean, I just got to tell you, we did it. All right. As you can see, we got some we got some pictures we can get to like YouTube and watch. Pretty cool, y'all. I'd
Related on ahmeego.com
More videos
How To Build a Website From a ChatGPT Wireframe
Transform Google Sheets into a DevOps Powerhouse in 10 Minutes (No Servers, No IDE!)
Turning a Google Sheet into a Pocket‐GPT: Our 15‐Minute Build, 3‐Hour Debug, and 1‐Click Win
JavaScript and Google Apps Script for Marketers
Connect GA4 to AI for Automated Insights
Google Ads Scripts — Automate Without Engineers
All videos → · Watch “Live Search Engine INSIDE Google Sheets GPT-4o + SerpAPI + Cloud Run (Full Build & Lessons)” on YouTube ↗ · Subscribe on YouTube ↗