Embeddings

code
POST /api/v1/embeddings

Generate vector embeddings for text. Compatible with the OpenAI Embeddings API.

Request body

FieldTypeRequiredDescription
modelstringYesEmbedding model ID
inputstringstring[]Yes

Example

bash
curl https://modelgates.ai/api/v1/embeddings \  -H "Authorization: Bearer sk-mg-YOUR_KEY" \  -H "Content-Type: application/json" \  -d '{    "model": "openai/text-embedding-3-small",    "input": "The quick brown fox"  }'

Pricing

Embedding costs are calculated only on input tokens (output price = 0). Prices include the standard 1.20× markup.