Presets

Extract preset from image

POST
/preset/extract-from-image

Upload a reference image and use AI to extract style settings as a preset. The image must already be uploaded as an asset (via POST /upload).

Authorization

token_auth
headerAuthorizationBearer <token>

Token-based authentication using access tokens.

Request Body

application/json
  1. body
file_id*File Id

UUID of the uploaded asset to analyze.

Lengthlength <= 100
type?Type

Preset type to extract for.

Default"flat_2_model"
Value in"flat_2_model""model_swap""identity_creation""create_packshot""garment_recolor"

Response Body

Successful Response

application/json
  1. response
instruction_data*

Extracted instruction data in preset format.

suggested_name?|

AI-suggested preset name.

Defaultnull
suggested_description?|

AI-suggested description.

Defaultnull
file_id?|

UUID of the source asset the preset was extracted from (image mode only). The client persists this on the preset as instruction_data.reference_asset so the user can optionally use the original image as an overall reference at generation time. Null for text extraction.

Defaultnull
curl -X POST "https://example.com/preset/extract-from-image" \  -H "Content-Type: application/json" \  -d '{    "file_id": "string"  }'
{  "instruction_data": {},  "suggested_name": null,  "suggested_description": null,  "file_id": null}