Gemini Embedding 2 Preview

Gemini 多模态嵌入 (文本/图/音频/视频)

Model ID: gemini-embedding-2-preview · Type: embedding · Provider: Google

Endpoints: /v1/embeddings

Pricing

Input (per 1M tokens)$0.15 USD

Capabilities

from openai import OpenAI

client = OpenAI(api_key="sk-...", base_url="https://api.router.ai/v1")
resp = client.embeddings.create(model="gemini-embedding-2-preview", input="hello world")
print(len(resp.data[0].embedding))

FAQ

How much does Gemini Embedding 2 Preview cost on openbat.ai?

Gemini Embedding 2 Preview (`gemini-embedding-2-preview`) is billed per usage at $0.20 / 1M tokens in · None / 1M tokens out, in USD. Current pricing is always listed at https://openbat.ai/models/gemini-embedding-2-preview.

How do I call Gemini Embedding 2 Preview through openbat.ai?

Send a request to https://api.router.ai/v1/v1/embeddings with the header `Authorization: Bearer <your API key>` and `"model": "gemini-embedding-2-preview"`. The API is OpenAI-compatible, so any OpenAI SDK works by changing base_url to https://api.router.ai/v1 — no other code change.

What is Gemini Embedding 2 Preview's context window?

Gemini Embedding 2 Preview accepts up to 8,192 input tokens and can return up to 8,192 output tokens. Requests exceeding the input limit are rejected before reaching the model.

What can Gemini Embedding 2 Preview do?

Gemini Embedding 2 Preview supports: multimodal.

Who makes Gemini Embedding 2 Preview?

Gemini Embedding 2 Preview is a embedding model from Google, available through the openbat.ai gateway with the same API key as every other model.

Call it through the openbat.ai OpenAI-compatible endpoint (API base: https://api.router.ai/v1). AI agents can discover and call every model on this gateway through MCP (https://mcp.router.ai/mcp) with no manual integration.

Which should you pick

API reference · All models