Prompt Try-On
The Prompt Try-On endpoint allows you to describe a new outfit using text to seamlessly drape it onto an AI fashion model.
Model Name: prompt-tryon
Lifecycle: stable
Processing Time: ~15s–40s (increases when using style or model references)
Output Format: Auto (JPEG or PNG)
Delivery Methods: URL
Credits: 1 to 5 per generation (depends on quality)
Request
Submit your try-on configuration to the universal /v1/run endpoint:
https://fititon.app/api/v1/runRequest Examples
Authentication
You can pass your API key either as a Bearer token (Authorization: Bearer YOUR_API_KEY) or via the x-api-key header (x-api-key: YOUR_API_KEY).
curl -X POST https://fititon.app/api/v1/run \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model_name": "prompt-tryon",
"inputs": {
"personImage": "https://example.com/person.jpg",
"prompt": "A stylish red summer dress with floral patterns.",
"quality": "2k",
"sampleCount": 1,
"ratio": "16:9",
"modelImageUrl": "https://example.com/model-reference.jpg",
"styleId": "movie"
}
}'Response
The Try-On generation happens asynchronously in the background. Your request will immediately return a 200 OK status with a tracking object.
{
"id": "123a87r9-4129-4bb3-be18-9c9fb5bd7fc1",
"status": "starting",
"created_at": "2026-07-17T11:00:00Z",
"error": null,
"output": null
}Polling for Results
You must use the returned id to poll the status endpoint (GET https://fititon.app/api/v1/status/{id}) to retrieve your generated image URLs. See the API Setup guide for detailed instructions.
When the generation finishes, the polling endpoint will return status: "success" with the following output array containing the final image URLs:
{
"id": "123a87r9-4129-4bb3-be18-9c9fb5bd7fc1",
"status": "success",
"output": [
"https://pub-r2.com/.../result-0.png"
],
"error": null,
"created_at": "2026-07-17T11:00:00Z",
"updated_at": "2026-07-17T11:00:45Z"
}Request Parameters
Required Parameters
personImageRequiredstringThe base image of the model you want to dress. Can be a publicly accessible URL or a Base64-encoded image string. Supported formats: JPEG, PNG, WEBP. Max size: 25MB.
Pro Tip: Front-facing poses with arms visible produce the most realistic draping.
Formatting Requirement
When submitting a Base64 string, it must include the standard data URI prefix (e.g., data:image/jpeg;base64,...). The /v1/run endpoint only accepts JSON payloads.
promptRequiredstringText description of the outfit you want the model to wear.
Pro Tip: Include fabric type (silk, cotton, denim) and fit style (slim, oversized) for the best results. Specify colors precisely ("navy blue" works better than "blue") and explicitly reference what the model is already wearing so the AI knows exactly what to change.
Optional Parameters
quality'1k' | '2k' | '4k'Output resolution tier for Prompt Try-On (Gemini models). Higher resolutions consume more credits.
Default: 1k
sampleCountintegerNumber of image variations to generate per request. Must be between 1 and 4. Additional images consume more credits and increase processing time linearly.
Default: 1
ratiostringDefines the width-to-height ratio of the generated image. If empty, the system defaults to the aspect ratio of the personImage.
Supported values: '1:1', '3:4', '4:3', '9:16', '16:9', '2:3', '3:2', '4:5', '5:4', '21:9'.
modelImageUrlstringOptional. URL of a human reference model to use instead of preserving the original person's features.
Preset Models Available:
styleIdstringOptional. Apply a specific photographic style to the output image.
Available Styles:
| Style Name | Style ID (`styleId`) |
|---|---|
Valid values: y2k, studio, iphone, professional, lifestyle, analog, streetwear, flash, movie, minimalist, ugc, editorial.
Note: Complex styles may increase the overall generation time.
Runtime Errors
Runtime errors for this feature use the shared set documented in Error Handling. If an error occurs during processing, the status will update to "error" and the error field will contain the specific failure reason.
Credit Cost
The cost depends on the selected quality tier and is multiplied by your sampleCount.
Formula: Cost = QualityCredits × sampleCount
| Parameter | Credits per Image |
|---|---|
quality="1k" | 1 |
quality="2k" | 3 |
quality="4k" | 5 |
