Build with Seedream 5.0 Flash Layer Decomposition
Make your first request
Use your Sorceress API key on your server. The playground uses your signed-in account; your application uses the same model with an API key.
curl -X POST 'https://sorceress.games/api/v1/jobs' \
-H 'Authorization: Bearer $SORCERESS_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"model": "seedream-5-flash-layer-decomposition",
"input": {
"size": "auto",
"output_format": "jpeg",
"image_url": "<image_url>"
}
}'Inputs & settings
sizestringResolution level of the output image. The base image maintains the aspect ratio of the input image, and each separated layer maintains the aspect ratio of the corresponding element in the original image. `auto`: Automatically selected based on the input image size `1K`: 1K resolution level `1.5K`: 1.5K resolution level `2K`: 2K resolution level
Options: auto, 1K, 1.5K, 2K
promptstringOptional prompt for layer separation. When a prompt is provided, the model separates the specified elements based on the prompt When no prompt is provided, the model automatically identifies the main elements in the image Supports using `<bbox>x1 y1 x2 y2</bbox>` to precisely specify element positions, recommending the use of normalized coordinates in the 0-1000 range Length: 4–5000 characters
image_urlstringRequiredThe source image URL for layer separation. Supported formats: PNG, JPEG. Image size must not exceed 30 MB Total pixel range is 262,144-36,000,000 Aspect ratio range is 1:16-16:1
output_formatstringOutput format of the base image. This parameter only controls the base image format; all separated layers are fixed to output as PNG.
Options: png, jpeg
Full input schema
{
"type": "object",
"required": [
"image_url"
],
"properties": {
"size": {
"enum": [
"auto",
"1K",
"1.5K",
"2K"
],
"type": "string",
"title": "Size",
"default": "auto",
"description": "Resolution level of the output image. The base image maintains the aspect ratio of the input image, and each separated layer maintains the aspect ratio of the corresponding element in the original image. `auto`: Automatically selected based on the input image size `1K`: 1K resolution level `1.5K`: 1.5K resolution level `2K`: 2K resolution level"
},
"prompt": {
"type": "string",
"title": "Prompt",
"maxLength": 5000,
"minLength": 4,
"description": "Optional prompt for layer separation. When a prompt is provided, the model separates the specified elements based on the prompt When no prompt is provided, the model automatically identifies the main elements in the image Supports using `<bbox>x1 y1 x2 y2</bbox>` to precisely specify element positions, recommending the use of normalized coordinates in the 0-1000 range Length: 4–5000 characters"
},
"image_url": {
"type": "string",
"title": "Image URL",
"format": "uri",
"x-media": "image",
"description": "The source image URL for layer separation. Supported formats: PNG, JPEG. Image size must not exceed 30 MB Total pixel range is 262,144-36,000,000 Aspect ratio range is 1:16-16:1"
},
"output_format": {
"enum": [
"png",
"jpeg"
],
"type": "string",
"title": "Output format",
"default": "jpeg",
"description": "Output format of the base image. This parameter only controls the base image format; all separated layers are fixed to output as PNG."
}
}
}Results, saved runs & billing
Media requests return a job ID. Poll GET /api/v1/jobs/:id until it succeeds or fails; keep the same ID while it is processing. Long chat requests can also return a saved job to poll. Completed outputs are stored in your account, and successful work is billed using your model's current rates.
A multi-step workflow may include separately billed successful actions. If a connection drops, check your saved run before submitting it again.






