ResourcesProduct Variants

Overview

On this page, we’ll dive into the different product variant endpoints you can use to manage product variants programmatically.

Product variants are intertwined with products. It's what contains all data pertaining to deliverables and pricing.

As you might have already noticed, one product is able to have multiple variants which each can have their unique deliverables and pricing.

On this page, we'll dive into the different product variant endpoints you can use to manage products programmatically. We'll look at how to create, update, and delete product variants.

Endpoints

The product variant model

The product variant model contains all the information about the product variants located within a product, including the price and deliverables.

Properties

Name
idinteger
Description

The unique identifier for the product.

Name
product_idinteger
Description

The unique product identified this variant is linked to.

Name
titlestring
Description

The product variant title.

Name
descriptionstring
Description

The product variant description.

Name
deliverablearray
Description

Deliverable details of the product variant, consists of the following:

  • data Array of deliverable data to be delivered. Consists of the following:
    • serials Only applicable if deliverable.types contains TEXT. This array should contain all of your serials, separated by the delimiter you set in parsingMode.
    • removeDuplicate Whether duplicate TEXT values should be removed.
    • parsingMode In which way TEXT values are separated/parsed.
    • comment Only applicable if deliverable.types contains MANUAL. This string should specify what the next steps are for the manual delivery to be completed.
    • file Only applicable if deliverable.types contains DOWNLOADABLE. If wanting to upload a file, make sure to send the request as a Multipart form instead of JSON.
    • webhook Only applicable if deliverable.types contains DYNAMIC. This string should be your dynamic webhook endpoint, which we ping following a successful purchase.
    • stock Specifies how much stock there is for the deliverable. Not required if deliverable.types contains TEXT as it is calculated automatically. If not present, stock will be set to infinite.
  • types Array with values of the deliverable type(s) this product variant contains. Supported values:
    • DOWNLOADABLE Downloadable file of any type.
    • TEXT Text products delivered one-by-one.
    • DYNAMIC Generate a product via your webhook URL.
    • MANUAL A product that is manually carried out and/or delivered.
Name
pricingarray
Description

The product variant pricing array, contains the following values:

  • humble Whether the product is of a "Pay what you want" type. If set to true, the customer can add an extra amount of their choosing on top of the price.
  • frequency array that specifies how often a product should be charged. Consists of two values:
    • value that specifies the period duration
    • interval that specifies the interval between values. Can be days, weeks, months. Up to 1 year.
  • type that contains a string of the charge frequency. One of two values:
    • SINGLE_PAYMENT for one-off charges
    • SUBSCRIPTION for recurring charges
      • At the moment, only Stripe is supported for subscriptions
  • price which contains the product price array. Consists of two values:
    • price product price, in cents
    • currency Country ISO code of the currency the product is priced in
Name
minimum_purchase_quantityinteger
Description

The minimum amount of stock a customer is required to purchase.

Name
maximum_purchase_quantityinteger
Description

The maximum amount of stock a customer is allowed to purchase. If set to null, the customer can purchase an unlimited amount of quantity.

Name
bulk_discountobject
Description

The bulk discount values of the product. Array consists of:

  • minimum_purchase_amount The quantity at which the bulk discount gets triggered.
  • discount_percentage The discount value (in percentage) that gets applied to the product price.
Name
payment_methodsarray
Description

This specifies which payment methods are available for the customer to check out with. Your store has to have a payment method activated in order for these to be set.

  • Consists of at least one of the below values:
    • PAYPAL PayPal
    • STRIPE Stripe
    • CASHAPP Cash App
    • PADDLE Paddle
    • AUTHNET Authorize.net
    • SQUARE Square
  • Cryptocurrency payment methods:
    • BTC Bitcoin
    • LTC Litecoin
    • ETH Ethereum
    • XMR Monero
    • BNB Binance BNB
    • TRX Tron
    • MATIC Polygon
    • ETH_USDT USDT (ETH network)
    • ETH_USDC USDC (ETH network)
    • ETH_UNI UNI (ETH network)
    • ETH_SHIB Shiba (ETH network)
    • ETH_DAI DAI (ETH network)
    • BNB_USDT USDT (BSC network)
    • BNB_USDC USDC (BSC network)
    • TRX_USDT USDT (TRX network)
    • TRX_USDC USDC (TRX network)
Name
other_settingsarray
Description

Array of additional settings pertaining to the product variant. Consists of:

  • quantity_increments that specifies by how much a product can be incremented.
    • The default is 1, which lets a customer purchase a quantity of 1,2,3 and so on
    • When set to e.g. 2, the customer can only purchase a quantity of 1,3,5 and so on. A quantity of 2 would end up not being allowed.
  • discord_data_required which specifies whether a customer is required to authorize their Discord account before proceeding with the purchase. If enabled, a customer can not check out before linking their Discord account.
Name
orderinteger
Description

The order of this variant relative to all other variants within the product

Name
created_attimestamp
Description

The time at which this product variant was first created.

Name
updated_attimestamp
Description

The time at which this product variant was last updated.

Name
deleted_attimestamp
Description

The time at which this product variant was deleted.

Name
productarray
Description

The relevant product details attached to this variant (readonly). Consists of additional information input(s) of the product. Additional information input array consists of:

  • required specifying whether the additional information is required
  • key unique key of the additional information input
  • type One of the following
    • TEXT
    • NUMBER
    • HIDDEN
    • TEXTAREA
    • CHECKBOX
  • label specifying what the customer needs to enter. Examples below
    • TEXT What is your in-game username?
    • NUMBER To what mobile number do you want this delivered?
    • HIDDEN n.a. (as this is a hidden input not visible to the end-user)
    • TEXTAREA Please specify what your website should look like.
    • CHECKBOX Would you like a complimentary drink?

On this page