Skip to main content

Product Variants

The Product Variants API lets you manage different variants of products in your store.

Overview

The Product Variants API provides endpoints to:

Price units

amount and old_price use opposite units.

  • amount is the charged price in minor units (e.g. cents). 1999 is 19.99 PLN.
  • old_price is the struck-through compare-at price in major currency units. 79 is 79.00 PLN.

On update, set old_price to null to clear it.

warning

Sending old_price: 7900 when you meant 79.00 PLN stores and displays 7900 PLN on checkout.

Active plan required

Creating or updating a variant of a published product requires the store to have an active Easytools plan, because the change goes live immediately. Create product variant and Update product variant return 422 without one, and nothing is created or changed. Variants of a draft product can always be created and updated. See Active plan required.

Downloadable files

A variant can carry up to 5 of its own files. When it has any, buyers of that variant receive them instead of the product's files; when it has none, they fall back to the product's.

Variant files use the same file object as product files — url is the stored location you send back when writing, and reads add a temporary download_url that returns the contents. See Downloadable files and Download Product File.

Access expiry modes

A variant can limit how long buyers keep access in one of two mutually-exclusive modes:

  • Relative - active_days: buyers keep access for N days after purchase.
  • Fixed - access_until: buyers keep access until a fixed calendar date. Setting access_until also ends the sale window (active_until is set to the same date), so the variant stops selling on that date.

The API does not enforce mutual exclusivity. If both fields are set, access_until takes precedence at fulfilment.