Quick Answer

  • Supports prompt-based image generation with multiple aspect ratios.
  • Supports reference_images for stronger style consistency.
  • Official variants expose richer generation controls for production tuning.

Key Parameters

  • model | string | required | gemini-3.1-flash-image-preview-vip | - | Exact image model identifier from ToAPIs.
  • prompt | string | required | - | - | Primary image instruction prompt.
  • size | string | optional | 1:1 | 1:1 | 16:9 | 9:16 | 4:3 | 3:4 | 21:9 | Output aspect ratio.
  • resolution | string | optional | 1K | 1K | 2K | 4K(按模型能力) | Output resolution, varies by model variant.
  • reference_images | file[] | optional | - | max 14 | Reference image array for style/composition control.

Common Errors

  • 400 invalid_request_error: trigger=Missing or invalid request payload fields.; fix=Validate model/prompt/size/resolution fields.; retry=Retry only after fixing payload.
  • 401 authentication_error: trigger=Missing or invalid API key.; fix=Verify Authorization header and API key scope.; retry=Retry after auth fix.
  • 429 rate_limit_exceeded: trigger=Request rate, concurrency, or current quota hits upstream rate limiting.; fix=Apply exponential backoff first, then review request rate, concurrency, and quota usage.; retry=Use 1s/2s/4s backoff with jitter; if it persists, reduce submission pressure.

gemini-3.1-flash-image-preview-vip

gemini-3.1-flash-image-preview-vip is a Google Gemini image generation model supporting text-to-image and reference-guided image creation, aligned to ToAPIs docs.

Model Type:
Pricing: 6 credits /request
1

Describe your image

Reference images

Describe the image you want to generate.157 / 1200

Advanced options

Example params
2

Your generated result

Your image result appears here

Sign in to submit a generation task.

Generation takes some time. Please wait.You can leave this page. [ Task Logs ] lets you check the generated content directly.

Request preview

{
  "model": "gemini-3.1-flash-image-preview-vip",
  "prompt": "Create a premium product advertising image with gemini-3.1-flash-image-preview-vip: clear subject, natural lighting, polished social-media-ready composition.",
  "size": "1:1",
  "n": 1,
  "metadata": {
    "resolution": "1K",
    "orientation": "square"
  }
}

Transparent pricing

gemini-3.1-flash-image-preview-vip pricing

Image usage is billed according to the current request and resolution rules. Final billing follows the current account quote.

Top up credits
6 credits /request

Why ToAPIs

Why call gemini-3.1-flash-image-preview-vip through ToAPIs?

Keep image generation, API keys, billing, and usage management in one workflow.

High-quality image generation

Generate high-fidelity images via a unified API.

Reference-guided consistency

Use reference_images to stabilize style and composition.

Production tuning controls

Tune resolution, aspect ratio, and sampling for quality/cost balance.

Connect in three steps

Create a key, send an image request, and review the generated result.

  1. 1

    Step 1

    Set Authorization: Bearer <YOUR_API_KEY>.

  2. 2

    Step 2

    Call image generation endpoint with model, prompt, and size.

  3. 3

    Step 3

    Optionally pass reference_images for stronger consistency.

When to use gemini-3.1-flash-image-preview-vip

Use case 1

When generating marketing/e-commerce/creative image assets at scale.

Use case 2

When using references to stabilize style and iterate prompts quickly.

FAQ

gemini-3.1-flash-image-preview-vip FAQ

How should I choose Gemini image variants?

Choose by resolution needs, official vs preview variant, and control parameters; prefer official for production.

Why are reference images not taking effect?

Check reference count/format/size limits and ensure prompt explicitly uses references.

Image or video model error: invalid apitype: -1

This usually means the request was sent to the wrong endpoint. Image and video models typically do not use the chat endpoint. Instead, submit the documented HTTP task request and poll the task status endpoint for results. Check the actual request code, URL, and payload first.

An image or video task failed, but the user was still charged

Ask the user for the task log or screenshot first and check whether input or output token usage appears. If token accounting shows up, the request was likely sent through a chat endpoint instead of the proper media workflow. Image and video models usually run as async HTTP task APIs: submit the task first, then poll by task id according to the relevant docs.

gemini-3.1-flash-image-preview-vip API

Start building with gemini-3.1-flash-image-preview-vip

Test an image request here, then continue in the dashboard or API documentation.

Try gemini-3.1-flash-image-preview-vip with one ToAPIs key.

Use one account and API surface for image generation workflows.

Sign up to get free credits