Ai Clothes Changer API guide
Ai Clothes Changer API: Create an image of a person wearing clothing from reference images. Send one portrait and one to eight garment references.
Model overview
Create an image of a person wearing clothing from reference images. Send one portrait and one to eight garment references.
API integration
| Documentation | Value |
|---|---|
| API invocation identifier | ai-clothes-changer |
| Integration | Async task API |
Use this invocation identifier in API requests. Check your authorized model catalog for access. Follow the Quickstart for your first complete call.
Request parameters
Studio presets describe the form setup, not guaranteed server defaults. Send preset values explicitly to reproduce them.
The URL of the input image.
Media types: image/*.
Provide 1 to 8 clothing reference images.
Item count: minimum 1; maximum 8.
No parameters match. Clear the search or reset the filters.
Model rules
Parameter meaning
- Use image for the person and clothes_images for the garment references. Include at least one clothing image and no more than eight.
Reference media
- Show the complete garment against an uncluttered background; laid-flat garments or mannequin photos make useful references.
Model behavior
- The edited image is a visual try-on preview; it does not establish the physical fit of a garment.
Integration notes
Use the following field formats and values in MuseSpark requests.
clothes_images: Use clothes_images, an array containing 1–8 clothing image URLs.
Request examples
Replace example media URLs and YOUR_... input identifiers with your own valid resources. Examples are checked against the exported item schema; media access and paid execution are separate runtime checks.
Set MUSESPARK_API_KEY and a stable MUSESPARK_REQUEST_ID before submitting. Preserve the request ID for retries of the same request and use a new ID for new work. Python examples use requests; JavaScript examples use Node.js 20 or later. The standalone Quickstart includes task polling and recovery.
Try on a jacket
curl --fail-with-body 'https://api.musespark.ai/api/v1/openapi/task' \
-H "Authorization: Bearer $MUSESPARK_API_KEY" \
-H "X-Idempotency-Key: $MUSESPARK_REQUEST_ID" \
-H 'Content-Type: application/json' \
-d '{
"item_key": "ai-clothes-changer",
"parameters": {
"image": "https://example.com/adult-standing-portrait.jpg",
"clothes_images": [
"https://example.com/jacket-front.png"
]
}
}'Parameters used: image · clothes_images.
Try a two-piece outfit
curl --fail-with-body 'https://api.musespark.ai/api/v1/openapi/task' \
-H "Authorization: Bearer $MUSESPARK_API_KEY" \
-H "X-Idempotency-Key: $MUSESPARK_REQUEST_ID" \
-H 'Content-Type: application/json' \
-d '{
"item_key": "ai-clothes-changer",
"parameters": {
"image": "https://example.com/adult-standing-portrait.jpg",
"clothes_images": [
"https://example.com/shirt-front.png",
"https://example.com/jacket-front.png"
]
}
}'Parameters used: image · clothes_images.
Output
The output is a portrait edited with the supplied clothing references.
Creation returns a task ID inside data. Poll that task until completion, then save data.result.output_urls and any data.result.batch_results. See the task lifecycle for terminal states, result retention, and errors.
Troubleshooting
The clothing list is empty or too long. Provide 1–8 image URLs in clothes_images.
The garment is poorly represented. Use full-garment reference images and a portrait with the body area clearly visible.
For rejected inputs, check the field type, accepted values, and conditional requirements in Request parameters and Model rules. Correct the affected fields before submitting again.
If creation times out, preserve the request identity and any known task ID. Follow Errors, timeouts and retries before submitting again.
Related docs
The public input snapshot was exported on 2026-11-09. Current prices and availability are listed in the model center.