Claude Code + Nano Banana 2 = This Changes Everything

Tech With Tim · Beginner ·🧠 Large Language Models ·2mo ago

Key Takeaways

Demonstrates image generation using Claude Code and Nano Banana 2

Full Transcript

You've probably heard of these state of the art image generation models like Nano Banana Pro and Nano Banana 2. Now, these are extremely good models and you can create some really interesting images with them. However, they're a little bit inconvenient to use. Most of the time you need to actually go to the website, type in the prompt, and you get mediocre results. So, in this video, I'm going to show you how we can combine Nano Banana, specifically Nano Banana 2, but you can use any model you want, with Claude code. Now, this gives you insane results because rather than you having to manually generate the images, you can have Claude code do it for you. This means that you can create stunning websites with all kinds of visuals generated by Nano Banana. This means that you can spin off 20 generation tasks at the exact same time. This means that you don't actually have to prompt the image generation yourself, you can have AI do it for you, which gives you a significantly better and much more detailed image. This does change everything when it comes to generating images and allows you to do it from one interface that you're probably already using, rather than going back and forth between a ton of different windows. Now, funny enough, when I was filming that intro, I was actually having Claude code generate a bunch of images for me and create a full website that I can link you guys to to make this video easier to follow, and you'll see that it looks something like this. Now, what you can actually do is go to the site, I'll leave a link to it in the description, and it's going to have some of the resources that you'll need for this video because we're going to be downloading and setting up some various skills. Now, if you have a look here, these are some images that I just generated in like 1 or 2 minutes using Nano Banana, and I didn't need to go to the website to do this. I literally just told Claude code, as you guys can see here, I said, "Make a site that looks super sexy by putting four different images that we generate on the site that are super sleek, clean, whatever." And then it went and started making those images using Nano Banana, and then it added them directly to the site. And the way that I did these is I actually used something called chase on prompting. So, you can see that it actually specified all of the different kind of characteristics or properties that it wanted for these images in this structured format which gives you a significantly better image result than if you just tell it like make a perfume bottle, right? For example, you can see that we have the type, the name, the description, right? Midground environment, all of this kind of stuff. So, we can be super super detailed and this is something that you would probably never write manually yourself, but that Claude can generate super quickly. But anyways, I just wanted to show you a realistic use case of why this is actually well useful and why you should add it to Claude. Okay, so the first thing we're going to do here to get set up is we're going to go to Google AI Studio and we're just going to make a new API key. Now, if you don't already have an account with Google AI Studio, all you're going to do is just go to this website. I'll leave a link to it in the description. You can just type Google AI Studio. From there, it's going to bring you into the playground. Now, from here, if it's your first time, all you're going to do is just accept the terms and then what we're going to do is go over to get API key. Now, you're going to notice that four API key here, we don't have anything. Again, you're going to go to the bottom left to get to this page. Now, what we're going to do is just simply press on create API key. We can put this in our default project and just name name this Gemini API key or in our case, we could change it to maybe Claude API key because that's where we're going to be using. So, I'm going to press on create key. Let's give this a second here and it should make one for us. Okay, so we can see it's made a key for us. We can go ahead and copy that and obviously don't share that with anyone else. Now, after that, what we're going to need to do is set up billing. The reason we need to set up billing is that because we're going to be using Nano Banana from the API, we are going to need some API credits. So, we're going to have to at least have some kind of billing so they can charge us. Don't worry, it is pretty inexpensive to use this and I believe you will get some free credits when you start using this with Google, but just be aware that this is, you know, a paid service generally and you're not able to do advanced image generation completely for free. So, I'm going to go to set up billing. So, from billing setup, we're just going to go through all of the prompts here. We're going to connect a credit card and an address and then we'll be good to go. All right, so we can see from here that we've now activated the paid tier. Gives us some information here. We're going to go ahead and press on done and then we're good to go. Now, just to make sure you don't accidentally spend too much money, especially because you're going to be giving this API key to a, you know, terminal writer or to an AI agent, what we're going to do is go to spend. We're going to go to our project, let me just change over to this, and we're just going to set the spending cap. Now, for the spending cap, I'm just going to change this to be $10 just because I don't want to spend more money than that. I highly recommend that you set this up to ensure that you don't actually go over whatever it is that you do want to spend. Then at any point in time, you can go and check your usage here and you should be able to see the spend, the limits, the cost, all of that kind of stuff. So, from here, once we have the API key, again, just make sure you copy it, then we're good to move on to the next step. All right, so we've got our API key here and the next step is to download some skills and install them in Cloud Code so that we can use However, before we do that, I want to give a quick thank you to today's sponsor, who is Skywork. And they just shipped their massive 3.0 update. It's absolutely worth your attention if you're already spending real money on AI like subscriptions and tokens. Now, a lot of you guys know Open Claw, but let's be real, wrestling with local setups and complex cloud configurations is a massive headache. Now, Skywork 3.0 completely removes that. It's the ultimate zero config Open Claw interface built into a unified cloud workspace. You get a dedicated cloud VM ready out of the box where you don't need to set anything up and you drive your entire 24/7 cloud workforce from a browser or straight from WhatsApp or Telegram. The second piece here is Skywork's skills. Now, these aren't basic plugins, they're enterprise-grade productivity skills that are built right in. They handle documents, slides, images, sheets, websites, and even multi-track video. But the magic is that you don't need to use them in isolation, you can actually stack them together. So, for example, I gave this AI one prompt, "Plan a tech influencer marketing campaign for the new M5 MacBook Pro launch in Japan. Now, it used the document skill to pull top Japanese tech creators with audience demographics, then it used the sheet skill to build a budget matrix with projected ROI, and then the slide skill to design a fully formatted 15-page localized pitch deck. Now, that was all in one run while I literally did nothing. Now, next, instead of being locked into one model, you can assign the best model for each task. So, GPT 5.4 and now 5.5 Pro for heavy coding, Claude Opus 4.6 for deep analysis, text, and research, Gemini 3.1 Pro for image and video generation like we're using here, or let Skywork autonomously route the best models for each task. Now, if your monthly software bills have crept past a few hundred a month, you're replacing separate subscriptions for design, data analysis, and website building, and easily saving $500 to $1,000 per year. So, stop doing the heavy lifting yourself and let your Cloud Team do it for you. The link's in the description. Hit the link to try Skywork for free and plug in code TIM2026 for 20% off. Now, let's continue with Nano Banana Pro. So, like I was saying, what we need to do here is add some skills to Claude. Now, the first skill that we're going to add is actually the Nano Banana JSON Prompter. Now, this is one that I just found from the MCP market. You can actually make your own, but when I read through this one, it looked fine and it was working well for me. But, if we read through this skill, you can see that effectively what this does is describe that Claude should use this whenever it's going to create marketing images, UI mock-ups, infographics, etc., and when not to use this skill for something like this. It then goes through and shows all of the key things that we can use for generating these different types of images, and then explains how we can translate them into JSON. So, if we scroll down, you can see that there's a bunch of different values that we can use inside of the JSON schema like framing, lightning, you know, lighting, surface materials, etc., and it gives some examples of the JSON on that can be used to generate these types of images. Now, it's not perfect and you could definitely create a much better skill than this, but it's just something to start with and what I wanted to show you. The basic idea here is that we're going to get a much better response when we use a JSON schema for generating the images rather than doing it ourselves. So, we want to have some kind of skill built into Claude code that can take a normal prompt like have a girl sitting on a chair, you know, drinking a beer, whatever, and convert it into JSON so that we can be a lot more specific with our images. So, this is one of the skills that will do that, but again, you can create your own, you could write your own JSON schema, you could just give an example and tell Claude to adjust it, but you want something to make this a little bit faster. Now, fortunately, with this particular tool, you can actually install these skills just by using this NPM command. So, I'm just going to copy this right here. I'm going to go into my terminal. And of course, this assumes that you have Claude code installed on your machine already, which means you'll have Node.js, and just paste this command. So, it's MPX skillfish add and then it's this guy's username {slash} Claude code nano banana skills. Okay? So, we're going to go ahead and press enter. When we do that, it's going to find the skill. It's going to run through here. We can choose where we want to install it. So, I'm going to go global so it's always available. Do you want to install it to all of the detected agents? I'm going to go yes because I have all of these on my computer. And then I'm going to go yes and install the skill. Now, you can see that I already have it installed, so it just skipped it, but this should install it in all of your different agents. You also could just pick one that you want to add it to. So, now if we open up Claude, so let's go here, we should be able to view our different skills. So, let's make this a little bit larger. So, we should see now that we have this JSON prompting for nano banana. So, now if we reference that skill and then we ask it to do something, it should be able to create that. So, actually, I'll just close the terminal and instead, I'm just going to go into my Claude code desktop application because I typically prefer to use this. And from here, what we can do is we can just go {slash} and same thing, we can use the skill. So, JSON prompting for nano banana. And then we can ask it to do something just to test that this is working. So, So, just going to tell it the following. Based on everything you know about me, generate an image of me, TechWithTim, sitting at a laptop drinking a Coca-Cola and working on an AI agent using Claude. I've no idea what this is going to give me, but let's see if it will give us the result, and then I'm just going to tell it, "Give me the JSON result. I want to have a look and see what you created." Okay, and let's press enter. And by the way, if you're wondering what I'm using to dictate here, I'm using a tool called WhisperFlow. It's super cool. You can see that I have a ton of words. I'm absolutely a power user here, and it gives you really precise AI transcriptions extremely quickly, does automatic formatting, punctuation, capitalization, etc., and generally just allows you to have much better prompts than if you were going to type them manually because you can do it so much faster. Anyways, I'll leave a link to it in the description because I do have a long-term partnership with them, but I've been using it much before I, you know, worked with them because it's just such a good tool. Anyways, you can see here that now it's giving me the JSON, and this is exactly what we were looking for. We're just giving us all of these details that we want to include in the final image. So, this is kind of the first skill. I'm not going to wait for this to finish. The next skill that we need to add allows us to actually call NanoBanana by using this skill first. So, the basic idea is we generate the JSON, then once the JSON is done, we pass that to NanoBanana, then it generates the images, and then from there we can stack that and combine that with any other skills that we want. So, we can do it all directly from our terminal. So, now what we can do is we can go to this website that I'll leave a link to in the description. We can press this button for download skill. It's going to give you a zip folder. What you can do is just open up the zip folder, and you can copy all of these files and just give it to Claude. So, you just paste all of these files into the Claude code terminal, or you can do it in, you know, however you want, but essentially just give it to Claude, and then just say something like, "Create a new skill for generating images with NanoBanana using these different files. Don't make any changes. Just wrap this in a skill and make sure it's available globally." So, all we're doing is just taking the files. I've already created them. I can verify that they work and we just give it over to Claude and it should make the new skill for us. Okay, so we can see that everything is working here. Now, I already have it installed so it's just saying, "Hey, I already have all of these files." But, for you it should create the new skill. And then it says to start using it we need to run this install command to install all of the dependencies and then we need to export our Gemini API key. So, what I'm going to do is just tell it to run this command. So, I'm going to say, "Run this command." Okay, and then the next step is going to be to go and get our Gemini API key, then to export the API key so it's available and we can actually use it to generate the images. Okay, so we can see that the install command was successful. Now, the next thing we're going to need to do is generate or export, sorry, the Gemini API key. Now, to get the key, same thing, go back to your AI studio from Google, go to API keys, press on it, and then simply copy it. Now, again, don't share this with anyone else because if you do then they will be able to use the key and cost you money. Now, if you want you can actually just manually write this command, right? So, export Gemini API key equals and then the key. However, if you're really lazy like me, you can just paste the API key so you can say, you know, API key like this. Okay, and then you can say something like, "Here's my API key. Just export it and run the command for me." Now, I definitely cannot recommend doing this because you're going to have your API key available in the chat history and you're going to be giving this over to Anthropic who could technically use it however they want. However, if you are super lazy, you don't care, and you're going to delete the key later, then I would just do this because it's a lot easier. So, effectively what you need to do is just get the API key saved in your kind of system path. Again, you can run this command to do it or you can simply just paste it in the terminal and say, "Hey, here's my API key, you know, go ahead and run this command for me." It will save it and then you'll be able to start utilizing it. Now, in my case, my API key is already saved. That's one you didn't already see here that I didn't leak in this video so I'm just going to leave it as it is. But, for you, you just need the API key available, then you're good to go. And again, if you're having trouble, just ask Claude code and it should be able to figure it out for you as long as you know what the actual key is. Okay, so now we have the JSON generator, we should have the Nano Banana Pro skill. And by the way, what this does is it just uses the Python API, I'll show you right here, to generate different images. So you can see that there's actually documentation where you can just use Python and you can generate an image with, uh, you know, Gemini 3.1 or Gemini 3.1 Pro or whatever, right? You can do multi-turn image editing. You can pass a reference image and then have it be updated. There's a bunch of different stuff that you can do here, and this script that I have in this skill is kind of just a minimal version of this API that allows you to have a reference image, generate different resolutions, sizes, you know, uh, what do you call it, aspect ratios, all of that kind of stuff. So for now, let's start by asking it to generate an image. I would like you to generate an image for me using the new skills that we created and added as well as the JSON, uh, you know, prompting for Nano Banana Pro. I would like this image to be a 9 by 16 image that I could post on Instagram. I want it to be, again, a photo of me similar to before where I'm kind of standing up, full body shot, holding a Sprite, and in my other hand I have a Mac Mini that has an open claw logo on it. Again, I don't know if that's actually going to make any sense, but I'm just giving it some random stuff to see what it can generate. Let's hit enter and let's see what we get. Okay, and there we go, that is the image that we get. Now, look, it's not great, but at least the Sprite logo is pretty good. I mean, the person looks pretty realistic. I know you still kind of get a little bit of the AI vibe, but that is like somewhat my build. Obviously doesn't look exactly like me, but, you know, it did get a lot of things right. So that's just the first thing, right? That was a really simple prompt, but we can do a lot more. Okay, so to go a step further, I'm actually just going to upload this thumbnail that I used for a previous video, which was also generated with AI, and I'm just going to ask it to change something. So maybe like let's swap the Claude logo for a chat GPT logo or something, right? So, if I do that, I might say something like swap the Claude logo for a chat GPT logo in this image. Again, use the Nano Banana Pro skill. Okay? And go ahead and press enter and we should be able to use this reference image as well, which is something I built into the skill. Now, the way that I built this skill is that it actually needs a reference to the file in order to pass that as an input field for the Python script that it's running. So, I just told it it's called uh thumbnail one.png from downloads. I'm going to stop this and now it's just going to execute this one because it was looking for the image, it couldn't find the original source. So, you need to have the image downloaded and then it should be good to go. Okay, and there we go. We can see we get the swapped image. I mean, that's actually pretty good that it was just able to do that. I guess it's just overlaying it on top, but still I mean pretty impressive and again, you can use the reference image as well. Now, look, there is a million other things you can do here, right? And this is really just the base and getting it set up. So, now you can extend it and add it to other skills. But I think with that said, this is a good place to leave it. So, this is super powerful. I hope you guys found some value from this. If you did, make sure you leave a like, subscribe to the channel, and I will see you in the next one. >> [music]

Original Description

Huge thanks to Skywork for sponsoring a portion of this video! 🚀 You can actually use the same image generation models we covered today - ChatGPT Image 2.0 and Nano Banana 2 - directly inside Skywork to automate your visual workflows. 👉 Use my code tim2026 Get up to 20% OFF your Skywork subscription here: https://skywork.ai/p/Wv69mE 🎁 Special Bonus: Sign up for the Annual Plan and get a FREE Skywork Note AI voice recorder. You've probably heard of the state of the art image generation models like Nano Banana Pro and Nano Banana 2. Now, these are extremely good models and you can create some really interesting images with them. However, they're a little bit inconvenient to use. So in this video, I'm going to show you how we can combine Nano Banana with Claude Code. Want to make real money with coding? I share high-signal insights on careers, monetization, and leverage in my free newsletter. Join here and get my guide How to Make Money With Coding instantly: https://techwithtim.net/newsletter 🚀 Tools I Use Get 10% off with code techwithtim Openclaw setup: https://www.hostinger.com/techwithtim VPS setup: https://www.hostinger.com/techwithtim10 Wispr Flow (Best AI Dictation): https://ref.wisprflow.ai/techwithtim 🎞 Video Resources 🎞 JSON Skill: https://mcpmarket.com/tools/skills/nano-banana-json-prompter Gemini API Docs: https://ai.google.dev/gemini-api/docs/image-generation Google AI Studio: https://aistudio.google.com/u/1/api-keys Nano Banana Skill Download: https://marble-quartz-tamc.here.now/ ⏳ Timestamps ⏳ 00:00 | Overview 01:03 | Demo/Usage 02:30 | Gemini/Nano Banana Setup 04:36 | Skywork Insert 06:53 | JSON Prompting 11:01 | Adding Claude Skills 14:17 | Generating Images Hashtags #ClaudeCode #NanoBanana #Anthropic UAE Media License Number: 3635141
Watch on YouTube ↗ (saves to browser)
Sign in to unlock AI tutor explanation · ⚡30

Related Reads

📰
Building a Custom GPT / Chatbot for Your Own Use Case
Learn to build a custom GPT/chatbot for your specific use case using Python
Medium · Python
📰
Building a Custom GPT / Chatbot for Your Own Use Case
Learn to build a custom GPT/chatbot for your specific use case and understand the process of creating a tailored conversational AI model
Medium · RAG
📰
Open-Weight LLM API Integration: A Developer Guide to Building with Transparent AI
Learn to integrate open-weight LLM APIs for transparent AI, enabling fine-grained control and inspecting the architecture behind the intelligence
Dev.to AI
📰
Stop Writing Boilerplate: How I Automated My Entire Workflow with LLM APIs
Automate your LLM workflow using APIs to reduce repetitive code, increasing productivity and efficiency
Dev.to AI

Chapters (7)

| Overview
1:03 | Demo/Usage
2:30 | Gemini/Nano Banana Setup
4:36 | Skywork Insert
6:53 | JSON Prompting
11:01 | Adding Claude Skills
14:17 | Generating Images
Up next
5 Levels of AI Agents - From Simple LLM Calls to Multi-Agent Systems
Dave Ebbelaar (LLM Eng)
Watch →