Get started
Quickstart
Get started with Ultra AI in minutes
Get up and running with Ultra AI in just a few steps:
-
Sign up for an account at Ultra AI
-
Create provider keys in the “Provider keys” section
-
Obtain your Ultra AI API key from the dashboard settings inside the “API Key” tab
-
Configure your project with the Ultra AI base URL and API key
Usage Example
Here’s a quick example using JavaScript:
import OpenAI from "openai"
const openai = new OpenAI({
apiKey: "your-ultraai-api-key",
baseURL: "https://api.ultraai.app/v1",
})
const completion = await openai.chat.completions.create({
model: JSON.stringify({
models: ["openai:gpt-4o", "anthropic:claude-3-5-sonnet-20240620"],
cache: {
type: "similarity",
maxAge: 3600,
threshold: 0.8,
},
}),
messages: [{ role: "user", content: "Hello, how are you?" }],
user: JSON.stringify({
id: "user123",
maxRequests: 100,
duration: "hour",
}),
})
This example demonstrates how to use Ultra AI with model fallbacks, caching, and rate limiting.