In this lesson of the course, I will be showing you how to create this entire automation that produces
for you viral product ads.
So for an example, I provided this image of this product and I created product ad and different themes.
So we've got five different themes.
And the best part is actually the cost of generating each image is pretty low.
So it's $0.17 if you wish.
And you can pick the minimum quality.
It's $0.04.
And also you do one image within seconds.
And in general you can create endless product ads.
So for an example I will be sharing with you Google Sheets with specific themes you can pick.
So let's say you've got Minimalist Office Deck and you've got home spa, vintage cafe, yoga studio.
So you just simply change the status to create.
And then this automation generates for you this specific product and these specific themes, other ads
that, for example, I created were for this specific product.
So we've got luma skin facial oil and then we've got these specific themes.
So 30% of price.
We've got this specific product that's perfect.
This is actually luxury I don't know.
Um, car, um, environment.
Um, and this is, um, it was kind of the street, street photography, uh, theme.
So in general, remember, you can create, um, specific themes, the products and specific environment
and circumstances.
And also for this case, let me upload some specific product and I will show you how this automation
works.
So basically let me click on Execute Workflow.
And inside we need to provide our file and the tagline.
So the tagline can be let's say um I don't know, maybe 60% discount discount with big letters discount.
And let me provide the file so I can choose the file.
And I've got here some products.
So maybe let's take this, um, cream.
All right.
We've got this cream and I can click on submit.
So what my automation does it uploads an image to the external platform.
It takes the themes I specified here.
So first you will have the summer picnic and then these four themes.
Then it goes to a loop node.
So we loop over items.
So here we'll have five loops.
Yeah because we've got five um statuses to create.
And then it goes through ChatGPT image generation tool to create for us an image.
It converts that to the file it sends over to us this image to the telegram.
And then it repeats the process for, um, rest of the themes.
Um, so also it's pretty great.
I will be showing you actually in the resources of this material, you can copy this specific Google
sheet.
So if you open the link, you click on the file, you make a copy and then you can use it.
Also I will be showing you I will be sharing with you this template.
So you can just import this specific template to your knee then and just set up your credentials and
use it.
Also in general will have the specific instructions.
So again, I will be sharing them with you inside, inside the resources.
However, for now, just take a look what we have.
We've got Luma Skin 60% discount.
And the theme again was, um, Summer picnic.
That's awesome.
After approximately 40 to 50s, I guess, and we've got the next product out.
So 60% discount.
Um, and here this is the theme of Science Fiction Laboratory.
So that's perfect.
Like, the theme is exact as we want it.
And yeah, it generates for us and free rest themes.
And the next one will be tropical poolside.
We've got the flower shop and luxury hotel lobby.
So after a few minutes our automation created three missing images.
So we've got the next.
This is probably the pool theme.
Um, we've got here the flower shop.
And at the end what we have, I don't know, maybe some restaurant.
However, you know, it stopped after generating five themes because we specified here Five themes to
create.
Um, so now, with all that being said, let me show you how to create it from start to finish.
So let me make it a full screen.
All right.
So let's start.
The first thing we want to provide is our trigger.
And we specify on form submission.
Inside we've got the form description.
So please provide a photo of the product without packaging so that we can apply the selected motifs.
Um here the form title is um our image and we've got our elements.
The first one is data.
We specify the type.
This is the file okay.
And then we've got the name.
Um so here the tagline and this is a type text.
So in general we've got two um specific fields.
All right.
The first one is file we need to provide.
And the second one um, is our tagline we want to insert inside our product.
And the next thing what we want to do, we want to upload this image we provided in the form to some
external application to get the URL, and I'm using the cloudinary and other automations and discourse.
We've been using it.
So it's the platform that gives us a lot of free credits.
And there we can just upload our files inside this platform and get the URLs.
So for the URL you provide the specific URL inside the documentation.
You can see you've got this URL.
And it's very important here in this moment.
So let me show you um in this specific in this specific um part of this URL, you need to provide your
cloud name.
So if you go ahead to Cloudinary, you just log in.
You go ahead to the home page here, you should have your cloud name.
So just copy this specific information and just paste it here.
All right.
Paste it here okay.
In this specific part of the URL.
And you're done.
Um the method is post.
We send the body and we have two parameters.
So the body content type is from data.
And the first parameter is our binary file.
We want to send this specific file to cloudinary.
So the name is file and the field name is data.
Because we've got the name of the of the file.
And this is the data.
That's why we've got here the data.
The next parameter is our upload preset.
So now let me show you.
If you go ahead to Cloudinary you click in the left bottom corner on settings.
Um you then click on upload.
You need to create your preset at the right side of the page.
So add upload preset and then you just name it as an A, then automation or test whatever.
And you click on the mode which is unsigned.
You save it.
And then it was very important.
You, you just copy this name and you provide it here.
So just paste it here Okay.
You need to have this specific name.
Otherwise it doesn't work.
But if you do this, um, you should be able to execute this step and get the URL.
If you take it, you paste it in your new page.
You should get your image uploaded here.
And we are doing that because we want to actually then use it for further steps.
The next step inside our automation is our Google Sheets.
So inside what we do we pick the operation which is get rows.
We specify the document which is image IDs, and then we check for the status.
Okay.
We check for the status which is to create.
So it's perfect actually inside this file that you can copy from the resources of this material.
You've got 46 different themes.
And let's say you've got a product and you decide okay I want to have a theme theme which is Vintage
Cafe.
So you just simply change it to create and others you just turn into skip okay.
And then you've got Yoga Studio.
So you click to create.
So in general, you define how many designs and how many themes you would like to get and how many,
of course, product ads.
Okay.
It's the same.
Um, so yeah, however you choose that specific theme.
So with this step you search for the fields to create.
So in that case I had five items.
That's perfect.
And then right away um, we provide our loop over item.
So inside we've got the batch size which is one.
And then we just specify okay, just take these five different rows from here and just loop over these
items.
So just loop five times this entire automation.
Okay.
Um then we've got a step to get the image.
So we've got a method which is get URL which is this one.
So we specify we want to get the URL from upload image um variable.
Um so you can just copy and paste it from our documentation.
Let me show you.
Just copy and paste it from here.
Remember about changing the name of the field so of the of this HTTP request to upload image.
Otherwise you would need to either change the name of this of this node for this code to work, or just
change the name of the I don't know, maybe http request 1 or 2.
So then you know it works.
Um, so the method is get URL is this one.
And by this way you get the file inside your automation.
The next node inside this automation is our HTTP request to generate an image.
And we'll be using OpenAI GPT image one model.
So inside it looks like this.
The method is post.
We provide the specific URL.
So API Openai.com images edit.
And remember in the file you've got this URL to copy um here.
And we've got authentication which is predefined credential type which is OpenAI.
We connect our account in the send body.
We've got form data.
And here we'll have actually 4 or 5 parameters okay.
So the first one um type is firm data.
The first one parameter type is firm data.
We specify the name so the prompt.
And here in general we provide the following data JSON prompt.
Make sure product is centered.
Put in bold free text the below the product and we specify the theme.
So we give the theme from the Google Sheets.
Also the tagline from our form submission.
The next case.
Also I need to mention you.
You could have occurred like other form of, you know, like another videos of providing the data and
setting up HTTP request with GPT image generation model.
But also you can do this in this form.
So so actually the advantage of this solution is that sometimes if you have the text that is not in
JSON format, and it's better to use it because actually you can process with this step.
Otherwise let's say you've got the variable that produces some and some text that is not compatible
with JSON format.
You you will have an error.
Okay, so for this case I'm using this, um, this form of the HTTP request.
So I don't need to make sure.
Okay.
Everything is in the JSON format if that makes sense for you.
But we've got the first parameter.
The second parameter is form data.
Again we specify the model GPT image one.
Then we've got the size specific size.
You can specify it.
And then we've got our um file.
So we specify the name which is image and the field name which is data.
Because again the field name for this specific case is our data.
And at the end we have um the parameter which is quality which is optional.
And I provided it for you because remember for the high quality image you pay $0.17, $0.17.
But for the medium one you pay only $0.04.
So you can just change it to medium.
The default amount actually amount.
The default um setting is high quality, so pay in mind.
However, again, you can change it to medium and the quality will be worse.
Um, but it's four times cheaper, so it's for your choice.
Okay, after you've got this node to create image, you just turn the base64 JSON to the file.
So you use convert to file node.
All right.
Um, then you just set up your telegram.
So just connect your telegram account, provide your ID, enable the binary file and here provide the
data.
And afterwards you should get actually your image and send in your chat in telegram.
That's perfect.
And at the end we've got the if node because we need to have some condition in order to loop for the
specific amount of the times.
So I simply provided here Google Sheets variable.
So I check for the status.
And the status is equal to to create.
So it runs through um our all of the you know like themes and that we give and it checks if it's to
create.
And after the five items for this case, it stops and our automation is run successfully.
And then what I do I connect this if node with the loop.
So again it loops five times.
And it depends how many themes we we we have okay.
So that's pretty everything.
This is the automation.
It's not that hard.
Um yeah it's pretty simple.
Remember you can download the file um instructions and also uh, what else.
Um, the Google Sheets file and the resources of this material.
Thank you for watching this video.
Remember, if you would like, please leave us your honest review or rating of the course.
We appreciate it if you have already done it.
Thank you so, so much.
You help us a lot.
It means the world to us.
Um, so yeah, it's so, so great.
Thank you so, so much again.
I really appreciate it.
Me and Damien, uh, we are both very happy.
Um, again, thank you for watching this video.
I hope you enjoyed it.
I will see you in the next material.