API Reference
NexusAI is a drop-in replacement for the OpenAI API. Just change base_url.
Base URL: https://nexusai.proword.uk//v1
Auth: Authorization: Bearer nxs_live_YOUR_API_KEY
Endpoints
POST
/v1/chat/completions
Chat Completions
Generate text completions. Supports streaming via SSE.
{"model":"nexus/llama-3.3-70b","messages":[{"role":"user","content":"Hello!"}],"stream":false}
POST
/v1/completions
Completions (Legacy)
Legacy text completion endpoint.
{"model":"nexus/llama-3.3-70b","prompt":"Once upon a time","max_tokens":100}
POST
/v1/embeddings
Embeddings
Generate vector embeddings.
{"model":"nexus/llama-3.1-8b-groq","input":"The quick brown fox"}
POST
/v1/images/generations
Image Generation
Generate images using Runware or Together AI.
{"model":"nexus/flux-schnell","prompt":"A futuristic city at night","n":1}
GET
/v1/models
List Models
Get all available models on your plan.
GET
/v1/models/{id}
Get Model
Get details for a specific model.
GET
/v1/dashboard/usage
Usage
Get your usage statistics for last 30 days.
GET
/v1/dashboard/balance
Balance
Get your current wallet balance.
Quick Start
from openai import OpenAI
client = OpenAI(base_url="https://nexusai.proword.uk//v1", api_key="nxs_live_YOUR_KEY")
response = client.chat.completions.create(model="nexus/llama-3.3-70b", messages=[{"role":"user","content":"Hello!"}])
print(response.choices[0].message.content)
const OpenAI = require('openai');
const client = new OpenAI({baseURL:'https://nexusai.proword.uk//v1',apiKey:'nxs_live_YOUR_KEY'});
const res = await client.chat.completions.create({model:'nexus/llama-3.3-70b',messages:[{role:'user',content:'Hello!'}]});
console.log(res.choices[0].message.content);
$ch = curl_init('https://nexusai.proword.uk//v1/chat/completions');
curl_setopt_array($ch, [CURLOPT_RETURNTRANSFER=>true,CURLOPT_POST=>true,
CURLOPT_HTTPHEADER=>['Authorization: Bearer nxs_live_YOUR_KEY','Content-Type: application/json'],
CURLOPT_POSTFIELDS=>json_encode(['model'=>'nexus/llama-3.3-70b','messages'=>[...]])]);
echo curl_exec($ch);
curl https://nexusai.proword.uk//v1/chat/completions \
-H "Authorization: Bearer nxs_live_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"nexus/llama-3.3-70b","messages":[{"role":"user","content":"Hello!"}]}'