Thoughtful finds. Delivered to Nigeria.Delivery, made clear
DEELINE.
Reference

Variants

Every product has one or more variants — the concrete items a customer buys (a specific size, colour, or configuration). To place an order later, you need the variant ID, not the product ID.

Shape

{
  "variants": [
    {
      "id": "1797628372869189632",
      "sku": "SKU-DEMO-001",
      "priceNgn": 3450.00,
      "attributes": {
        "color": "White Gold",
        "size": "Adjustable Opening"
      }
    }
  ]
}

Field reference

FieldTypeNotes
idstringVariant ID. Use as variantId when placing an order.
skustring | undefinedUnique SKU. Optional.
priceNgnnumberVariant-specific reseller price. May differ from the base product price.
attributes.colorstring | undefinedColour name, when applicable.
attributes.sizestring | undefinedSize or configuration label, when applicable.

Why variants matter

  • Correct pricing. A product may have several prices — the variant price is the accurate one.
  • Correct delivery. Some variants (e.g. oversized items) have different shipping weight.
  • Correct fulfilment. When you place an order, you must send the variant ID; sending just the product ID is not enough.

Example: choosing a variant

A product has multiple variants. You display them as size / colour buttons and let the customer pick one. The chosen variant's id is what you store and, eventually, send with the checkout.

JavaScript

const product = data.products[0];

// Suppose the customer picked the first variant:
const chosenVariant = product.variants[0];

console.log(chosenVariant.id);        // variant ID for checkout
console.log(chosenVariant.priceNgn);  // price for this variant
console.log(chosenVariant.attributes.color); // "White Gold"

Python

product = data["products"][0]
chosen = product["variants"][0]

print(chosen["id"])                # variant ID for checkout
print(chosen["priceNgn"])          # price
print(chosen.get("attributes", {}))

What happens if a product has no variants?

A very small number of products may have an empty variants array (edge cases during catalogue updates). When that happens, treat the product as unavailable for that request and skip it. New syncs restore the variants.

Multiple variants: how to display

Most products have one attribute (color) or two (color + size). To display them:

  • Group by attributes.color first, then by attributes.size.
  • Show the price from the selected variant, not the base price.
  • Disable sizes that do not exist for the currently selected colour.
  • Pass variant.id to your checkout flow.

See also