OpenAI Compatibility
Parel is designed as a drop-in replacement for OpenAI-compatible chat, image, audio, and embedding calls. In most applications, the migration is two values:
client = OpenAI( api_key=os.environ["OPENAI_API_KEY"], base_url="https://api.openai.com/v1", api_key=os.environ["PAREL_API_KEY"], base_url="https://api.parel.cloud/v1",)Compatible surfaces
Section titled “Compatible surfaces”| Use case | Endpoint |
|---|---|
| Chat and vision | POST /v1/chat/completions |
| Legacy completions / fill-in-the-middle | POST /v1/completions |
| Image generation | POST /v1/images/generations |
| Image editing | POST /v1/images/edits |
| Speech to text | POST /v1/audio/transcriptions |
| Text to speech | POST /v1/audio/speech |
| Embeddings | POST /v1/embeddings |
| Models | GET /v1/models |
Parel extensions
Section titled “Parel extensions”Parel also adds endpoints for model comparison, imported models, dedicated GPU deployments, usage, and billing. These are documented separately and use the same Authorization: Bearer header.
Response headers
Section titled “Response headers”Most paid API responses include useful telemetry:
| Header | Meaning |
|---|---|
X-Parel-Cost-USD | Request cost |
X-Parel-Budget-Remaining | Remaining account balance |
X-Parel-Latency-Ms | Gateway latency |
X-Parel-Provider | Selected upstream provider when available |