More like one product

post/v1/shoppers/me/similar

Products like one the shopper picked, from the same slot, ordered by how alike they are and, with a token, a quarter by the shopper's own taste. The product itself is not returned, nor products that are not worn (slot non fashion).

Public keyapi.v1.shoppersDemo key OK

Headers

1
X-Shopper-Tokenstring

The shopper's profile token, from auth/start, auth/verify or any call that made a profile. Optional here.

Request body

application/jsonrequired
itemIdstringrequired

The product to find more like.

ageGroupstring

Only this age group, as products carry it in metadata.age_group. adult keeps products with no age group (labelled before age groups existed), as search does.

One ofadultkidsbaby
limitinteger

Products to return. Clamped to 1–60.

default: 12min: 1max: 60
countrystring

The shopper's two-letter country, for prices in their market.

Response

200The products, most alike first.
array<ShopperProductCard>required
itemIdstring

The product. Open it with Retrieve products.

namestringnullable

The product's name.

urlstringnullable

The product's page on its store.

pricenumbernullable

Price in currency, in the shopper's market when country was sent.

currencystringnullable

ISO currency code.

compareAtPricenumbernullable

The price before a sale, when on sale.

imagestringnullable

A 600 px wide WebP of the product's best photo.

slotstringnullable

The garment slot.

colourstringnullable

Its colour family.

scorenumber

How well it fits their taste, or how alike it is for similar.

reasonstringnullable

Why it is here, in a short sentence the shopper can read.

stylestringnullable

The id of the style it was chosen for, from profile.styles. Null for something new.

Errors

25

Every error is JSON with a single error string unless noted. Match on the status code; the message is for humans.

400
Request body must be valid JSON.

A body was sent and could not be parsed as JSON.

400
Request body must be a JSON object.

A body was sent and parsed to something other than a JSON object.

401
That shopper token is not valid here. Start a profile or sign in again.

X-Shopper-Token was sent but cannot be opened with this key.

404
No such product.

itemId is not a product in your catalogue.

422
ageGroup must be one of adult, kids, baby.

ageGroup was sent (non-null) but is another value.

422
itemId is required.

itemId is missing or empty.

curl -X POST "https://stylor.ai/api/v1/shoppers/me/similar" \
  -H "Authorization: Bearer $STYLOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "itemId": "35a725c8-23fb-4009-a52a-2a778d2e504a",
  "limit": 12,
  "country": "US"
}'
Response · 200
{
  "items": [
    {
      "itemId": "a342cbe3-965b-4055-8ac3-20f63103cade",
      "name": "NEW CLASSIC JEAN DENIM",
      "url": "https://ca.stussy.com/products/new-classic-jean-denim",
      "price": 195,
      "currency": "CAD",
      "compareAtPrice": null,
      "image": "https://stylor.ai/api/v1/image/v1/datasets/images/0c1d2e3f.jpeg?resize=600x&format=webp",
      "slot": "bottom",
      "colour": "blue",
      "score": 0.912,
      "reason": "Like the one you picked.",
      "style": null
    }
  ]
}