Skip to main content

Update variant values

Use the Update variant options mutation to update a variant value for an option or to add another variant value.

EXAMPLE--Use this mutation to update hex code for Gold from #FFD701 to #FFD700

Mutation

mutation updateProductVariantOptionValue($input: UpdateProductVariantOptionValueInput!) {
updateProductVariantOptionValue(input: $input) {
product {
addon
allowMultiplePurchases
defaultVariant {
configuration {
code
hexcode
name {
locale
value
}
}
edition {
code
id
inventory {
editionCode
id
sku
}
}
id
}
}
userErrors
}
}

Was this page helpful?