API quickstart & endpoints
Endpoints cover generation, retrieval, account, models and image tools. All responses are JSON.
| Method | Path | Description |
|---|---|---|
POST | /v1/images/generations | Generate one or more images |
POST | /v1/images/tools/{tool} | Edit an image: remove background, upscale, expand or erase |
GET | /v1/jobs/{id} | Retrieve a past generation |
GET | /v1/account | Plan, credit balance and limits |
GET | /v1/models | List available models and tools |
Generate an image
curl https://multigen.fdmultimedia.workers.dev/v1/images/generations \
-H "X-API-Key: $MULTIGEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"prompt": "a matte black ceramic mug on a marble counter, soft daylight",
"n": 1,
"size": "2K"
}'
Response:
{
"id": "job_9f83c2a1",
"status": "succeeded",
"model": "multigen-image-1",
"credits_used": 5,
"credits_remaining": 937,
"images": [ { "url": "https://…/output.png" } ]
}
Parameters
| Field | Default | Notes |
|---|---|---|
prompt | — | Required, up to 4000 chars |
n | 1 | 1–4 images |
size | 2K | 2K or 4K (4K bills 2×) |
image_urls | [] | Up to 6 public https reference URLs |
Note
Image URLs are signed and expire after 1 hour — download and store the bytes if you need them longer.