younifyd
Menu

Get product variants

Get product variants

GET/products/{productIdentifier}/variants

Use it in a workflow

  1. Add a step and choose the SCAYLE Admin connector.
  2. Pick the Get product variants action (under Variants).
  3. Fill in the fields below, then reference the result from later steps as {{getProductVariants.response.data}}.

Request

Path parameters

productIdentifieroneOfrequired

Product ID or reference key. If you are using a reference key, it is highly recommended to use the encoded equal sign (%3D) instead of the plain =

Query parameters

witharray<string>

Comma-separated list of additional properties that should be included in the response.

limitinteger

Maximum number of entities in the result. When fetching entities with children, the limit always applies to the amount of parent entities (max. 1000).

Default 100

filters[id]array<integer>

Comma-separated list of IDs of entities that should be used for filtering.

filters[minId]integer

Minimum (inclusive) ID of entities that should be returned.

filters[maxId]integer

Maximum (inclusive) ID of entities that should be returned.

filters[minCreatedAt]string (date-time)

Minimum (inclusive) creation date of entities that should be returned.

filters[maxCreatedAt]string (date-time)

Maximum (inclusive) creation date of entities that should be returned.

filters[minUpdatedAt]string (date-time)

Minimum (inclusive) modification date of entities that should be returned.

filters[maxUpdatedAt]string (date-time)

Maximum (inclusive) modification date of entities that should be returned.

filters[attributes]object

This query parameter allows you to filter for entities with the given simple attributes. The array/object key must be the attribute name and the value can be a comma-separated list of attribute values. The filter logic will combine all attributes of the same group into an `OR` filter and all attribute groups into an `AND` filter.

sortstring

Sort by the provided column.

One ofidDefault "id"

sortDirstring

Sort ascending or descending

One ofascdescDefault "asc"

cursorstring

Valid cursor used for pagination.

Response

Returns 200 with an object. Read it in later steps with {{getProductVariants.response.data.<field>}}.

entitiesarray<object>
idinteger

ID assigned by SCAYLE.

referenceKeystringrequired

A key that uniquely identifies the variant of a product (usually an SKU) within the tenant's ecosystem.

merchantReferenceKeysarray<string>

A list of merchant reference keys the variant belongs to.

eanstring

An ean that refers to a product variant .

attributesarray<object>5 fields

A list of attributes attached to the product variant.

pricesarray<object>15 fields

A list of prices attached to the product variant.

stocksarray<object>6 fields

The product variant stock information.

customDataany
isCompositeboolean

Indicates whether the variant is composite.

relatedVariantsoneOf

A list of variants that belong to the composite variant. All variants in the list must use the same identification method, either all use variantId or all use variantReferenceKey. Empty arrays are allowed in responses.

cursorobject
nextstring

The cursor pointing to the next page. If null there is no next page available.

json
{
  "entities": [
    {
      "referenceKey": "M0001-black-M",
      "id": 0,
      "merchantReferenceKeys": [
        "string"
      ],
      "ean": "0000007619991",
      "attributes": [
        {
          "name": "size",
          "type": "simple",
          "value": "M",
          "isLocked": false
        }
      ],
      "prices": [
        {
          "price": 9999,
          "tax": 19,
          "countryCode": "DE",
          "currencyCode": "EUR",
          "key": "1-100",
          "oldPrice": 10999,
          "recommendedRetailPrice": 9999,
          "buyingPrice": 9999,
          "groupKey": "myPriceGroup",
          "promotionKey": "myPromotion",
          "unitPrice": {
            "unit": "ml",
            "amount": 100,
            "price": 999
          },
          "validFrom": "2021-09-23T11%3A30%3A58%2B00%3A00"
        }
      ],
      "stocks": [
        {
          "quantity": 27,
          "warehouseReferenceKey": "DefaultWarehouse",
          "changedAt": "2020-07-23T11%3A30%3A58%2B00%3A00",
          "sellableWithoutStock": true,
          "merchantReferenceKey": "string",
          "expectedAvailabilityAt": "2020-07-23"
        }
      ],
      "customData": null,
      "isComposite": false,
      "relatedVariants": null
    }
  ],
  "cursor": {
    "next": "MQ=="
  }
}

Need more? See the SCAYLE Admin guide for connection setup and behaviour shared by every action.