Google Banana / Gemini Image / Gemini 2.5 Flash Lite / Image to text (vision)
google_banana/gemini-2.5-flash-lite/image_to_text
Sync
Async
Analyse an input image and return text — or strict JSON via response_format/response_schema. Symmetric to text_to_image. Multimodal model; priced like text generation.
Parameters
| Name | Type | Required | Description | Allowed values | Bundle dim. |
|---|---|---|---|---|---|
| image | — | no | Input image: a data-URI/URL string, or an object { type, media_type, data } / { type, url }. Formats: jpeg/png/webp. | — | — |
| images | array | no | Multiple input images (analysed together). | — | — |
| prompt | string | no | Instruction / question about the image. | — | — |
| messages | object[] | no | Optional chat history (alternative to `prompt`). Content arrays may carry { type:"image_url", image_url:{ url } } parts. | — | — |
| temperature | number | no | — | — | — |
| callback_url | string | no | Webhook URL invoked when async task completes. | — | — |
| response_format | object | no | OpenAI-style structured output: { "type":"json_schema", "schema":{…} } (or { "type":"json_object" }). Translated to Gemini responseSchema. Equivalent to setting response_schema directly. | — | — |
| response_schema | object | no | JSON Schema the response must conform to (implies application/json). Native Gemini form; alternative to response_format. | — | — |
| max_output_tokens | integer | no | — | — | — |
| response_mime_type | string | no | Force JSON output when set to application/json. | text/plain, application/json | — |
| system_instruction | string | no | System-level guidance prepended to the prompt. | — | — |
Example request
{
"provider": "google_banana",
"model": "gemini-2.5-flash-lite",
"method": "image_to_text",
"params": {
"image": {
"data": "<BASE64>",
"type": "base64",
"media_type": "image/jpeg"
},
"prompt": "Определи блюдо и ингредиенты на фото, оцени вес, калории и БЖУ.",
"response_format": {
"type": "json_schema",
"schema": {
"type": "object",
"required": [
"dish",
"kcal",
"protein",
"fat",
"carbs"
],
"properties": {
"fat": {
"type": "number"
},
"dish": {
"type": "string"
},
"kcal": {
"type": "number"
},
"carbs": {
"type": "number"
},
"protein": {
"type": "number"
}
}
}
}
}
}Example response
{
"status": "queued",
"task_id": "tsk_01H..."
}