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

> ## Agent Instructions
> Public hosts only: console https://omnimux.ai/dashboard · API https://api.omnimux.ai · docs https://docs.omnimux.ai.
> Gateway auth is Authorization: Bearer sk-… on https://api.omnimux.ai/v1 (OpenAI-compatible Chat Completions and related paths).
> Discover pages from /llms.txt; full site dump /llms-full.txt; product skill /skill.md; docs search MCP /mcp. Prefer .md page URLs for Markdown.
> Default docs locale is en; zh mirrors the same relative paths. Do not invent model ids not present on live pricing or the complete API pages.

# Gemini · Native Multimodal Understanding

> Submit text and media through the native content API and receive text or structured results.

* Put the model in the request path and use `contents` in the body; a body `model` is not required.
* Pass system instructions in `systemInstruction`. Treat media as input content, not higher-priority instructions.
* One user message can contain text, the complete video and multiple reference images; output is text or structured data.
* For streaming, see [Native Streaming Understanding](https://docs.omnimux.ai/en/api-reference/text-series/gemini/native-stream.md).

## Models

| Model ID |
| - |
| `gemini-4-argon` |
| `gemini-4-hydrogen` |
| `gemini-4-neon` |
| `gemini-4-carbon` |

## Media and results

Send PNG, MP4 or PDF through `parts[].inlineData`. Match `mimeType` to the actual file and encode the complete file in `data` without a data-URL prefix. Confirm unlisted formats, media sizes and long-media limits before integrating; request examples do not establish service limits.

Set `generationConfig.thinkingConfig.thinkingLevel` to choose thinking effort: `gemini-4-hydrogen` and `gemini-4-neon` support `low`, `medium`, `high`, and `xhigh`; `gemini-4-carbon` supports `low`, `medium`, and `high`; `gemini-4-argon` examples use `low`. `maxOutputTokens` covers both thinking and visible output; the example value does not establish a maximum output limit.

For structured results, combine `generationConfig.responseMimeType: application/json` with native `responseSchema`. These structured-output parameters are forwarded in the native request. The returned content may still contain code fences or field types that do not match the schema, such as an object where an array was requested. Validate the actual content and field types before processing it.

Inspect the complete response, `finishReason` and `usageMetadata`. A returned `functionCall` leaves execution to the client; this reference does not promise multi-turn tool execution.

## Billing and usage

Charges follow published account prices and actual usage. Automatic route changes do not alter the published price for this model. Input includes reported tool-use input, output includes reported thinking, and reported cached input is an input subset. Do not add these components twice or charge cumulative streaming snapshots as separate usage. An omitted usage field is not an explicit zero.

For insufficient balance, inspect the error body: native endpoints can return `403` with `insufficient_user_quota`, in addition to `402`. Do not treat every `403` as a permission failure.


## OpenAPI

````yaml openapi/ops/gemini/native.json POST /v1beta/models/{model}:generateContent
openapi: 3.1.0
info:
  title: Gemini · Native multimodal text
  version: 1.0.0
  description: >-
    Native Gemini content requests with system instructions, media input, text
    and structured output on OmniMux.
servers:
  - url: https://api.omnimux.ai
security:
  - BearerAuth: []
paths:
  /v1beta/models/{model}:generateContent:
    post:
      summary: Gemini native text generation
      description: >-
        Use native systemInstruction and contents.parts. Send text and media as
        separate parts of user content. Responses contain text, structured data
        or function-call requests.
      operationId: generateGeminiNativeText
      parameters:
        - name: model
          in: path
          required: true
          schema:
            type: string
            enum:
              - gemini-4-argon
              - gemini-4-hydrogen
              - gemini-4-neon
              - gemini-4-carbon
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NativeRequest'
      responses:
        '200':
          description: Native response; inspect finishReason and usageMetadata
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NativeResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/InsufficientQuota'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
        '502':
          $ref: '#/components/responses/UpstreamError'
        '503':
          $ref: '#/components/responses/Unavailable'
components:
  schemas:
    NativeRequest:
      type: object
      required:
        - contents
      properties:
        systemInstruction:
          type: object
          required:
            - parts
          properties:
            parts:
              type: array
              items:
                $ref: '#/components/schemas/TextPart'
          description: >-
            Task framework and scope; media content is data, not a
            higher-priority instruction
        contents:
          type: array
          minItems: 1
          items:
            $ref: '#/components/schemas/NativeContent'
        generationConfig:
          type: object
          properties:
            thinkingConfig:
              type: object
              properties:
                thinkingLevel:
                  type: string
                  enum:
                    - low
                    - medium
                    - high
                    - xhigh
                  description: >-
                    Thinking effort level: hydrogen and neon support
                    low/medium/high/xhigh; carbon supports low/medium/high;
                    argon reference documents low.
            maxOutputTokens:
              type: integer
              minimum: 1
              example: 2048
              description: >-
                Combined thinking and visible-output budget. This example value
                is not a model maximum.
            responseMimeType:
              type: string
              enum:
                - application/json
            responseSchema:
              type: object
              description: >-
                Native Schema object for structured text, used with
                responseMimeType=application/json.
        tools:
          type: array
          items:
            type: object
            properties:
              functionDeclarations:
                type: array
                items:
                  type: object
                  required:
                    - name
                    - parameters
                  properties:
                    name:
                      type: string
                    description:
                      type: string
                    parameters:
                      type: object
          description: >-
            Function declarations for a single-turn function-call response. The
            returned functionCall asks the client to execute the function; it
            does not run the function.
        toolConfig:
          type: object
          properties:
            functionCallingConfig:
              type: object
              properties:
                mode:
                  type: string
                  enum:
                    - ANY
                allowedFunctionNames:
                  type: array
                  items:
                    type: string
      example:
        systemInstruction:
          parts:
            - text: Respond concisely.
        contents:
          - role: user
            parts:
              - text: Hello.
        generationConfig:
          maxOutputTokens: 2048
    NativeResponse:
      type: object
      properties:
        modelVersion:
          type: string
          description: >-
            Supplier-reported model version; not independent backend identity
            proof
        responseId:
          type: string
        candidates:
          type: array
          items:
            type: object
            properties:
              index:
                type: integer
              finishReason:
                type: string
              content:
                type: object
                properties:
                  role:
                    type: string
                  parts:
                    type: array
                    items:
                      type: object
                      properties:
                        text:
                          type: string
                        thought:
                          type: boolean
                        functionCall:
                          type: object
                          properties:
                            name:
                              type: string
                            args:
                              type: object
        usageMetadata:
          $ref: '#/components/schemas/UsageMetadata'
    TextPart:
      type: object
      required:
        - text
      properties:
        text:
          type: string
    NativeContent:
      type: object
      required:
        - parts
      properties:
        role:
          type: string
          enum:
            - user
        parts:
          type: array
          minItems: 1
          items:
            oneOf:
              - $ref: '#/components/schemas/TextPart'
              - $ref: '#/components/schemas/InlinePart'
    UsageMetadata:
      type: object
      properties:
        promptTokenCount:
          type: integer
          minimum: 0
        toolUsePromptTokenCount:
          type: integer
          minimum: 0
          description: Additional reported tool-use input, counted in total input once
        candidatesTokenCount:
          type: integer
          minimum: 0
        thoughtsTokenCount:
          type: integer
          minimum: 0
          description: Reported thinking, counted in output once
        cachedContentTokenCount:
          type: integer
          minimum: 0
          description: Cached input subset, not additional input
        totalTokenCount:
          type: integer
          minimum: 0
        promptTokensDetails:
          type: array
          items:
            $ref: '#/components/schemas/ModalityUsage'
        toolUsePromptTokensDetails:
          type: array
          items:
            $ref: '#/components/schemas/ModalityUsage'
      description: >-
        Optional fields remain absent when not supplied; absent is not an
        explicit zero. Do not add modality breakdowns again or treat cumulative
        stream snapshots as separate charges.
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            message:
              type: string
            type:
              type: string
            code:
              oneOf:
                - type: string
                - type: integer
    InlinePart:
      type: object
      required:
        - inlineData
      properties:
        inlineData:
          type: object
          required:
            - mimeType
            - data
          properties:
            mimeType:
              type: string
              enum:
                - image/png
                - video/mp4
                - application/pdf
            data:
              type: string
              contentEncoding: base64
              description: >-
                Complete original media bytes encoded as base64, without a
                data-URL prefix
    ModalityUsage:
      type: object
      properties:
        modality:
          type: string
        tokenCount:
          type: integer
          minimum: 0
  responses:
    BadRequest:
      description: Invalid or unsupported request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Missing or invalid OmniMux API token
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    InsufficientQuota:
      description: Insufficient available quota
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: >-
        Request/model access is not allowed; this native surface may also return
        insufficient_user_quota as HTTP 403. Inspect the error code and message
        rather than assuming a permission problem.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Requested resource or model is unavailable
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimited:
      description: Rate limit reached
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    InternalError:
      description: Gateway error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    UpstreamError:
      description: Upstream error or incomplete upstream result
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unavailable:
      description: No available accepted route
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: OmniMux API token

````

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