Amux AI

Create image

Last updated November 25, 2026

Generate images synchronously with bytedance/seedream-5.5 via the native Volcengine Ark endpoint /api/v3/images/generations, supporting text-to-image, multi-image editing, native RGBA transparency, up to 99-layer decomposition, and rich-text OCR.

Generate images synchronously with bytedance/seedream-5.5. Requests and responses use the native Volcengine Ark format—official SDKs work directly once base_url points to the gateway. Text-to-image, multi-image editing, native RGBA transparent generation, and layer decomposition share this endpoint.

POSThttps://gateway.amux.ai/api/v3/images/generations

Authorization

header
AuthorizationstringRequired

Bearer <your Amux AI key> Amux AI API key.

Request

application/json
modelstringRequired

Platform model ID. Append :provider to pin a specific provider.

promptstring

Text prompt. Required for text-to-image and image-to-image; optional for layer decomposition (when omitted, subjects, text, and background are detected automatically). Supports <bbox>x1 y1 x2 y2</bbox> and <point>x y</point> tags (0–1000 integer coordinates) for localized editing.

imagestring | array<string>

Optional reference images. Omit for text-to-image; provide for image-to-image or multi-image blending. Pass a single string or an array of strings (up to 10 images, max 30 MB each).

Each entry must be a publicly reachable HTTPS URL or data:image/<format>;base64,… (lowercase format). Private network addresses or plain HTTP URLs return HTTP 400.

sizestring

Output dimensions. Standard generation accepts tiers 1K, 1.5K, or 2K (default 2K; 4K is not supported) or exact pixel strings WxH (921,600–4,624,220 total pixels, aspect ratio 1/16–16).

Layer decomposition accepts only 1K, 1.5K, 2K, or auto (default auto); exact pixel strings are not supported.

output_format"png" | "jpeg"Default "png"

Output image encoding, defaulting to png. Must be png when background: "transparent" is set; in layer decomposition mode, applies only to the base image while extracted layers are always png.

background"auto" | "transparent" | "opaque"Default "auto"

Background transparency mode: auto (default; determined from prompt context), transparent (natively generates RGBA transparent/semi-transparent PNGs for both text-to-image and 1–10 reference image edits; incompatible with output_format: jpeg), or opaque (forces a solid background). Cannot be passed when layer_decomposition: true.

watermarkbooleanDefault false

Whether to add an "AI generated" watermark in the bottom-right corner. Disabled (false) by default; pass true to enable.

layer_decompositionbooleanDefault false

Enable layer decomposition to split a single input image into 1 base image plus up to 99 extracted transparent layers. Requires exactly 1 image (PNG or JPEG, recommended ≥ 512×512); prompt is optional and background cannot be combined.

layer_decomposition_optionsobject

Layer decomposition options, effective only when layer_decomposition: true.

›layer_decomposition_optionsobject
max_imagesintegerDefault 30

Maximum total output images returned (including the base image and all layers), from 2 to 100 (default 30). Higher values produce finer-grained layer separation and determine the pre-authorization image count.

text_recognitionbooleanDefault false

Whether to enable rich-text OCR on regular text layers. When true, returns extracted text, line bounding boxes, and typography styles under data[].text_recognition.

optimize_prompt_optionsobject

Prompt optimization settings; defaults to standard when omitted.

›optimize_prompt_optionsobject
mode"standard" | "fast"Default "standard"

Prompt optimization mode: standard delivers higher composition and detail quality with slightly higher latency; fast reduces latency with lighter optimization. Both modes share the same unit price.

response_format"url" | "b64_json"Default "url"

Response delivery format. When set to b64_json, data[] items return Base64 strings without url; generated outputs remain accessible in console logs and Playground under both formats.

Response

200response

Image generation completed.

400response

Invalid parameters (e.g., layer decomposition without exactly 1 image, background or pixel size in decomposition mode, max_images outside 2–100, more than 10 reference images, transparent paired with jpeg, or unreachable image URL).

402response

Insufficient workspace balance to cover the pre-authorization hold.

502response

Generation failed; not charged and the pre-authorization hold is released.

Dimensions (size)

size accepts either of two mutually exclusive formats:

  • Resolution tier: 1K, 1.5K, or 2K (default 2K; 4K is not supported);
  • Exact pixels: WxH, with total pixel area between 921,600 and 4,624,220 and an aspect ratio between 1/16 and 16.

Layer decomposition accepts resolution tiers (1K, 1.5K, 2K) or auto (default auto) only; exact pixel strings are not supported.

Reference images and spatial anchors (image / prompt)

Pass reference images via image as a single string or an array of up to 10 strings (max 30 MB per image). Publicly reachable HTTPS URLs and data:image/<format>;base64,… (lowercase format name) are accepted. Omit image for text-to-image generation.

For image-to-image and multi-image editing, prompt supports spatial anchor tags using 0–1000 normalized integer coordinates:

  • Bounding-box anchor: <bbox>x1 y1 x2 y2</bbox> to designate a localized region for replacement, modification, or inpainting;
  • Point anchor: <point>x y</point> to pinpoint a target subject or placement focus.

Native transparent backgrounds (background)

seedream-5.5 natively generates RGBA transparent and translucent channels (such as glassware, sheer fabrics, glow stickers, and UI icons) across both text-to-image (0 reference images) and 1–10 reference image editing:

  • auto (default): automatically determines whether to generate a transparent background from prompt semantics;
  • transparent: forces an RGBA PNG with an alpha channel (automatically defaults output_format to png when omitted; cannot be combined with output_format: "jpeg");
  • opaque: forces a solid opaque background.

background cannot be combined with layer_decomposition: true.

Layer decomposition and rich-text OCR (layer_decomposition)

Set layer_decomposition: true to split a single input image into 1 base image plus up to 99 extracted transparent layers, with fine-grained control via layer_decomposition_options:

  • image must contain exactly 1 PNG or JPEG image (recommended resolution ≥ 512 × 512 pixels);
  • prompt is optional and specifies target elements to extract; when omitted, subjects, text, and background are detected automatically;
  • layer_decomposition_options.max_images caps total returned images (base image plus extracted layers), accepting integers from 2 to 100 (default 30);
  • Setting layer_decomposition_options.text_recognition to true (default false) populates data[].text_recognition on regular text layers with rich-text OCR output, including full plain text, per-line bounding boxes (lines[].bounding_box), and per-run visual style attributes (lines[].runs[].style: similar_font_family, foreground_color, bold, italic, underline, strikethrough, shadow, and translucent);
  • In response data, the base image has z_index: 0 (honoring output_format), while extracted layers increment from 1 and are always returned as transparent png files;
  • bounding_box.normalized uses integer coordinates from 0 to 1000; prefer pixel coordinates in bounding_box.absolute when re-compositing onto the base canvas.

Layer decomposition is designed for posters, e-commerce hero banners, illustrations, and layout designs with distinct foreground elements; overly complex inputs that cannot be decomposed return HTTP 400 without charge.

Additional parameters

ParameterDescription
watermarkBottom-right "AI generated" watermark. Disabled (false) by default; pass true to enable
output_formatOutput encoding: png (default) or jpeg
optimize_prompt_options.modePrompt optimization mode: standard (default, higher composition and detail quality) or fast (lower latency); both modes share the same unit price
response_formaturl (default) or b64_json (returns Base64 strings only, omitting url)

n, seed, and streaming output are not supported; standard generation requests output 1 image per call.

Latency

Synchronous requests return once all images are ready—typically 15–60 seconds for text-to-image and image-to-image, and 60–150 seconds for high-count layer decomposition with OCR. To avoid holding open long-lived HTTP connections, use Amux Tasks.

Billing

Billed per input reference image + per output image × resolution tier, not per token. Each output image's tier is determined by its actual pixel count: ≤ 2,601,123 pixels (~2.60 MP, covering 1K and 1.5K) falls into the lower tier, and above 2,601,123 pixels falls into the higher tier (2K). In layer decomposition mode, the base image and each extracted layer are tiered individually by their actual pixel counts; input reference images are billed per image.

Output billing follows usage.generated_images in the response; output_tokens and total_tokens are area-derived reference figures and are not billed. For unit prices, see the model page and pricing page.

An upper-bound hold is reserved upon acceptance (layer_decomposition_options.max_images or 30 images by default for layer decomposition) and settled on actual usage upon completion, releasing any unused difference. Failed requests are not charged.

Calling methods compared

MethodEndpointNotes
Volcengine Ark native (this page)POST /api/v3/images/generationsSynchronous; native Volcengine Ark response schema
OpenAI-compatiblePOST /v1/images/generationsSynchronous; OpenAI response schema with amux extension metadata
Amux TasksPOST /v1/tasksAsynchronous; returns task ID and supports webhooks

All three methods share the same routing, billing, and task persistence, and all model parameters above apply across all three.

Errors

Error responses follow the OpenAI error schema. See Errors and retries for type values and retry semantics.

cURL
curl https://gateway.amux.ai/api/v3/images/generations \
  -H "Authorization: Bearer $AMUX_API_KEY" \
  -d '{
    "model": "bytedance/seedream-5.5",
    "prompt": "设计一张电商促销横版海报,奶油色背景,精致化妆品瓶身,上方清晰艺术字标题 'SUMMER SALE'",
    "size": "2K",
    "output_format": "png",
    "watermark": false
  }'
{
  "model": "doubao-seedream-5-5-261028",
  "created": 1795593600,
  "data": [
    {
      "size": "2048x2048",
      "url": "https://cdn.amux.ai/gen/20261125/task_01M5CWPZEAJ6FRGPDM1G7G1V29-0.png",
      "output_format": "png"
    }
  ],
  "usage": {
    "generated_images": 1,
    "output_tokens": 16384,
    "total_tokens": 16384
  }
}