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

# Gemini embeddings

> Create embeddings with the specified engine/model



## OpenAPI

````yaml /fr/api-reference/openapi.json post /v1/engines/{model}/embeddings
openapi: 3.0.1
info:
  title: Rock API API de modèles IA
  version: 1.0.0
  description: Référence de l’API de modèles IA compatible OpenAI pour Rock API.
servers:
  - url: https://rockapi.ai
security:
  - BearerAuth: []
tags:
  - name: List models
  - name: OpenAI format (Chat)
  - name: OpenAI format (Responses)
  - name: Image generation
  - name: Image generation/OpenAI-compatible format
  - name: Image generation/Qwen
  - name: Video generation
  - name: Video generation/Sora-compatible format
  - name: Video generation/Kling format
  - name: Video generation/Jimeng format
  - name: Claude format (Messages)
  - name: Gemini format
  - name: OpenAI format (Embeddings)
  - name: Text completions
  - name: OpenAI audio
  - name: Rerank
  - name: Moderations
  - name: Realtime
  - name: Not implemented
  - name: Not implemented/Fine-tunes
  - name: Not implemented/Files
paths:
  /v1/engines/{model}/embeddings:
    post:
      tags:
        - Gemini format
      summary: Gemini embeddings
      description: Create embeddings with the specified engine/model
      operationId: createEngineEmbedding
      parameters:
        - name: model
          in: path
          description: Model/engine ID
          required: true
          example: ''
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EmbeddingRequest'
            examples: {}
      responses:
        '200':
          description: Embeddings created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EmbeddingResponse'
          headers: {}
      deprecated: false
      security:
        - BearerAuth: []
components:
  schemas:
    EmbeddingRequest:
      type: object
      required:
        - model
        - input
      properties:
        model:
          type: string
          example: text-embedding-ada-002
        input:
          oneOf:
            - type: string
            - type: array
              items:
                type: string
          description: Text to embed
        encoding_format:
          type: string
          enum:
            - float
            - base64
          default: float
        dimensions:
          type: integer
          description: Output embedding dimensions
    EmbeddingResponse:
      type: object
      properties:
        object:
          type: string
          example: list
        data:
          type: array
          items:
            type: object
            properties:
              object:
                type: string
                example: embedding
              index:
                type: integer
              embedding:
                type: array
                items:
                  type: number
        model:
          type: string
        usage:
          type: object
          properties:
            prompt_tokens:
              type: integer
            total_tokens:
              type: integer
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: |
        Authenticate with a Bearer Token.
        Format: `Authorization: Bearer sk-xxxxxx`

````