Skip to content

Other endpoints

Besides chat completions, the API exposes three more inference endpoints. All use the same authentication, the same model field semantics, and the same error model.

POST https://inference.inferel.ai/v1/completions

OpenAI-compatible legacy text completions (prompt in, text out). Useful for base models and code-completion workloads. Supports stream: true.

Terminal window
curl https://inference.inferel.ai/v1/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $INFEREL_API_KEY" \
-d '{
"model": "Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8",
"prompt": "def fibonacci(n):",
"max_tokens": 128
}'
POST https://inference.inferel.ai/v1/responses

OpenAI Responses API format, for clients built on the newer OpenAI interface:

Terminal window
curl https://inference.inferel.ai/v1/responses \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $INFEREL_API_KEY" \
-d '{
"model": "openai/gpt-5.4-mini",
"input": "Summarize the benefits of KV-cache-aware routing."
}'
POST https://inference.inferel.ai/v1/messages

Anthropic Messages API format. Point the Anthropic SDK’s base URL at Inferel and use your Inferel key (the x-api-key header is accepted):

import anthropic
client = anthropic.Anthropic(
base_url="https://inference.inferel.ai",
api_key="YOUR_INFEREL_API_KEY",
)
message = client.messages.create(
model="anthropic/claude-sonnet-4.6",
max_tokens=512,
messages=[{"role": "user", "content": "Hello, Inferel!"}],
)
print(message.content)

The API currently does not provide embeddings (/v1/embeddings), image generation, or audio endpoints. If you need these, contact support@inferel.ai.