Developer Documentation
SmartDrobe REST API v1.0
OpenAPI 3.0 compatible endpoints for authenticating users, querying digital wardrobes, and requesting AI outfit recommendations.
Authentication Specification
All protected endpoints require an HTTP-only JWT session cookie named smartdrobe_token issued upon calling POST /api/auth/login.
Core API Endpoints
POST
/api/auth/loginAuthenticate user credentialsRequest Body
{
"email": "user@smartdrobe.ai",
"password": "password123"
}Response 200 OK
{
"success": true,
"user": {
"id": "usr_9981",
"name": "Sophia Chen",
"role": "USER"
}
}GET
/api/wardrobeFetch cataloged wardrobe itemsQuery Parameters
category = "Shirts" | "Pants" | "Shoes" season = "Summer" | "Winter" | "All-Season" search = "oxford"
Response 200 OK
{
"items": [
{
"id": "item_01",
"name": "Crisp Oxford Shirt",
"category": "Shirts",
"color": "White"
}
]
}POST
/api/outfits/generateExecute AI styling algorithmRequest Body
{
"occasion": "Work",
"season": "Fall",
"weather": "Cool 58°F",
"style": "Minimalist"
}Response 200 OK
{
"outfit": {
"title": "Executive Minimalist Look",
"score": 98,
"explanation": "Pairs crisp shirt..."
}
}