Logo API Documentation

Authentication

All API endpoints require a Basic Authorization header. Use your projectName and secretKey to generate it.

The header value should be in the format:


{
    "Authorization": "Basic {base64_encoded(projectName:secretKey)}"
}

            

Base URL


{
    "Base URL": "https://api.aiwearlab.com/v1"
}
            

Endpoints

POST /product/similar_products

Finds similar products based on the specified filters and criteria.

Request Body


{
    "id": "string", // Required - The target product ID to determine similarity
    "product_view": "front_view",
    "details_required": true,
    "language": "string",
    "currency": "string",
    "filters": {         //Can be a single string or a list of strings
        "color": ["red", "blue"],
        "brand": "BrandName",
        "category": ["clothing", "shoes"],
        "gender": "female",
        "sizes": ["5(XL)"]
        // Additional filters can be added dynamically based on the data mapping
    },
    "price_filters": {
        "min_price": 10.0,
        "max_price": 100.0,
        "min_sale_price": 10.0,
        "max_sale_price": 100.0
    },
    "relation_filter": "similar", // "similar" or "complementary",
    "page": 1,
    "limit": 10
}
                

Response


{
    "locale": {
        "currency": "UAH",
        "language": "EN"
    },
    "meta": {
        "has_next_page": true,
        "limit": 3,
        "page": 1
    },
    "results": [
        {
            "group_id": "68325",
            "id": "68325-56270",
            "media": {
                "front_view_url": "https://example.com/images/goods/68325/front.jpg",
                "gallery_front_view_url": "https://example.com/images/goods/68325/gallery.webp",
                "other_view_urls": [
                    "https://example.com/images/goods/68325/other1.jpg",
                    "https://example.com/images/goods/68325/other2.jpg"
                ],
                "product_url": "https://example.com/goods/68325"
            },
            "prices": {
                "price": 500.0,
                "sale_price": 305.0,
                "sizes_prices": [
                    {
                        "price": 500.0,
                        "sale_price": 305.0,
                        "sizes": ["5(XL)"]
                    }
                ]
            },
            "properties": {
                "brand": "Anabel Arto",
                "category": "Women > Women's Underwear > Panties > Thongs",
                "color": "Champagne",
                "colors": [
                    {
                        "color": "Champagne",
                        "product_id": "68325-56270"
                    },
                    {
                        "color": "Pink",
                        "product_id": "68325-65900"
                    }
                ],
                "gender": "female",
                "material": "polyamide/spandex",
                "sizes": "5(XL)",
                "title": "Women's Lace Thong Panties"
            },
            "score": 0.9435
        }
    ],
    "target": {
        "group_id": "32897",
        "id": "32897-28129",
        "media": {
            "front_view_url": "https://example.com/images/goods/32897/front.jpg",
            "gallery_front_view_url": "https://example.com/images/goods/32897/gallery.webp",
            "other_view_urls": [
                "https://example.com/images/goods/32897/other1.jpg",
                "https://example.com/images/goods/32897/other2.jpg"
            ],
            "product_url": "https://example.com/goods/32897"
        },
        "prices": {
            "price": 603.0,
            "sale_price": 543.0,
            "sizes_prices": [
                {
                    "price": 603.0,
                    "sale_price": 543.0,
                    "sizes": ["3(M)", "4(L)", "5(XL)"]
                }
            ]
        },
        "properties": {
            "brand": "Si e Lei",
            "category": "Women > Women's Underwear > Panties > Thongs",
            "color": "White",
            "colors": [
                {
                    "color": "White",
                    "product_id": "32897-28129"
                },
                {
                    "color": "Black",
                    "product_id": "32897-28130"
                },
                {
                    "color": "Nude",
                    "product_id": "32897-34933"
                }
            ],
            "gender": "female",
            "material": "cotton/polyamide/elastane",
            "sizes": ["3(M)", "4(L)", "5(XL)"],
            "title": "Women's Transparent Panties"
        }
    }
}