Docs

Unbxd Recommendations - REST APIs

REST APIs provide quick and seamless connection to Unbxd platforms and let you easily integrate the recommendation widgets in your ecommerce store. With each widget having its own API signature, configuring them on different pages of your store becomes really simple. The following sections will explain in detail about these APIs and teach you how to use them on your online store.

Before you start making the API calls, there are some prerequisite steps you must complete. Learn the steps to integrate Unbxd Recommendations in your online store.

API Parameters

The various parameters used in each recommendation widget API are explained in the table below:

ParameterAcceptable ValueDefault ValueMandatoryDescription
regionapac, usN/AYesThis parameter specifies the geographical location of your server. The selected region must be the closest to your server location.
API_KEYN/AN/AYesYour API key.
SITE_KEYN/AN/AYesYour Site key.
uidN/AN/AYesThe unique identifier of a visitor. This value can be easily obtained from a browser cookie "unbxd.userId" which gets automatically added on every visit.
pidN/AN/AYesThe unique identifier of the product on whose Product Detail Page (PDP) the widget needs to be integrated. This value can be obtained from the uploaded Product Feed.
categoryN/AN/AYesThe category of a product. This value can be obtained from the uploaded Product Feed.
brandN/AN/AYesThe brand of a product. This value can be obtained from the uploaded Product Feed.
ipValid IPv4 addressN/ANoThe IP address of a visitor.
format"html", "json"htmlNoThe response format.
currencyISO 4217 currency code format."USD" US DollarNoSpecifies the currency used.
screenWidthPositive numbersN/ANoUsed for resizing the widget according to the screen width. This parameter is only used when the format is "html".

Recommended For You

The Recommended For You is a personalized widget that showcases recommendations based on the visitor’s interaction history on your online store. Learn more about this widget.

The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/recommend/<uid>/?ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Note:

`v1.0` specifies that we are using the first version of the API.

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "RECOMMENDED_FOR_YOU",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "http://images.examplewebsite.com/is/image/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "http://images.examplewebsite.com/is/image/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "http://images.examplewebsite.com/is/image/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Recently Viewed

The Recently Viewed widget recommends products that were recently viewed by a visitor. Learn more about this widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/recently-viewed/<uid>/<pid>/?format=<format>&currency=<currency>&screenWidth=<screenWidth>  
To use this widget on pages other than the PDP remove the "pid" parameter. The API will then look like this:
http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/recently-viewed/<uid>/?format=<format>&currency=<currency>&screenWidth=<screenWidth>  


Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "RECENTLY_VIEWED",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

{
   "count": 0,
   "error": {
      "code": 3001,
      "message": "message describing the error "
   }
}

More Like These

The "More Like These" widget is built to recommend products similar to the one being viewed on the PDP (Product Detail Page). The widget leverages visitor's interaction history on the store to fetch relevant recommendation. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/more-like-these/<pid>/?uid=<uide>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "MORE_LIKE_THESE",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

{
   "count": 0,
   "error": {
      "code": 3001,
      "message": "message describing the error "
   }
}

Viewed also Viewed

As the name suggests, this widget recommends products viewed by other visitors. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/also-viewed/<pid>/?uid=<uid>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "ALSO_VIEWED",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Bought also Bought

Similar to the "Viewed also Viewed" widget, the Bought also Bought widget recommends products bought by other visitors. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/also-bought/<pid>/?uid=<uid>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "ALSO_BOUGHT",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }
It is highly recommended to not integrate the Viewed also Viewed and Bought also Bought widget together on the same PDP (Product Detail Page) as it would prevent the widgets from showing duplicate products. This scenario may arise right after integrating the widgets due to the lack of site data.

Cart Recommendations

This widget recommends complementary products on the "Cart page" for those present in the visitor's cart. This widget allows you to cross-sell products even on the cart page. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/cart-recommend/<uid>/?ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "CART_RECOMMEND",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Homepage Top Sellers

This widget recommends top selling products bought from the homepage. Learn more about the widget.

The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/top-sellers/?uid=<uid>&ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "TOP_SELLERS",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Category Top Sellers

This widget recommends top selling products from a specific category. Learn more about this widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/category-top-sellers/<category>/?uid=<uid>&ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "CATEGORY_TOP_SELLERS",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

PDP Top Sellers

This widget recommends top selling products for a specific product. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/pdp-top-sellers/<pid>/?uid=<uid>&ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "PDP_TOP_SELLERS",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Brand Top Sellers

This widget recommends top selling products from a specific brand. Learn more about the widget. The request format is shown below:

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/brand-top-sellers/<brand>/?uid=<uid>&ip=<ip>&format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

A sample Success response will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "BRAND_TOP_SELLERS",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 150.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 200.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "Women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 172.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "Women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }

Complete the Look

The Complete the Look widget showcases curated products on a Product Display Page (PDP) that are usually associated with the original product. Ensure that this widget is configured on the console before sending the request. The request format is shown below:

Learn more about the widget.

http(s)://recommendations.unbxdapi.com/v1.0/<API_KEY>/<SITE_KEY>/complete-the-look/<pid>/?format=<format>&currency=<currency>&screenWidth=<screenWidth>  

Response

The "Complete the look" widget response for "Vera Wang Ivory White Wedding Gown" will look like this:

{
  "status": 200,
  "queryTime": 13,
  "boxType": "COMPLETE_THE_LOOK",
  "count": 3,
  "location": null,
  "explanation": null,
  "error": null,
  "Recommendations": [
    {
      "title": "Vera Wang Bridal Fingerless Gloves",
      "price": 49.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/09_980_4002_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-bridal-fingerless-gloves/pro/002/540011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "9804002",
    },
    {
      "title": "Flower White Gracious Tiara",
      "price": 34.9,
      "catlevel2Name": "Birthdays and Parties",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/06_107_0035_098?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/flower-white-gracious-tiara/pro/035/940011",
      "gender": "women",
      "availability": "YES",
      "uniqueId": "1070035",
    },
    {
      "title": "Vera Wang Ivory Lace Edge Cathedral Length Bridal Veil",
      "price": 24.9,
      "catlevel2Name": "Bridal Accessories",
      "imageUrl": [
        "http://images.examplewebsite.com/is/image/34_373_1272_058?cache=on&wid=361&fmt=jpeg&qlt=75,1&resmode=sharp2&op_usm=1,1,5,0"
      ],
      "catlevel1Name": "Women",
      "productUrl": "/clothing/women/vera-wang-ivory-lace-edge-cathedral-length-bridal-veil/pro/766/1720002",
      "gender": "women",
      "catlevel2Name": "Bridal Accessories",
      "availability": "YES",
      "uniqueId": "3731272",
    }
  ]
}

A sample Failure response will look like this:

    {
       "count": 0,
       "error": {
          "code": 3001,
          "message": "message describing the error"
       }
    }
If you do not have custom templates for any widget at the ready, you can choose to Edit Widget Templates from your Recommendation console to suit your online store.