SnapEditDocs
API HomeGet API Key
API Reference

Generate image with Z-Image

z-image-turbo

Text-to-image generation using Z-Image.

post/v1/images/generates/zimage

Credit cost: 9

Authorization β€” This endpoint requires an API key. Pass it in the api-key header on every request. See the quickstart

Body

NameTypeStatusDescription
prompt
stringRequiredText prompt describing the image to generate.
aspect_ratio
stringOptionalOutput aspect ratio.
1:13:22:34:33:416:99:16
(default: 1:1)

Responses

Image generated successfullySingleImageResponse

NameTypeDescription
createdintegerUnix timestamp of when the response was created
dataobject[]
urlstringURL to download the result image
curl -X POST "https://api.snapapi.ai/v1/images/generates/zimage" \
  -H "api-key: YOUR_API_KEY" \
  -F "prompt=value" \
  -F "aspect_ratio=1:1"
Response
{
  "created": 1745827200,
  "data": [
    {
      "url": "https://outputs.snapapi.ai/outputs/abc123.png"
    }
  ]
}

Examples

(1 example)

Prompt

β€œYoung Chinese woman in red Hanfu, intricate embroidery. Impeccable makeup, red floral forehead pattern. Elaborate high bun, golden phoenix headdress, red flowers, beads. Holds round folding fan with lady, trees, bird. Neon lightning-bolt lamp, bright yellow glow, above extended left palm. Soft-lit outdoor night background, silhouetted tiered pagoda, blurred colorful distant lights.”

Output

Output