Embeddings API
Return an embedding for a given text and, optionally, an image.Endpoint
Request Body (EmbedRequest)
| Field | Type | Required | Description |
|---|---|---|---|
text | String | Yes | The input text for generating embeddings. |
image_bytes | String | No | Optional. Base64-encoded image bytes. |
image_url | String | No | Optional. The URL of the image. |
Example Request
Response Body (EmbedResponse)
Returns a JSON object containing the generated embedding.
| Field | Type | Description |
|---|---|---|
embedding | Array | A list of floating point numbers representing the embedding vector. |
Example Response
Responses
200 OK: Successful Response (EmbedResponse)422 Validation Error: (HTTPValidationError)

