# Gemini format

`POST /v1/engines/{model}/embeddings`

Creates embeddings with the given engine/model

## Authorizations

Bearer authentication — send `Authorization: Bearer <token>`.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `model` | path | string | yes | Model/engine ID |

## Request Body (application/json)

```json
{
  "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 vector dimensions"
    }
  }
}
```

## Responses

### 200 — Embeddings created

```json
{
  "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"
        }
      }
    }
  }
}
```
