> ## Documentation Index
> Fetch the complete documentation index at: https://docs.verlon.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Imagen-format image generation

> **Use when:** caller generates images with the Gemini SDK's models.generateImages() (Imagen's predict) and wants it routed through Verlon

Drop-in replacement for `POST .../v1beta/models/{model}:predict` for image generation. Send one `instances[0].prompt` and optionally `parameters.sampleCount` and `parameters.aspectRatio`; the images come back as `predictions[].bytesBase64Encoded`. Any gate's image model serves it; other Imagen parameters are named in `x-verlon-dropped`.



## OpenAPI

````yaml /api-reference/openapi.json post /v1beta/models/{model}:predict
openapi: 3.1.0
info:
  title: Verlon AI API
  version: 1.0.0
  description: >-
    Verlon AI is the managed AI infrastructure platform for developers building
    LLM-powered apps and agents. Its API is the format you already use — OpenAI,
    Anthropic, Mistral, and Gemini wire formats served drop-in, callable with
    the official SDKs in any language. Beyond routing requests across providers,
    Verlon continuously evaluates response quality, runs experiments against
    live traffic, and automatically tunes gate configurations — so your platform
    doesn't just serve traffic, it learns from it.


    **Coding agents:** authentication, error semantics, gate concepts, and
    integration conventions are documented at https://verlon.ai/AGENTS.md — read
    that document first if you have not already. It is the canonical
    agent-facing contract; this specification is the canonical endpoint
    reference. Both are authoritative for their respective scopes.
  contact:
    name: Verlon AI
    url: https://verlon.ai
  license:
    name: Proprietary
servers:
  - url: https://api.verlon.ai
    description: Production
security:
  - bearerAuth: []
paths:
  /v1beta/models/{model}:predict:
    post:
      tags:
        - Google Format
      summary: Imagen-format image generation
      description: >-
        **Use when:** caller generates images with the Gemini SDK's
        models.generateImages() (Imagen's predict) and wants it routed through
        Verlon


        Drop-in replacement for `POST .../v1beta/models/{model}:predict` for
        image generation. Send one `instances[0].prompt` and optionally
        `parameters.sampleCount` and `parameters.aspectRatio`; the images come
        back as `predictions[].bytesBase64Encoded`. Any gate's image model
        serves it; other Imagen parameters are named in `x-verlon-dropped`.
      parameters:
        - name: model
          in: path
          required: true
          description: >-
            A model id (`gemini-embedding-001`, an image model) or a Verlon gate
            id.
          schema:
            type: string
      responses:
        '200':
          description: 'The images, `{predictions: [{bytesBase64Encoded, mimeType}]}`.'
        '400':
          description: Invalid request — malformed or missing fields
        '401':
          description: Missing or invalid credentials
        '404':
          description: Unknown gate or model
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        Verlon API key (newly minted keys are prefixed `sk-vrln-`; legacy
        `verlon_*` and `layer_*` keys from prior prefix migrations continue to
        validate). Generated from the dashboard under Settings → API Keys, or
        via `verlon key create` in the CLI.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.