VoyageAI by MongoDB: voyage-code-4: AI model
- Context window:
- 32,000 tokens
- Input:
- $0.12/1M tokens
- Output:
- $0/1M tokens
- Type:
- embedding
- Embeddings
VoyageAI by MongoDB: voyage-code-4 is a AI model from Mongodb, available through Hormouz via an OpenAI-compatible API with stable access from inside Iran.
voyage-code-4 is a code embedding model from Voyage AI, a MongoDB company. It is designed for coding agents and code retrieval, with Matryoshka embeddings at 2048t voyage-code-4 here: mongodb.com/products/platform/ai-search-and-retrieval/models
Quickstart
curl https://api.hormouz.net/v1/embeddings \
-H "Authorization: Bearer ng-YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"mongodb/voyage-code-4","input":"The quick brown fox"}'Specs
| Vendor | Mongodb |
|---|---|
| Type | Embedding |
| Context window | 32,000 tokens |
| Pricing | $0.12/M in · $0.00/M out |
| API | embeddings |
Code example
cURL
curl https://api.hormouz.net/v1/embeddings \
-H "Authorization: Bearer ng-YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"mongodb/voyage-code-4","input":"The quick brown fox"}'Python
from openai import OpenAI client = OpenAI(api_key="ng-YOUR_API_KEY", base_url="https://api.hormouz.net/v1") resp = client.embeddings.create(model="mongodb/voyage-code-4", input="The quick brown fox") print(resp.data[0].embedding)
JavaScript
import OpenAI from "openai";
const client = new OpenAI({ apiKey: "ng-YOUR_API_KEY", baseURL: "https://api.hormouz.net/v1" });
const resp = await client.embeddings.create({
model: "mongodb/voyage-code-4",
input: "The quick brown fox",
});
console.log(resp.data[0].embedding);Buy the VoyageAI by MongoDB: voyage-code-4 API, paid in rial
- Buy credit with an Iranian bank card; no foreign card or account needed.
- One Hormouz key reaches VoyageAI by MongoDB: voyage-code-4 and nearly 700 other models, and you pay only for what you use.
- No VPN and no risk of a banned account; just change the base URL to api.hormouz.net/v1.
Use via Hormouz
Connect to this model and nearly 700 others with one API key, then see usage down to each request.
Request company accessUpdated 2026-11-27