Upload Image
gemini_upload_imageUpload local images to Gemini Files API to obtain file URIs, enabling faster batch processing without base64 encoding.
Instructions
Upload one or more images to the Gemini Files API and return their file URIs.
Use this to pre-upload reference images before calling gemini_batch_submit. Uploaded files persist for 48 hours on Google's servers. Pass the returned URIs to batch_submit via the file_uris field to avoid slow base64 encoding.
Args:
image_paths (string, required): Comma-separated list of local file paths to upload. Example: "/path/to/ref1.jpg,/path/to/ref2.png"
Returns:
A list of file URIs (e.g. "files/abc123") mapped to each input path.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| image_paths | Yes | Comma-separated list of local file paths to upload |