Hi there! 
When we print packing slips we would like it to show the available quantity for each line item. Is it possible? It would be helpful when someone is picking they can see how many we have on hand at the time.
Already checked Shopify’s official documentation and didn’t find anything regarding how to display the total inventory. Only found ‘line_item.quantity,’ and for a moment I got excited, but then I realized that only shows the quantity purchased by the customer. 
Thx in advance! 
That info is generally provide on pick lists , at least for larger warehouses.
Generally not a great idea to put internal business data on on packing slips that can end up getting shipped to customers.
For a line_item you want to go to it’s variants object
{{ line_tem.variant.inventory_quantity }}
https://shopify.dev/docs/api/liquid/objects/variant#variant-inventory_quantity
If whatever system is being used can output line-item-properties(LIPs) you could try creating hidden line-item-properties on those line_items with some automation reading inventory info.
As generally you don’t want to use theme product>cart LIP’s passed through checkout to expose your inventories on the frontend of the website in the html.
Or try piping the info into any note feature it one exists for your packing slips.
Also be aware of multi-location so “total” inventory can be misleading vs “total onhand inventory” “local inventory” etc.
Hello! If there’s still someone looking for this and you found this post on Google, I was able to solve it already. I just used the following code:
{% assign inventory_quantity = nil %}
{% for item in order.line_items %}
{% if item.sku == line_item.sku %}
{% assign inventory_quantity = item.variant.inventory_quantity %}
{% endif %}
{% endfor %}
{% if inventory_quantity %}
STOCK: {{ inventory_quantity }}
{% endif %}
the only problem with this solution is that it shows Available quantity. not On Hand quantity… so if you have 30 items on hand. but 29 of them are sold to this customer then the packing slip will return a value of 1. which is 28 short of what would be needed to fill the order. Do you know if there is a “item.variant.inventory_quantity” that is specific to On Hand rather then Available?