Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.drssed.app/llms.txt

Use this file to discover all available pages before exploring further.

Call POST /images/preview to upload a clothing photo and run it through the Drssed image pipeline. The API removes the background from the image and uses AI to detect the item’s dominant color, category, relevant seasons, and style tags. The returned image_id links the processed image to a clothing item when you call POST /users/me/clothing.

Endpoint

FieldValue
MethodPOST
Path/images/preview
Auth requiredYes — Bearer token
Rate limit1 per minute
Content-Typemultipart/form-data

Request parameters

file
file
required
The clothing image to process. Send as a multipart/form-data field.

Response fields

Status: 201 Created
image_url
string
required
URL of the processed image with the background removed.
image_id
string
required
Unique identifier for this processed image. Pass this as image_id when creating a clothing item via POST /users/me/clothing.
image_color
string
required
Detected dominant color of the clothing item.
image_category
string
required
Detected category of the clothing item. One of: JACKET, TOP, BOTTOM, FOOTWEAR.
image_seasons
array
required
Detected seasons the item is suited for. Possible values: Spring, Summer, Autumn, Winter.
image_tags
array
required
Detected style tags for the item. Possible values: Casual, Formal, Sports, Vintage.

Error codes

StatusMeaning
400No file was included in the request.
413The uploaded file exceeds the maximum allowed size.
422The image is unclear or not recognizable as clothing.

Example

cURL
curl --request POST \
  --url https://api.drssed.com/images/preview \
  --header "Authorization: Bearer <token>" \
  --form "[email protected]"
Response
{
  "image_url": "https://api.drssed.com/uploads/clothing_images/img_f1e2d3c4",
  "image_id": "img_f1e2d3c4",
  "image_color": "Navy Blue",
  "image_category": "TOP",
  "image_seasons": ["Spring", "Autumn"],
  "image_tags": ["Casual"]
}
This endpoint is strictly rate limited to 1 request per minute. Queue image uploads appropriately to avoid hitting the limit.
Use the returned image_category, image_seasons, and image_tags as default values when calling POST /users/me/clothing — this reduces the amount of input the user needs to provide.