Fashion try-on
curl --request POST \
--url https://modelslab.com/api/v6/image_editing/fashion \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"init_image": "<string>",
"cloth_image": "<string>",
"prompt": "<string>",
"negative_prompt": "<string>",
"temp": "no",
"guidance_scale": 10,
"webhook": "<string>",
"track_id": 123
}
'{
"status": "success",
"generationTime": 123,
"id": 123,
"output": [
"<string>"
],
"proxy_links": [
"<string>"
],
"meta": {}
}Image Editing API
Fashion
This endpoint allows you to wear a cloth image sample on an existing model body
POST
/
image_editing
/
fashion
Fashion try-on
curl --request POST \
--url https://modelslab.com/api/v6/image_editing/fashion \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"init_image": "<string>",
"cloth_image": "<string>",
"prompt": "<string>",
"negative_prompt": "<string>",
"temp": "no",
"guidance_scale": 10,
"webhook": "<string>",
"track_id": 123
}
'{
"status": "success",
"generationTime": 123,
"id": 123,
"output": [
"<string>"
],
"proxy_links": [
"<string>"
],
"meta": {}
}Fashion

Request
Make aPOST request to below endpoint and pass the required parameters as a request body to the endpoint.
curl
--request POST 'https://modelslab.com/api/v6/image_editing/fashion' \
Body
json
{
"key": "your_api_key",
"prompt": ":A realistic photo of a model wearing a beautiful t-shirt",
"negative_prompt": "Low quality, unrealistic, bad cloth, warped cloth",
"init_image": "https://pub-3626123a908346a7a8be8d9295f44e26.r2.dev/livewire-tmp/5dzoZ9qWI2FQxwceFDb3zULRtwCRmF-metaZjA5NjMyX3BhcmVudF8xXzE2NTMwMDMzODguanBn-.jpg",
"cloth_image": "https://pub-3626123a908346a7a8be8d9295f44e26.r2.dev/livewire-tmp/5BDmwvtizESFRO24uGDW1iu1u5TXhB-metaM2JmZmFkY2U5NDNkOGU3MDJhZDE0YTk2OTY2NjQ0NjYuanBn-.jpg",
"cloth_type": "upper_body",
"guidance_scale": 7.5,
"num_inference_steps": 21,
"seed": null,
"temp": "no",
"webhook": null,
"track_id": null
}
Body
application/json
Your API Key used for request authorization
The URL of the image of the model to try the dress on
The URL of the cloth/dress to try on
Type of garment
Available options:
upper_body, lower_body, dresses The text prompt describing the things you want in the image
Items you do not want in the image
The number of denoising steps
Available options:
21, 31, 41 Set to yes for proxy links
Available options:
yes, no The scale for classifier-free guidance
Required range:
1 <= x <= 20URL to receive POST API call when complete
ID for webhook identification
Response
200 - application/json
Fashion try-on response
- Option 1
- Option 2
- Option 3
Available options:
success Time taken to generate the image in seconds
Unique identifier for the generation request
Array of generated image URLs
Array of proxy image URLs
Metadata about the generation process
Was this page helpful?
⌘I

