aisplice

API reference

Images: direct

No model serves this yet

Nothing in the model catalogue supports this route right now. The page stays for reference.
POST/v1/images/generations

Synchronous image generation for models that serve this route, in one OpenAI-shaped body. The response carries final image URLs.

#Request parameters

  • modelstringrequired

    An image model that serves this synchronous route. Task-only models reject it — use /v1/images/tasks.

  • promptstringrequired

    What to draw.

  • nintegeroptional

    Number of images (billing multiplies per image).

  • sizestringoptional

    Aspect-ratio preset such as "16:9" — what most image models take; the model card lists the exact values. Some older models also accept WIDTHxHEIGHT.

  • resolutionstringoptional

    Output resolution tier such as "1K", "2K" or "4K", where the model card lists it — also a pricing-tier dimension.

  • qualitystringoptional

    Vendor quality level (e.g. standard / hd) — also a pricing-tier dimension.

  • response_formatstringoptional

    "url" (default) or "b64_json" for inline bytes.

Tiered pricing

size, quality and duration select the billed tier — the model card lists the exact price per tier, and failed calls refund automatically.

#Related errors

  • 422 unprocessable_entityThe vendor rejected parameter values the gateway forwarded (e.g. unsupported size or duration).
  • 401Invalid or missing bearer token. No error.code on this path — match the status.
  • 402 insufficient_user_quotaWallet balance cannot cover the pre-reserved estimate.
  • 429Per-key throttle. Empty body; wait for Retry-After. A 429 that does carry insufficient_user_quota is a daily spend cap instead.
  • 503 model_not_foundUnknown model, or no healthy channel serves it right now.

Full error-code table →

#Request example

curl https://www.aisplice.store/v1/images/generations \
  -H "Authorization: Bearer sk-YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "YOUR_SYNC_IMAGE_MODEL",
    "prompt": "A cyberpunk skyline at dusk, neon rain",
    "size": "1:1"
  }'

#Response

response.json
{
  "created": 1720000000,
  "data": [{"url": "https://…"}]
}

Still stuck?

Send us the request ID or the error message and we will look into it.