For Developers
OpenAI-compatible.
Infinite scale.
One URL change from your existing OpenAI image generation code. Access 50+ diffusion and video models with dramatically better unit economics.
API capabilities
REST endpoints, streaming, batch jobs, webhooks
generate.py
from sogni import SogniClient
client = SogniClient(api_key="sgn_...")
result = client.images.generate(
model="stable-diffusion-3-5",
prompt="a luminous forest at dusk, cinematic",
size="1024x1024",
n=4,
response_format="url"
)
for img in result.data:
print(img.url)generate.mjs
import Sogni from 'sogni-sdk';
const client = new Sogni({ apiKey: 'sgn_...' });
const result = await client.images.generate({
model: 'stable-diffusion-xl-1024',
prompt: 'neon city reflections on rain-wet pavement',
size: '1024x1024',
n: 2
});
console.log(result.data[0].url);terminal
$ curl -X POST https://api.sognix.com/v1/images/generations \
-H "Authorization: Bearer sgn_..." \
-H "Content-Type: application/json" \
-d '{
"model": "stable-diffusion-3-5",
"prompt": "ethereal landscape, golden hour",
"size": "1024x1024",
"n": 1
}'
{"data":[{"url":"https://cdn.sognix.com/out/..."}]}Compatibility
Works with your existing stack
If your app already calls POST /v1/images/generations, point it at api.sognix.com and you're done. We are not a new SDK to learn — we are a different backend for the same interface.
Python SDK
JavaScript SDK
Node.js
REST / HTTP
Get started
Get your API key in 2 minutes.
Free tier includes 100 credits/month — enough to run a few hundred 512×512 test generations. No credit card to start. Builder plan at $99/month covers 25,000 credits and 10 concurrent jobs for production workloads.