Quickstart Guide
Get started with HiveOps in 5 minutes
Quickstart Guide
Get started with HiveOps in under 5 minutes. Run your first AI inference request using affordable, open-source models.
What is HiveOps?
HiveOps is an affordable AI inference API that provides access to powerful open-source language models like Llama 3, Gemma 3, and Mistral. We're fully compatible with OpenAI's API, so you can switch seamlessly with minimal code changes.
Why Choose HiveOps?
- š° Up to 90% cheaper than proprietary AI APIs
- š Open-source models - no censorship, full transparency
- š Drop-in replacement for OpenAI - works with existing SDKs
- ā” Fast inference with typical 1-3 second response times
Step 1: Create an Account
- Visit hiveops.io and click Sign Up
- Choose to sign up with:
- Google account
- GitHub account
- After signing up, you'll be taken to your HiveOps dashboard where you can manage API keys, view usage, and add funds.
- Bonus Credit: Receive 50% credit on your first deposit (up to $50) to get started!
Step 2: Generate an API Key
- Log in to your HiveOps dashboard
- Navigate to API Keys in the sidebar
- Click + New Key
- Give your key a descriptive name (e.g., "Development", "Production")
- Click Create
- ā ļø IMPORTANT: Copy your API key immediately - it will never be shown again!
# Your API key looks like this:
sk-...Etgg
Step 3: Make Your First Request
Python
Install the official OpenAI SDK (yes, it works with HiveOps!):
pip install openai
from openai import OpenAI
# Initialize the client with HiveOps endpoint
client = OpenAI(
api_key="sk-YOUR-HIVEOPS-API-KEY",
base_url="https://ai.hiveops.io"
)
# Make your first request
response = client.chat.completions.create(
model="llama3:8b-instruct-q8_0",
messages=[
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "What is the capital of France?"}
]
)
print(response.choices[0].message.content)
Output:
The capital of France is Paris.
JavaScript/TypeScript
Install the official OpenAI SDK:
npm install openai
# or
yarn add openai
import OpenAI from "openai";
// Initialize the client with HiveOps endpoint
const client = new OpenAI({
apiKey: "sk-YOUR-HIVEOPS-API-KEY",
baseURL: "https://ai.hiveops.io",
});
async function main() {
const response = await client.chat.completions.create({
model: "llama3:8b-instruct-q8_0",
messages: [
{ role: "system", content: "You are a helpful assistant." },
{ role: "user", content: "What is the capital of France?" },
],
});
console.log(response.choices[0].message.content);
}
main();
cURL
Test directly from your terminal:
curl https://ai.hiveops.io/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer sk-YOUR-HIVEOPS-API-KEY" \
-d '{
"model": "gemma3:4b",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'
Step 4: Try Streaming
Streaming allows you to receive responses incrementally, perfect for chat interfaces:
Python
response = client.chat.completions.create(
model="gpt-oss:120b",
messages=[
{"role": "user", "content": "Write a haiku about coding."}
],
stream=True
)
for chunk in response:
if chunk.choices[0].delta.content:
print(chunk.choices[0].delta.content, end="")
JavaScript
const stream = await client.chat.completions.create({
model: "deepseek-r1:8b",
messages: [{ role: "user", content: "Write a haiku about coding." }],
stream: true,
});
for await (const chunk of stream) {
process.stdout.write(chunk.choices[0]?.delta?.content || "");
}
Available Models
| Model | Context Window | Input Price | Output Price |
|---|---|---|---|
| llama3:8b-instruct-q8_0 | 8K tokens | $0.010/1M | $0.020/1M |
| llama-3-70b-instruct | 16K tokens | $0.100/1M | $0.200/1M |
| gemma-2-9b-it | 8K tokens | $0.005/1M | $0.010/1M |
| mistral-7b-instruct-v0.3 | 4K tokens | $0.001/1M | $0.002/1M |
š” Tip: Start with llama3:8b-instruct-q8_0 for general tasks or mistral-7b-instruct-v0.3 for the lowest cost.
Managing Your Balance
Check Balance
View your current balance in the dashboard.
Add Funds
- Go to Billing in your dashboard
- Click Add Funds
- Enter amount (minimum $10)
- Complete payment via Stripe
Low Balance Alert
ā ļø When your balance reaches $0, API requests will be blocked. We recommend:
- Setting up auto top-up (coming soon)
- Monitoring your usage regularly
- Setting up balance alerts
Next Steps
ā Quickstart Complete! Here's what to explore next:
- š API Reference - Complete endpoint documentation
- š Migration from OpenAI - Switch in minutes
- š¬ Build a Chatbot - Use case guide
- š§ Error Handling - Troubleshooting tips
- š Python SDK Guide - Advanced examples
Support
Need help? We're here for you:
- š¬ Discord
- LinkedIn: HiveOps
- X: @HiveOpsHQ
- š§ Email: [email protected]
- š Contact Form
Happy building! š