API reference

One endpoint creates every kind of generation. Base URL: https://generativeaiapi.com/api/public/v1

Create an API key

Authentication

Send your key as a bearer token on every request. Keys start with gai_live_ and are shown once at creation — store them in your server environment, never in browser code.

header
Authorization: Bearer gai_live_xxxxxxxx

Create a generation

Credits are deducted when the job starts and refunded automatically if it fails. Pass wait: true to block until the job finishes (up to two minutes) instead of polling.

request
POST /api/public/v1/generations
Authorization: Bearer gai_live_xxxxxxxx
Content-Type: application/json

{
  "model": "studio-image",
  "prompt": "an orbital greenhouse at golden hour",
  "options": { "aspect_ratio": "16:9" },
  "wait": false
}
201 response
{
  "id": "0f1b8b2e-...",
  "status": "processing",
  "model": "studio-image",
  "kind": "image",
  "prompt": "an orbital greenhouse at golden hour",
  "credits": 5,
  "outputs": [],
  "text": null,
  "error": null,
  "created_at": "2026-08-09T05:19:08.000Z",
  "completed_at": null
}
FieldTypeNotes
modelstringModel slug from the catalogue. Required.
promptstringRequired for image and video models.
imagestringhttps URL or base64 data URL for image input.
optionsobjectModel-specific options; unknown keys are ignored.
waitbooleanBlock until the job settles.
webhook_urlstringStored with the job for your own bookkeeping.

Retrieve a generation

Poll every couple of seconds until status is succeeded or failed. Output URLs are signed and valid for seven days.

GET /v1/generations/{id}
curl https://generativeaiapi.com/api/public/v1/generations/0f1b8b2e-... \
  -H "Authorization: Bearer gai_live_xxxxxxxx"

# once finished
{
  "status": "succeeded",
  "outputs": ["https://.../0.png"],
  "completed_at": "2026-08-09T05:19:31.000Z"
}

Video & image input

Video jobs take one to three minutes. Image-to-video models require the image field.

image-to-video
curl https://generativeaiapi.com/api/public/v1/generations \
  -H "Authorization: Bearer gai_live_xxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "animate-video",
    "prompt": "slow dolly in, drifting dust",
    "image": "https://example.com/still.jpg",
    "options": { "resolution": "480p" }
  }'

Image tagging

Tagging models return their result in text rather than outputs.

tagging
curl https://generativeaiapi.com/api/public/v1/generations \
  -H "Authorization: Bearer gai_live_xxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "image-tags",
    "image": "https://example.com/product.jpg",
    "wait": true
  }'

# -> { "status": "succeeded", "text": "studio photo, ceramic mug, ..." }
node
const res = await fetch("https://generativeaiapi.com/api/public/v1/generations", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.GENAI_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({ model: "turbo-image", prompt: "a brutalist library", wait: true }),
});

const job = await res.json();
console.log(job.outputs[0]);

Models endpoint

GET /v1/models returns the live catalogue with credit costs. No authentication required.

slugs
flash-image      image  1 credits
turbo-image      image  2 credits
studio-image     image  5 credits
edit-image       image  6 credits
pro-image        image  10 credits
max-image        image  16 credits
motion-video     video  45 credits
animate-video    video  22 credits
story-video      video  35 credits
image-tags       tag    1 credits
image-caption    tag    1 credits

Errors

400Invalid request — bad model slug, missing prompt or missing image.
401Missing, malformed or revoked API key.
402Insufficient credits. Top up and retry.
404Generation not found for this account.
500Unexpected platform error. Safe to retry.