Generate Mockup
Endpoints
Generate Mockup
Create apparel mockups by compositing designs onto garments
POST
Generate Mockup
Generate Mockup
Composite a design image onto a garment blank to create a realistic mockup.Each generation costs 1 token.
Endpoint
Request Body
URL of the design image to place on the garment. Must be publicly accessible.
ID of the garment from the
/garments endpoint.Direct URL to the garment blank image (specific color variant).
Color variant name (e.g., “Black”, “White”, “Navy”).
Print zone to use. Options:
front, back, left-chest, right-chest.Design placement configuration.
Apply subtle fabric texture effect for realism.
URL to receive a POST callback when generation completes.
Response
Unique generation ID (e.g.,
gen_1703001234_abc123).Generation status:
pending, processing, completed, or failed.URL of the generated mockup image (when completed).
URL of a smaller thumbnail version.
Number of tokens consumed (always 1).
ISO 8601 timestamp of when the generation started.
ISO 8601 timestamp of when the generation finished.
Error message if status is
failed.Example
Response Example
Webhooks
If you provide awebhookUrl, we’ll POST the completed generation to your endpoint:
Errors
| Code | Status | Description |
|---|---|---|
invalid_request | 400 | Missing required fields or invalid URLs |
insufficient_tokens | 402 | Not enough tokens |
not_found | 404 | Garment ID not found |