Variants implement the Line item products interface.
Associated query | Returns multiple results |
---|
Variant | |
Variants | ✔️ |
Label | Type | Notes | Null |
---|
attributes | Attributes | The variant's attributes ("Blue", "1,32 meters", "Plastic", ... ) | |
barcode | string | This variant's barcode | ✔️ |
changed | Date | The date of the variant's last modification | |
created | Date | The date of the variant's creation | |
default_component_discount | decimal (10,2) | The discount applied to it's components (if it has any) | |
id | integer | The id of this variant | |
initial_cost | decimal(12,4) | The initial cost of this variant | |
is_assembly | boolean | Indicates if this variants is an assembly of other variants | |
is_component | boolean | Indicates if this variants is a components of a kit or assembly | |
is_kit | boolean | Indicates if this variant is a kit | |
label | string | The name of this variant | |
moving_average_cost | decimal(12,4) | The average moving cost of this variant | |
packs | Packs | The packs including this variant | ✔️ |
prices | Prices | The prices used for this variant | ✔️ |
product | Product | The product this variant's is associated with | |
sku | string | The sku of this variant | ✔️ |
stock_levels | Stock levels | The stock levels of this variant | |
supplier_sku | string | The sku of this variant's supplier | ✔️ |
track_inventory | boolean | Indicates if we should track the inventory of this variant | |
user | User | The user who created this variant | |
weight_amount | decimal(10,2) | The weight of this variant | ✔️ |
weight_unit | string | The unit used to weigh this variant | ✔️ |
{
"codes": [
{
"code": "query{\n Variants{\n edges{\n node{\n attributes{\n edges{\n node{\n label\n }\n }\n }\n barcode\n changed\n created\n default_component_discount\n id\n initial_cost\n is_assembly\n is_component\n is_kit\n label\n moving_average_cost\n packs{\n edges{\n node{\n id\n }\n }\n }\n prices{\n edges{\n node{\n id\n }\n }\n }\n product{\n id\n }\n sku\n stock_levels{\n edges{\n node{\n id\n }\n }\n }\n supplier_sku\n track_inventory\n user{\n display_name\n }\n weight_amount\n weight_unit\n }\n }\n }\n}\n",
"language": "json"
}
]
}