> For the complete documentation index, see [llms.txt](https://docs.photoroom.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.photoroom.com/image-editing-api-plus-plan/virtual-try-on.md).

# Virtual Try-On

## Overview

Virtual Try-On lets you automatically place a piece of clothing on an a person:

<table data-header-hidden><thead><tr><th align="center" valign="middle"></th><th align="center" valign="middle"></th></tr></thead><tbody><tr><td align="center" valign="middle"><em>(original image)</em></td><td align="center" valign="middle"><em>(edited image)</em></td></tr><tr><td align="center" valign="middle"><img src="/files/IIl5XXj08CmCPE4YA9qO" alt=""><br><br>+<br><br><img src="/files/zF7DDeRb59NCd7RBvI9O" alt=""><br></td><td align="center" valign="middle"><img src="/files/xi6dMPNbljYMtIwMioYa" alt=""></td></tr><tr><td align="center" valign="middle"><img src="/files/PDDoTSjnTtR780b67GJx" alt=""><br><br>+<br><br><img src="/files/2wLTUlRhKz2VoflkkZM9" alt=""></td><td align="center" valign="middle"><img src="/files/nCIzEoFGNXcO5nR3O5Mv" alt=""></td></tr><tr><td align="center" valign="middle"><img src="/files/pIT4H0aNQLIlVSXGys6U" alt=""><br><br>+<br><br><img src="/files/V3kCq7S1U79bWJUHtS2L" alt=""></td><td align="center" valign="middle"><img src="/files/f2sJYDc25WpGrUaH8YRO" alt=""></td></tr></tbody></table>

{% hint style="info" %}
Virtual Try-On is meant to be used with images that feature clothing items.
{% endhint %}

## Main Parameters

Virtual Try-On shares the same parameters than [Virtual Model](/image-editing-api-plus-plan/virtual-model.md), but used in a different way.

To use Virtual Try-On, you'll need to use the following parameters:

### `virtualModel.mode`

To enable Virtual Try-On, set the parameter `virtualModel.mode` to `ai.auto`.

### `virtualModel.model`

The parameter `virtualModel.model` lets you control the likeness of the person wearing the clothing.

The image of that person is provided using either the parameter `virtualModel.model.custom.imageFile` or `virtualModel.model.custom.imageUrl`.

{% hint style="info" %}
The parameter `virtualModel.model.custom.imageFile` is only available when using the [POST endpoint](/image-editing-api-plus-plan/quickstart-guide.md#post-endpoint).
{% endhint %}

### `virtualModel.scene`

The parameter `virtualModel.scene` lets you control the environment in which the person will be placed.

You can either use a pre-set scene or a custom one.

{% hint style="warning" %}
To keep the scene generated around the virtual model, please also set the parameters `removeBackground=false` and `referenceBox=originalImage`.
{% endhint %}

To use a **pre-set scene**, set the parameter `virtualModel.scene.preset.name` to the name of the pre-set scene that you want to use.

<details>

<summary>List of pre-set scenes</summary>

<table data-card-size="large" data-view="cards"><thead><tr><th align="center"></th><th data-hidden data-card-cover data-type="image">Cover image</th></tr></thead><tbody><tr><td align="center"><code>random</code></td><td data-object-fit="contain"><a href="/files/0IahvwH1qAhBC7VK1DmK">/files/0IahvwH1qAhBC7VK1DmK</a></td></tr><tr><td align="center"><code>street</code></td><td data-object-fit="contain"><a href="/files/hqCfOdvjAbxiRGpQYQWR">/files/hqCfOdvjAbxiRGpQYQWR</a></td></tr><tr><td align="center"><code>bedroom</code></td><td data-object-fit="contain"><a href="/files/JuqlkH1Q44j6ejNektqZ">/files/JuqlkH1Q44j6ejNektqZ</a></td></tr><tr><td align="center"><code>sunset</code></td><td data-object-fit="contain"><a href="/files/YQyJXdUeWE5uMsPBVd3w">/files/YQyJXdUeWE5uMsPBVd3w</a></td></tr><tr><td align="center"><code>factory</code></td><td data-object-fit="contain"><a href="/files/O5Xhtq4bq6JIN2XmhNRb">/files/O5Xhtq4bq6JIN2XmhNRb</a></td></tr><tr><td align="center"><code>studio</code></td><td data-object-fit="contain"><a href="/files/46pbuQT1qatH5mFzK0KN">/files/46pbuQT1qatH5mFzK0KN</a></td></tr><tr><td align="center"><code>coloredstudio</code></td><td data-object-fit="contain"><a href="/files/xB188ouKVuWUedpoS6ix">/files/xB188ouKVuWUedpoS6ix</a></td></tr><tr><td align="center"><code>concretestudio</code></td><td data-object-fit="contain"><a href="/files/K9WgvXohswvMQxmCvI07">/files/K9WgvXohswvMQxmCvI07</a></td></tr><tr><td align="center"><code>beach</code></td><td data-object-fit="contain"><a href="/files/sO0N99T9AZiCj3LlaHCi">/files/sO0N99T9AZiCj3LlaHCi</a></td></tr><tr><td align="center"><code>tropical</code></td><td data-object-fit="contain"><a href="/files/SYh2uL2aUBjcIXBjtey0">/files/SYh2uL2aUBjcIXBjtey0</a></td></tr><tr><td align="center"><code>library</code></td><td data-object-fit="contain"><a href="/files/GiraV1vfH23kImqTPNyb">/files/GiraV1vfH23kImqTPNyb</a></td></tr><tr><td align="center"><code>forest</code></td><td data-object-fit="contain"><a href="/files/Cabudtg7qofeRxSJvqxb">/files/Cabudtg7qofeRxSJvqxb</a></td></tr><tr><td align="center"><code>businessdistrict</code></td><td data-object-fit="contain"><a href="/files/1whyFWttZIX1PgjBgPuM">/files/1whyFWttZIX1PgjBgPuM</a></td></tr><tr><td align="center"><code>countryside</code></td><td data-object-fit="contain"><a href="/files/k0JYUfdQhHWFIZ9BxKMq">/files/k0JYUfdQhHWFIZ9BxKMq</a></td></tr><tr><td align="center"><code>flowers</code></td><td data-object-fit="contain"><a href="/files/qnRyUk2mdQhhY3C7Zpaj">/files/qnRyUk2mdQhhY3C7Zpaj</a></td></tr><tr><td align="center"><code>goldenlight</code></td><td data-object-fit="contain"><a href="/files/dYJbjI0QUpUbVt4AAhPg">/files/dYJbjI0QUpUbVt4AAhPg</a></td></tr><tr><td align="center"><code>mountain</code></td><td data-object-fit="contain"><a href="/files/mNj17LqxxHiH43QJah5p">/files/mNj17LqxxHiH43QJah5p</a></td></tr><tr><td align="center"><code>pool</code></td><td data-object-fit="contain"><a href="/files/5P0ZoyzgUQldwBHUosCL">/files/5P0ZoyzgUQldwBHUosCL</a></td></tr><tr><td align="center"><code>latincity</code></td><td data-object-fit="contain"><a href="/files/ASerA2aObCrrfohVZzzK">/files/ASerA2aObCrrfohVZzzK</a></td></tr><tr><td align="center"><code>cafe</code></td><td data-object-fit="contain"><a href="/files/pOIsqqeC1TY1hAylFnkB">/files/pOIsqqeC1TY1hAylFnkB</a></td></tr><tr><td align="center"><code>asiancity</code></td><td data-object-fit="contain"><a href="/files/4TGJJG4wGjWgSdrE3M4X">/files/4TGJJG4wGjWgSdrE3M4X</a></td></tr><tr><td align="center"><code>nightlights</code></td><td data-object-fit="contain"><a href="/files/EsIhqi1zDJIacnhmhpW8">/files/EsIhqi1zDJIacnhmhpW8</a></td></tr><tr><td align="center"><code>desert</code></td><td data-object-fit="contain"><a href="/files/9y3YDcyNziwCXcAm35TG">/files/9y3YDcyNziwCXcAm35TG</a></td></tr></tbody></table>

</details>

To use a **custom scene**, you will need to provide an image of that scene using either the parameter `virtualModel.scene.custom.imageFile` or `virtualModel.scene.custom.imageUrl`.

{% hint style="info" %}
The parameter `virtualModel.scene.custom.imageFile` is only available when using the [POST endpoint](/image-editing-api-plus-plan/quickstart-guide.md#post-endpoint).
{% endhint %}

By default, this parameter will be set to `virtualModel.scene.preset.name=random`.

### `virtualModel.pose`

The parameter `virtualModel.pose` lets you control the pose of the person.

You can pick between a list of pre-set poses:

<details>

<summary>List of pre-set poses</summary>

<table data-card-size="large" data-view="cards"><thead><tr><th align="center"></th><th data-hidden data-card-cover data-type="image">Cover image</th></tr></thead><tbody><tr><td align="center"><code>random</code></td><td data-object-fit="contain"><a href="/files/Faf3PSv0EshWPi7lZidj">/files/Faf3PSv0EshWPi7lZidj</a></td></tr><tr><td align="center"><code>standing</code></td><td data-object-fit="contain"><a href="/files/cnatpfhy24KObYRZ2PeB">/files/cnatpfhy24KObYRZ2PeB</a></td></tr><tr><td align="center"><code>34turn</code></td><td data-object-fit="contain"><a href="/files/dyekqFCnTIiokOHjGz1h">/files/dyekqFCnTIiokOHjGz1h</a></td></tr><tr><td align="center"><code>powerstance</code></td><td data-object-fit="contain"><a href="/files/NL5voD4ITlb6OMMCWwBN">/files/NL5voD4ITlb6OMMCWwBN</a></td></tr><tr><td align="center"><code>walkingforward</code></td><td data-object-fit="contain"><a href="/files/dlkWBG6HAwLwzpUQXs6p">/files/dlkWBG6HAwLwzpUQXs6p</a></td></tr><tr><td align="center"><code>handinpocket</code></td><td data-object-fit="contain"><a href="/files/ur6H0OFDmyyQ00lRlHJy">/files/ur6H0OFDmyyQ00lRlHJy</a></td></tr><tr><td align="center"><code>crossedarms</code></td><td data-object-fit="contain"><a href="/files/9XySYGJsLsS1Ogxv9yEG">/files/9XySYGJsLsS1Ogxv9yEG</a></td></tr><tr><td align="center"><code>back</code></td><td data-object-fit="contain"><a href="/files/VM4Rvi8urMlwKsKYWuuf">/files/VM4Rvi8urMlwKsKYWuuf</a></td></tr><tr><td align="center"><code>overtheshoulder</code></td><td data-object-fit="contain"><a href="/files/s1TKlWffMaDgpiNR9MTC">/files/s1TKlWffMaDgpiNR9MTC</a></td></tr><tr><td align="center"><code>seated</code></td><td data-object-fit="contain"><a href="/files/rteXK1iHRMgqj77j4EvW">/files/rteXK1iHRMgqj77j4EvW</a></td></tr><tr><td align="center"><code>adjustingclothing</code></td><td data-object-fit="contain"><a href="/files/bCpiBRHlpXeNTQWOvzqt">/files/bCpiBRHlpXeNTQWOvzqt</a></td></tr><tr><td align="center"><code>playfulspin</code></td><td data-object-fit="contain"><a href="/files/o2L52MkKqh55bta3bX83">/files/o2L52MkKqh55bta3bX83</a></td></tr></tbody></table>

</details>

{% hint style="info" %}
For a Virtual Try-On, we recommend setting `virtualModel.pose=standing`
{% endhint %}

By default, this parameter will be set to `virtualModel.pose=random`.

## Which resolutions are supported?

By default, Virtual Try-On will produce outputs at a resolution of 1K (`1024x1024`).

Output resolutions of 2K and 4K are available for Enterprise plans:

<div><figure><img src="/files/lSCmE5dJ2O68aGeBouCe" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/Jn38LRKnRctDAfcsRWLX" alt=""><figcaption><p><em>(default 1K output)</em></p></figcaption></figure> <figure><img src="/files/rYmwUl5k8SsDYk7UuwSF" alt=""><figcaption><p><em>(4K output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/aQNuzwbcv3yRYoOd5nA6" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/3ZA6IUotMrjOhs7GdaOq" alt=""><figcaption><p><em>(default 1K output)</em></p></figcaption></figure> <figure><img src="/files/vgXZxUwjMHnI9wfp4vka" alt=""><figcaption><p><em>(4K output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/Q7T4kIRs89HxP0PUqZRi" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/ODYsbAoblPgLU35q1CHX" alt=""><figcaption><p><em>(default 1K output)</em></p></figcaption></figure> <figure><img src="/files/NLHwbWnJYuojdlVTptoA" alt=""><figcaption><p><em>(4K output)</em></p></figcaption></figure></div>

{% hint style="info" %}
Make sure to click on the images to see them in full resolution.
{% endhint %}

If you're interested to use 2K or 4K resolution, please [contact our team to book a demo](https://www.photoroom.com/contact-sales?utm_source=apidocumentation\&utm_medium=enterprisegated).

<a href="https://www.photoroom.com/contact-sales?utm_source=apidocumentation&#x26;utm_medium=enterprisegated" class="button primary">Book a demo</a>

## Additional Parameters

### `virtualModel.additionalProductImages[]`

Additional product images showing different angles or details of the same item.

These help the model better understand the product and generate more accurate results.

To provide these images, use either the parameter `virtualModel.additionalProductImages[].imageFile` or `virtualModel.additionalProductImages[].imageUrl`.

{% hint style="info" %}
The parameter `virtualModel.additionalProductImages[].imageFile` is only available when using the [POST endpoint](/image-editing-api-plus-plan/quickstart-guide.md#post-endpoint).
{% endhint %}

### `virtualModel.prompt`

Optional text prompt to guide the generation style.

Example: `street style`

### `virtualModel.size`

The output size and aspect ratio of the generated image.

Default: `PORTRAIT_HD_3_2`

Possible values: `PORTRAIT_HD_16_9`, `PORTRAIT_HD_4_3`, `PORTRAIT_HD_3_2`, `SQUARE_HD`, `LANDSCAPE_HD_3_2`, `LANDSCAPE_HD_4_3`, `LANDSCAPE_HD_16_9`


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.photoroom.com/image-editing-api-plus-plan/virtual-try-on.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
