Image Generation
Generate images using FLUX models through the Meridian API. The endpoint is fully compatible with the OpenAI image generation schema, so you can drop it into existing applications without changing your code. Billing is per-image at the rates listed below, charged from your account balance.
Pricing
| Model | Size | USD | User tokens |
|---|---|---|---|
| flux1-pro | 1024x1024 | $0.04 | 50,000 |
| flux1-pro | 1792x1024 | $0.08 | 100,000 |
| flux2-pro | 1024x1024 | $0.06 | 75,000 |
| flux2-pro | 1792x1024 | $0.12 | 150,000 |
curl example
curl https://meridian.getnimbus.net/api/v1/images/generations \
-H "Authorization: Bearer nim_live_..." \
-H "Content-Type: application/json" \
-d '{
"model": "flux1-pro",
"prompt": "A serene mountain lake at sunset, digital art",
"n": 1,
"size": "1024x1024",
"response_format": "url"
}'Python SDK example
from openai import OpenAI
client = OpenAI(
api_key="nim_live_...",
base_url="https://meridian.getnimbus.net/api/v1",
)
response = client.images.generate(
model="flux2-pro",
prompt="A cyberpunk street scene at night, neon lights",
n=2,
size="1792x1024",
)
for img in response.data:
print(img.url)TypeScript SDK example
import OpenAI from "openai";
const client = new OpenAI({
apiKey: "nim_live_...",
baseURL: "https://meridian.getnimbus.net/api/v1",
});
const response = await client.images.generate({
model: "flux1-pro",
prompt: "An astronaut riding a horse on Mars, photorealistic",
n: 1,
size: "1024x1024",
});
for (const img of response.data) {
console.log(img.url);
}