{
"contents": [
{
"parts": [
{
"text": "A kawaii-style sticker of a happy red panda wearing a tiny bamboo hat. It'smunching on a green bamboo leaf. The design features bold, clean outlines,simple cel-shading, and a vibrant color palette. The background must be white."
}
]
}
],
"generationConfig": {
"imageConfig": {
"aspectRatio": "16:9",
"image_size": "1K"
}
}
}curl --location -g --request POST 'http://api.example.com/v1beta/models/gemini-3-pro-image-preview:generateContent' \
--header 'x-goog-api-key: sk-xxx' \
--header 'Content-Type: application/json' \
--data-raw '{
"contents": [
{
"parts": [
{
"text": "A kawaii-style sticker of a happy red panda wearing a tiny bamboo hat. It'\''smunching on a green bamboo leaf. The design features bold, clean outlines,simple cel-shading, and a vibrant color palette. The background must be white."
}
]
}
],
"generationConfig": {
"imageConfig": {
"aspectRatio": "16:9",
"image_size": "1K"
}
}
}'{
"candidates": [
{
"content": {
"parts": [
{
"inlineData": {
"mimeType": "image/jpeg",
"data": "{base64_data}"
}
}
],
"role": "model"
},
"finishReason": "STOP",
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 54,
"candidatesTokenCount": 1230,
"totalTokenCount": 1456,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 54
}
],
"candidatesTokensDetails": [
{
"modality": "IMAGE",
"tokenCount": 1120
}
],
"thoughtsTokenCount": 172
},
"modelVersion": "gemini-3-pro-image-preview",
"responseId": "EfEqaf-7E4uwjMcPq4qk-AY"
}