Order data does not include line item's "Barcode" field

MobWeb
Shopify Partner
12 1 6

I noticed that the order data as returned by the API (http://docs.shopify.com/api/order#show) does NOT include the "Barcode" field that can be set for each product variant. It does however include the variant's SKU, which is placed right next to the "Barcode" field in the shop's admin panel.

My question is: Was this left out intentionally? If so, will I have to pull the variant data manually to get this "Barcode", or is there another way? Ideally it should come bundled with the rest of the order data I think.

Thanks!

the_program
Shopify Partner
2 0 0

Bump. This is pretty crucial - SKUs might not always be unique enough, and not having Barcode/UPC adds an extra layer of difficulty in interfacing Shopify API with other APIs

0 Likes
HunkyBill
Shopify Expert
4372 36 467

I have been pulling it from the Variant which is an extra API call but hardly qualifies as making things difficult to communicate with other API's. So what if you have to make a call to get it? You are not processing the order in real-time anyway and an API call per variant is cheap all things considered. At what point to you draw the line about how much info a line item contains about a variant?

I wish it was included myself as I once considered including barcode in all my reporting too... but have since decided that since it slows things down... screw it.

Talking about crucial, while you may consider barcode crucial, for me it is the fact that line items do not report the discount applied to them. That makes accounting nightmares... 

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
the_program
Shopify Partner
2 0 0

Well, I guess that's another nightmare I'll encounter while on this integration quest :) Am currently considering just storing a cache of variants with redis or some such.

0 Likes
HunkyBill
Shopify Expert
4372 36 467

Been there.. done that. Variants are pretty low-level to deal with and do introduce "issues". The main problem with a cache on Redis is keeping it from getting stale. Every single time a merchant so much as touches a variant for anything, you will receive a webhook in your App and you'll have to decide what to do with your cache... and therein lies some serious pain.... 

 

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
0 Likes
dattelpalme
Excursionist
13 0 9

No product type and not barcode type :-(

0 Likes