api returning empty sku for certain line_items

jamestan
Not applicable
2 0 0

using api, we called:

https://hidden:hiden@kbright-sg.myshopify.com/admin/orders.json to retrieve orders 

 

and we found many orders that return line_items.sku empty string.

but other orders works fine. when we check the sku in the product page, its the sku exists

 

"id" : 1096474624035,
"id" : 1096474624035,
"id" : 1096474624035,
"id" : 1096474624035,
"id" : 1096474624035,
"id" : 1096474624035,
"id" : 1096383070243,
"id" : 1096383070243,
"id" : 1096383070243,
"id" : 1096383070243
"id" : 1096379203619,
"id" : 1096379203619,
"id" : 1096378974243,
"id" : 1096378974243,
"id" : 1096378974243,
"id" : 1096259207203,
"id" : 1096259207203,
"id" : 1095272398883,
"id" : 1095272398883,
"id" : 1095272398883,
 
any reason for this to happen?
Replies 2 (2)
Busfox
Shopify Staff (Retired)
Shopify Staff (Retired)
628 49 111

Hi @jamestan,

 

An order's line item is a snapshot of the variant as it was at the time of purchase. If there's no SKU value on a line item, it meant the associated variant had no SKU at the time of purchase.

 

Hope that helps!

To learn more visit the Shopify Help Center or the Community Blog.

jamestan
Not applicable
2 0 0

hi thank you for clarification , i suspect it too