Create Embedding
Create text embeddings.
Returns vector representations of the input text.
Authentication
AuthorizationBearer
Your production key sent as a bearer token.
Request
This endpoint expects an object.
model
Model ID in format ‘provider/model-name’
input
Text to embed
encoding_format
Encoding format for embeddings
dimensions
Number of dimensions for the output embeddings. Supported by OpenAI text-embedding-3 and later models and by Google gemini embedding models.
task_type
Google-only: the embedding task type (e.g. RETRIEVAL_QUERY, RETRIEVAL_DOCUMENT, SEMANTIC_SIMILARITY, CLASSIFICATION, CLUSTERING). Ignored for non-Google models.
user
End-user identifier
vendor
Pin the vendor that runs this request.
customer
Customer ID (UUID) to scope this request to, applying that customer’s routing policy, provider keys, budget, and usage attribution.
Response
Successful Response
data
model
usage
Token usage for embeddings.
vendor
Vendor that served the request.
object
Errors
422
Unprocessable Entity Error