---
updatedAt: 2026-04-12T09:22:25.000Z
---

# Get variants API

# Overview

The [Get variants API ](https://developer.walmart.com/us-marketplace/reference/getassortmentrecommendationvariants) lists customer favorite preferences such as size, color, or material.

# Endpoint

```text bash
GET 
https://marketplace.walmartapis.com/v3/growth/assortment/recommendations/variants 
```

# Functionality

This API can help you:

* Find product variants and demand trends.
* Compare pricing variations and offers that competitors are making.
* Decide which product variations are primary or non-primary.
* Drive inventory and pricing decisions at the product variations level.

# Request sample

```curl
curl --request GET \
     --url https://marketplace.walmartapis.com/v3/growth/assortment/recommendations/variants \
     --header 'accept: application/json'
```
```python
import requests

url = "https://marketplace.walmartapis.com/v3/growth/assortment/recommendations"

headers = {
    "accept": "application/json",
    "content-type": "application/json",
    # Include your auth + required Walmart headers as applicable in your integration.
}

payload = {
    "recommendationType": "ITEM",
    "meta": {"limit": 2}
}

resp = requests.post(url, headers=headers, json=payload, timeout=30)
resp.raise_for_status()
print(resp.json())
```

# Modify your code

**Add authentication and tracing headers.**\
Include required Marketplace credentials and optional tracing headers:

```json
\--header 'Authorization: Bearer \<ACCESS_TOKEN>' \\ 
\--header 'WM_CONSUMER.ID: \<CONSUMER_ID>' \\ 
\--header 'WM_QOS.CORRELATION_ID: <unique-id>'
```

# Response sample 200 All item recommendations

```json
{
  "payload": {
    "meta": {
      "totalRecords": 12,
      "recordsFetched": 2,
      "limit": 200,
      "nextCursor": "FGluY2x1ZGVfY29udGV4dF91dWlkDXF1ZXJ5QW5kRmV0Y2gBFkxxYXVqbDdDU215YlJmTzVoY1V3cGcAAAAAAAAbXhZzRk1VYTR0RlRLbTBHYm4zZWxXaFRB"
    },
    "primaryVariantItemId": "B0BQPH9CNF",
    "records": [
      {
        "itemRecommendationUniqueId": "2023736962",
        "itemDetails": {
          "title": "Nintendo Super Mario Bomber Jacket, Mario and Luigi Bomber Jacket",
          "brand": "Nintendo",
          "category": "Clothing",
          "productType": "Outerwear Jackets",
          "gtin": "00197347024339",
          "upc": "0019734702433",
          "ean": "0197347024339",
          "itemAvailabilityStatus": "EXISTING_IN_WALMART",
          "potentialSales": "$0-$10K",
          "shoppingTrends": [
            "Best sellers"
          ],
          "demandSalesTrends": [
            "OCT",
            "FEB",
            "DEC",
            "NOV",
            "JAN",
            "MAR"
          ],
          "offerCount": 1,
          "walmart": {
            "itemId": "2023736962",
            "url": "www.walmart.com/ip/2023736962",
            "itemPrice": {
              "amount": 42.99,
              "currency": "USD"
            },
            "shippingPrice": {
              "amount": 0,
              "currency": "USD"
            }
          },
          "competitors": [
            {
              "itemId": "B0BQPH9CNF",
              "url": "www.amazon.com/dp/B0BQPH9CNF",
              "itemPrice": {
                "amount": 51.99,
                "currency": "USD"
              },
              "shippingPrice": {
                "amount": 0,
                "currency": "USD"
              }
            }
          ],
          "freeShipping": "NO",
          "ratingCount": 1832,
          "rating": 4.7,
          "variantInfo": [
            {
              "name": "Color",
              "value": "Bowser Black"
            },
            {
              "name": "Size",
              "value": "4"
            }
          ],
          "isPrimaryVariant": true
        }
      },
      {
        "itemRecommendationUniqueId": "3744707969",
        "itemDetails": {
          "title": "Nintendo Super Mario Bomber Jacket, Mario and Luigi Bomber Jacket",
          "brand": "Nintendo",
          "category": "Clothing",
          "productType": "Outerwear Jackets",
          "itemAvailabilityStatus": "EXISTING_IN_WALMART",
          "potentialSales": "$0-$10K",
          "shoppingTrends": [
            "Best sellers"
          ],
          "demandSalesTrends": [
            "OCT",
            "FEB",
            "DEC",
            "NOV",
            "JAN",
            "MAR"
          ],
          "offerCount": 1,
          "walmart": {
            "itemId": "3744707969",
            "url": "www.walmart.com/ip/3744707969",
            "itemPrice": {
              "amount": 42.99,
              "currency": "USD"
            },
            "shippingPrice": {
              "amount": 0,
              "currency": "USD"
            }
          },
          "competitors": [
            {
              "itemId": "B0BQP6JSFF",
              "url": "www.amazon.com/dp/B0BQP6JSFF",
              "itemPrice": {
                "amount": 48.99,
                "currency": "USD"
              },
              "shippingPrice": {
                "amount": 0,
                "currency": "USD"
              }
            }
          ],
          "freeShipping": "NO",
          "ratingCount": 1786,
          "rating": 4.8,
          "variantInfo": [
            {
              "name": "Color",
              "value": "Bowser Black"
            },
            {
              "name": "Size",
              "value": "5-6"
            }
          ],
          "isPrimaryVariant": false
        }
      }
    ]
  }
}
```

# Result

* You receive variant-level recommendation entries grouped under a `primaryVariantItemId`.
* Each record includes variant metadata, pricing (Walmart + competitor), shipping, rating, demand signals, and `variantInfo` (for example, color, size).
* `isPrimaryVariant` identifies whether the record is the primary variant for that group.
* Use `nextCursor` to fetch additional variant records (if `recordsFetched `< `totalRecords`).

# Next steps

* **Get recommendations API**:  Makes suggestions about what to sell on Walmart Marketplace based on market trends, customer-favorite items, high demand items over the past 30 days, and gaps in your product availability.
  * [Get recommendations API Guide ](https://developer.walmart.com/us-marketplace/docs/get-recommendations-api)
  * [Get recommendations API Reference Guide ](https://developer.walmart.com/us-marketplace/reference/getassortmentrecommendations-1)
* **Get categorization API**: Provides a list of brands and categories for every recommended item, then a secondary sort by alphabetical order. You can use `BRAND` or `CATEGORY` for `categorizationType`.
  * [Get categorization API Guide ](https://developer.walmart.com/us-marketplace/docs/get-categorization-api)
  * [Get categorization API Reference Guide ](https://developer.walmart.com/us-marketplace/reference/getcategorizationdetailsofassortmentrecommendations-1)
* **Reject recommendations API**: Lets you reject items Walmart recommends. If you reject a recommended item, you won’t see it again.
  * [Reject recommendations API Guide ](https://developer.walmart.com/us-marketplace/docs/reject-recommendations-api)
  * [Reject recommendations API Reference Guide ](https://developer.walmart.com/us-marketplace/reference/rejectassortmentrecommendations-1)
* **Get recommendation trends API**:  Provides data trends about your assortment on Walmart, such as price and demand trends, so you can respond quickly and maintain a competitive edge.
  * [Get recommendation trends API Guide ](https://developer.walmart.com/us-marketplace/docs/get-trends-api-1)
  * [Get recommendation trends API Reference Guide](https://developer.walmart.com/us-marketplace/reference/getassortmentrecommendationtrends-1)