Image creation with Gemini

What are you trying to achieve?

I want to create an image based on a prompt and store it in Google Drive

Steps taken so far

I have created the workflow. It opens a Google sheet and gets the prompt. Then it creates an image. Make says that it is succesful. But then the Google Drive module says Missing value of required parameter ‘data’.
It has created some images so somehow it has worked. But now I get this error and I don’t know what went wrong, as it indicates that the Gemini Create Image module has run succesfully. I have made a similar scenario with OpenAI and that worked well.
I don’t know what to do now.

Screenshots: scenario setup, module configuration, errors


Hey Matthijs,

the error is showing that the image it self is not getting forwarded to the google drive module. Can you show the configuration of the module and what the incoming data looks like?

1 Like

Hi,

Do you mean the Gemini module. Here is a screenshot

The output of the module.

Dit is what I see when I click on the Gemini module.

@Stoyan_Vatov I now see what you mean. With OpenAI it gives this as output: Response Image DataBuffer, codepage: binary

89 50 4e 47 0d 0a 1a 0a 00 00

This is missing with Gemini.

The strange thing is that I have been able to generate some images, but it suddenly gave an error. This seem to be a bug at the side of Make.

{{toBinary(parts.inlineData.data; “base64”)}}

I have not used any programming language in Make.com.

Can you explain how I can use this to retrieve the image in a Make flow and store it in Google drive?

I use Gemini Completion for this, because it has no model limitations and it returns:

[
    {
        "parts": [
            {
                "inlineData": {
                    "mimeType": "image/png",
                    "data": "IMTString(1583820): long_string_here
                }
            }
        ]
    }
]

Then I use JSON module to specify the output interface, so I can use it further in the Google Drive Module.

Then in the Google Drive module I convert the result to binary:

{{toBinary(parts.inlineData.data; “base64”)}}


So the whole process looks like this