Browse docs
--- title: "OpenAI SDK Integration" description: "Use the OpenAI Python and Node.js SDKs with Aurora as a drop-in replacement." icon: "openai" ---
OpenAI SDK Integration
Aurora supports both OpenAI-format and Anthropic-format APIs. Point any OpenAI SDK at Aurora by changing the base URL — no code changes needed.
Python SDK
python
from openai import OpenAI
client = OpenAI(
base_url="http://your-aurora-host/v1",
api_key="sk-aurora-key"
)
response = client.chat.completions.create(
model="gpt-4o-mini",
messages=[{"role": "user", "content": "Hello"}]
)
print(response.choices[0].message.content)Node.js SDK
javascript
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'http://your-aurora-host/v1',
apiKey: 'sk-aurora-key'
});
const response = await client.chat.completions.create({
model: 'gpt-4o-mini',
messages: [{ role: 'user', content: 'Hello' }]
});
console.log(response.choices[0].message.content);What Works
Aurora supports all standard OpenAI API endpoints:
- Chat Completions (
/v1/chat/completions) - Text Completions (
/v1/completions) - Embeddings (
/v1/embeddings) - Models (
/v1/models) - Streaming (SSE)
- Tool/function calling
- Responses API
See OpenAI-Compatible Apps for detailed setup instructions.