For a customer I need to implement batch tracking on fulfillment of orders.
so when an order is sent to the 3rd party logistics they sent out the articles but the articles can come from a specific production batch.
in order to do this I would like to update the Fulfillment: line-items : properties field and include Batch and quantity in there.
but when i call the api it doesn't seem to be saving the properties field.
I've been testing this out this afternoon. Indeed, the expected is that the properties array would be ignored if tried to be updated post order. Of course when order is created, the line items properties can naturally be set. This would be why they are not 'read only' in the docs right now.
That said, that's a great call out - this point above isn't mentioned in the documentation, and it would help partners immensely to include it. I'll put that in motion.
By way of a different solutions, you may want to try the Fulfillmentevent endpoint(docs). You'd be able to set a value for the "message" which could be any string you desire.
Lastly for only unfulfilled line items it's possible to make use of the Order Edit GraphQL API - further documentation is here. I hope that at least explains some more. Thank you.
Thanks for the feedback. Should I assume then that the line-items on fulfulliment are actually order line-items and not separate records? That is also not clear. when you look at the structure within Shopify it looks as if there are seperate line-items.
if you look at the order information in JSON you see
order level items like id, email m note etc etc
order.line-items fields like id, varian_id title sku quantity
fulfillment fields like id, orderid, status, shipment_status, tracking_company
"title": "product title",
"variant_title": "30 ml",
/// etc etc
I would expect that a fulfillment api would be able to manage the properties of the fulfillment as these line-items are specifically for the fulfillment and seperated from the order line-items.
Hey @danielblank, apologies for the late reply here, I was away.
Yes, so the Fulfillment Resource is used to Manage the Fulfillment of an order's line items, Fulfillment representing a shipment of one or more items in an order. Conceptually, a good reference point would be the relationship shown here for the Fulfillment object, which shows it's relationship with the Or... - the Fulfillment Order object by definition being a group of one or more items to be fulfilled from the same location.
Hope that helps clarify, but please do let me know if you have any questions - thanks!