Skip to content

ProductVariantList_Load_Query#


Description#

This function loads a list of product variants for a product.

Request Parameters#

Parameter
Type Description
count Number Maximum lines of data allowed to be returned in the response. This limit is used to prevent excessive amounts of data return
filter String A string for filtering returned data
offset Number Used with the Count parameter for paginating results of large datasets. Default 0 is no offset.
sort String The order for sorting returned data
product_id
Edit_Product
Product_Code
Product_SKU
Number
String
String
String
ID Number of product
Product code string
Product code string
Product SKU string

Response Parameters#

Parameter
Type Description
success Boolean Boolean value indicating if the api request was successful
total_count Number The total number of product variants returned
start_offset Number The number of pages of results. Default 0 is no offset.
offset Number The number of pages of results. Default 0 is no offset.
product_id Number The product id
variant_id Number The id number of variant
option_id_9_1 Number The option id number of the variant
option_code_9_1 String The option id code of the variant
parts Object The product variant parts

Parts Object#

The product variant parts

Parameter
Type Description
offset Number The number of pages of results. Default 0 is no offset.
product_id Number The product id of the variant
product_code String The product code of the variant
product_sku String The product sku of the variant
product_name String Product name of the variant
quantity Number The quantity of the variant

Example Request#

{
    "Store_code": "beta",
    "Function": "ProductVariantList_Load_Query",
    "Count": 39,
    "Filter": "",
    "Offset": 0,
    "Product_ID": 1
}

Example Response#

{
  "success": 1,
  "data": {
    "total_count": 8,
    "start_offset": 0,
    "data": [
      {
        "offset": 0,
        "product_id": 1,
        "variant_id": 4,
        "option_id_9_1": 1,
        "option_code_9_1": "SM",
        "parts": [
          {
            "offset": 0,
            "product_id": 207,
            "product_code": "shirt_SM",
            "product_sku": "",
            "product_name": "Shirt size:SM",
            "quantity": 1
          }
        ]
      },
      ...
    ]
  }
}

Error Responses#

Error Code Error Message Error Description
MER-JSN-PRD-00070 Product not found Product id is not found