Hello,
I’m trying out API version 2025-07
to update the unitPriceMeasurement
field (which is great, thank you!) but I’m running into an issue with how the data looks in the admin.
If I update unitPriceMeasurement
and there’s no previous unit price set for the variant the following happens:
- The new value displays correctly in the API
- I do not see the new value on the variant detail page
- I do see the new value if I open up the modal to edit the unit price
This makes it confusing for merchants because it seems like the value isn’t set when, according to the API, it is.
If however, I update the unitPriceMeasurement
for a variant that already has had the unit price configured in the admin, the calculated unit price shows up correctly.
I’ve tested this single-variant products and products with multiple variants and I’m seeing the same thing.
Here’s some debug info:
GraphQL variables:
{
"productId": "gid://shopify/Product/10529604895023",
"variants": [
{
"id": "gid://shopify/ProductVariant/51114789503279",
"unitPriceMeasurement": {
"quantityUnit": "G",
"quantityValue": 200.0,
"referenceUnit": "KG",
"referenceValue": 1
}
}
]
}
GraphQL mutation (API version 2025-07
):
mutation productVariantsBulkUpdate(
$productId: ID!
$variants: [ProductVariantsBulkInput!]!
) {
productVariantsBulkUpdate(productId: $productId, variants: $variants) {
product {
id
legacyResourceId
}
productVariants {
id
legacyResourceId
title
price
compareAtPrice
barcode
sku
taxable
taxCode
position
inventoryPolicy
inventoryQuantity
createdAt
updatedAt
}
userErrors {
field
message
}
}
}
x-request-id
9912db34-e5f9-495c-978b-edbfe41961cb-1747930687
Thanks!
Daniel