Administrator Panel

OmniAI Backend Setup Guide

Complete step-by-step instructions for registering all 8 free API providers and configuring the secure rotating backend server.

8
Free Providers
20K+
Req / Day Free
₹0
Total Cost
~20m
Setup Time

📋 Admin Checklist

Setup Progress 0 / 12 tasks done
Sign up for Groq (highest free limit — do this first)
console.groq.com → Create API Key → paste into server.js
Sign up for Google Gemini
aistudio.google.com → Get API Key → paste into server.js
Sign up for Together AI
api.together.ai → Settings → API Keys
Sign up for OpenRouter
openrouter.ai → Keys → Create Key
Sign up for HuggingFace
huggingface.co → Settings → Access Tokens → New Token
Sign up for Cerebras
cerebras.ai → Developer → API Keys
Sign up for Cohere
cohere.com → Dashboard → API Keys → Trial Key
Sign up for Mistral AI
console.mistral.ai → API Keys → Create New Key
Paste all 8 keys into server.js PROVIDER_KEYS section
See "Server Configuration" section below for exact format
Run cd server && npm install
Installs express, cors, node-fetch, uuid
Start the server with node server.js
Should print "8 providers configured" in terminal
Open public/index.html and verify green "Server online" banner
All provider pills should turn green. Test a query.

🔑 Provider Registration — Step by Step

Groq
console.groq.com
✓ Free Forever 14,400 req/day
⭐ Start here. Groq is the fastest, most generous free provider. 14,400 requests/day — enough to power your app solo. Ultra-low latency responses.
1
Open Groq Console
Go to console.groq.com in your browser. Click Sign Up in the top right corner.
2
Create your account
Sign up with Google or email. No credit card required. Verify your email if prompted.
3
Navigate to API Keys
Once logged in, click API Keys in the left sidebar. Then click Create API Key button.
4
Name and copy your key
Name it omniai-server. Click Create. Copy the key immediately — it starts with gsk_ and is only shown once.
5
Paste into server.js
Open server/server.js. Find groq: '' inside PROVIDER_KEYS. Paste your key between the quotes.
🔑 Key format: gsk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🔷
Google Gemini
aistudio.google.com
✓ Free Forever 1,500 req/day
1
Open Google AI Studio
Go to aistudio.google.com. Sign in with your Google account.
2
Get API Key
Click Get API Key button (top left area or header). Then click Create API key in new project.
3
Copy and paste
Copy the generated key. Open server/server.js and paste it into gemini: '' inside PROVIDER_KEYS.
🔑 Key format: AIzaSy_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🤝
Together AI
api.together.ai
✓ Free Models ~1,000 req/day
1
Sign up at Together AI
Go to api.together.ai. Click Get Started. Sign up with Google or email.
2
Go to API Keys
After login, click your profile icon → SettingsAPI Keys. Click Create new key.
3
Copy and paste
Copy the key and paste it into together: '' in server.js PROVIDER_KEYS.
Note: Together AI uses Llama-3.3-70B-Instruct-Turbo-Free — a very capable free model with no credit card required.
🔑 Key format: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🛣️
OpenRouter
openrouter.ai
✓ Free Models ~200 req/day
1
Sign up at OpenRouter
Go to openrouter.ai. Click Sign InCreate account.
2
Create an API Key
Go to Keys section in the dashboard. Click Create Key. Name it omniai.
3
Set credit limit to $0
When creating the key, set the credit limit to $0 so it only uses free models — this prevents any accidental charges.
4
Copy and paste
Copy key and paste into openrouter: '' in server.js.
🔑 Key format: sk-or-v1-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🤗
HuggingFace
huggingface.co
✓ Free Inference ~500 req/day
1
Create HuggingFace account
Go to huggingface.co/join. Fill in username, email, password. Verify email.
2
Go to Access Tokens
Click your profile photo → SettingsAccess Tokens in the left menu.
3
Create new token
Click New token. Name it omniai. Select role: Read. Click Generate a token.
4
Copy and paste
Copy the token (starts with hf_). Paste into hf: '' in server.js.
🔑 Key format: hf_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🧠
Cerebras
cerebras.ai
✓ Free Tier ~1,000 req/day
1
Sign up at Cerebras
Go to cerebras.ai. Click Get Started or Developer. Create a free account.
2
Navigate to API Keys
In your dashboard, find API Keys section. Click Create new API key.
3
Copy and paste
Copy the key (starts with csk_). Paste into cerebras: '' in server.js.
🔑 Key format: csk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🌊
Cohere
cohere.com
✓ Trial Key 1,000 req/month
1
Sign up at Cohere
Go to cohere.com. Click Start for free. Register with email or Google.
2
Get Trial API Key
In your dashboard, click API Keys. You'll see a Trial key already generated. Copy it. No credit card needed.
3
Paste into server.js
Paste the key into cohere: '' in server.js PROVIDER_KEYS.
Note: Cohere trial keys work immediately with no credit card. The 1,000/month limit resets each month — good as a backup provider.
🔑 Key format: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
🌪️
Mistral AI
console.mistral.ai
✓ Free Credits ~500 req/day
1
Open Mistral Console
Go to console.mistral.ai. Click Sign up. Register with email.
2
Verify and log in
Check email for verification link. Click it, then log in to the console.
3
Create API Key
Go to API Keys in the left sidebar. Click Create new key. Name it omniai.
4
Copy and paste
Copy the key immediately — shown only once. Paste into mistral: '' in server.js.
🔑 Key format: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

⚙ Server Configuration

Open server/server.js and fill in the PROVIDER_KEYS object:

// server/server.js — PROVIDER_KEYS section const PROVIDER_KEYS = { gemini: 'AIzaSy_YOUR_GEMINI_KEY_HERE', groq: 'gsk_YOUR_GROQ_KEY_HERE', cerebras: 'csk_YOUR_CEREBRAS_KEY_HERE', openrouter: 'sk-or-v1-YOUR_OPENROUTER_KEY', cohere: 'YOUR_COHERE_KEY_HERE', mistral: 'YOUR_MISTRAL_KEY_HERE', hf: 'hf_YOUR_HUGGINGFACE_TOKEN', together: 'YOUR_TOGETHER_KEY_HERE', };

Then run: node server.js

Pass keys as environment variables — safer since keys aren't saved in code:

# Windows (Command Prompt) set GEMINI_KEY=AIzaSy_YOUR_KEY && set GROQ_KEY=gsk_YOUR_KEY && node server.js # Mac / Linux / Git Bash GEMINI_KEY=AIzaSy_YOUR_KEY \ GROQ_KEY=gsk_YOUR_KEY \ CEREBRAS_KEY=csk_YOUR_KEY \ OPENROUTER_KEY=sk-or-v1-YOUR_KEY \ COHERE_KEY=YOUR_KEY \ MISTRAL_KEY=YOUR_KEY \ HF_KEY=hf_YOUR_KEY \ TOGETHER_KEY=YOUR_KEY \ node server.js

Create a file called .env in the server/ folder:

GEMINI_KEY=AIzaSy_YOUR_GEMINI_KEY# from aistudio.google.com
GROQ_KEY=gsk_YOUR_GROQ_KEY# from console.groq.com
CEREBRAS_KEY=csk_YOUR_CEREBRAS_KEY# from cerebras.ai
OPENROUTER_KEY=sk-or-v1-YOUR_KEY# from openrouter.ai
COHERE_KEY=YOUR_COHERE_KEY# from cohere.com
MISTRAL_KEY=YOUR_MISTRAL_KEY# from console.mistral.ai
HF_KEY=hf_YOUR_TOKEN# from huggingface.co
TOGETHER_KEY=YOUR_TOGETHER_KEY# from api.together.ai

Install dotenv: npm install dotenv then add require('dotenv').config() at the top of server.js. Add .env to your .gitignore so keys never go to GitHub.

🎲 How Rotation Works

Every search request randomly shuffles the provider order. If one fails or is rate-limited, it automatically moves to the next — user never sees an error.

Request In
🎲 Shuffle
Try Groq
✓ Success → Return
Request In
🎲 Shuffle
Groq limit hit
Try Gemini
✓ Success
Request In
🎲 Shuffle
Groq + Gemini down
Try Cerebras
✓ Success

With 8 providers totalling 20,000+ free requests/day, the app stays online even if 6 providers are down simultaneously.