/v1/embeddings on the application
URL, with the same key they use for chat. Google’s SDKs can keep their own
embeddings calls instead: see Gemini and Vertex AI shapes.
Which registries can serve it
Anthropic, Gemini AI Studio, and Bedrock’s chat models do not embed and are left
out of the candidate pool automatically.
How it routes
The application’s registries are narrowed to those that advertise embeddings, then routing runs on that pool as usual. Two edges:- Pinning a registry that cannot embed — with
@provider/model— is a400, not a silent failover. You asked for something impossible; the gateway says so. - No capable registry at all is a
503. Attach one.
Gemini and Vertex AI shapes
The Gemini and Vertex AI model paths that serve chat also take the embeddings actions Google’s SDKs send:curl
/v1/embeddings: any registry that can embed
serves them, not only Vertex AI, and the gateway translates in both directions.
- The response follows the action called.
:embedContentreturns{"embedding": …}.:batchEmbedContentsreturns{"embeddings": [...]}, even for a single request.:predictreturnspredictions[].embeddings.values. :predictis for embedding models only:gemini-embedding-*,text-embedding-*andtext-multilingual-embedding-*. Any other:predict, and:predicton/v1beta/models/…, is a404, as are:countTokens,:rawPredictand unknown actions.- One
contentis one vector. Its text parts are joined. A request with non-text parts or no text, or a batch that mixestaskTypeoroutputDimensionalityvalues, is a400in the Gemini error format. - Options are carried where the provider has them.
taskTypeandtitlereach Vertex AI, andtaskTypebecomes Cohere’sinput_type.outputDimensionalitybecomesdimensionson OpenAI and Azure OpenAI and is dropped for Mistral, OpenAI-compatible, Titan and Cohere.