Generate images using Gemini model.
API Key
Array of conversation turns. Each turn has a role and parts. A part can be a text prompt, or an inline_data image (base64). To use a reference image, include both a text part and an inline_data part in the same parts array.
[
{
"role": "user",
"parts": [
{
"text": "Hi, this is a picture of me. Can you add a llama next to me?"
},
{
"inline_data": {
"mime_type": "image/jpeg",
"data": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg=="
}
}
]
}
]