| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
model | string | ✅ Yes | doubao-seedream-4-5-251128 | - | The model identifier for image generation/editing |
prompt | string | ✅ Yes | - | - | Description of the desired image transformation or generation |
response_format | string | ❌ No | url | - | Response format: “url” (image URL) or “b64_json” (base64 encoded) |
size | string | ❌ No | adaptive | - | Output image resolution. Options: adaptive, 1024x1024, 2K, 4K |
seed | integer | ❌ No | - | - | Random seed for reproducible results |
guidance_scale | number | ❌ No | 5.5 | 1.0-10.0 | Controls adherence to the prompt. Recommended: 3.0-7.0 |
watermark | boolean | ❌ No | true | - | Whether to add watermark to the generated image |
| Error Code | Error Name | Description |
|---|---|---|
| 401 | Unauthorized | API key is missing or invalid |
| 403 | Forbidden | Your API key doesn’t have permission to access this resource, or insufficient balance for the requested operation |
| 429 | Too Many Requests | You’ve exceeded your rate limit |
| 500 | Internal server error | An internal server error occurred |
| 503 | Content policy violation | Content blocked due to safety concerns (actual status code is 400) |