Skip to main content
POST
Submit Nano Banana 2.1 Text to Image Task
  1. Submit the request with VIDGO_API_KEY. A task_id is returned. Keep it until the task reaches finished or failed.
  2. Use Query Task Status to retrieve the result. If you provide a callback_url, Vidgo sends the result to your webhook when the task finishes or fails.

Nano Banana 2.1 Text to Image

Usage Guide

Generate one image with Nano Banana 2.1 using a text prompt.
  • Set model to google/nano-banana-2.1/text-to-image.
  • Place model and optional callback_url at the request root; place workflow parameters inside input.
  • Each request produces one image.
  • For reference-image editing, use Image Edit with model=google/nano-banana-2.1/edit.

Parameter Details

  • prompt is required. Supply non-blank text of up to 20,000 characters.
  • size defaults to 1:1.

Developer Notes

  • Submission is asynchronous. Use the task status endpoint or a completion webhook to retrieve the final image.
  • Billing is per output image and depends on resolution. Text-to-image and editing use the same rate at each tier.
  • Credits are deducted on submission and refunded if the task fails.

Optional parameters

  • size (string): Output aspect ratio. Accepted values: 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:9. Default: 1:1.
  • resolution (string): Output resolution tier. Accepted values: 1K, 2K, 4K. Default: 1K.

Authorizations

Authorization
string
header
required

Use Authorization: Bearer VIDGO_API_KEY.

Body

application/json
model
string
required
Example:

"google/nano-banana-2.1/text-to-image"

input
object
required
callback_url
string<uri>

Optional webhook URL for completion or failure notifications.

Example:

"https://your-domain.com/callback"

Response

Task submission result. A task ID identifies asynchronous work; generation may still be running.

code
integer
required
Example:

200

data
object
required