That is available in inventory export
For automation you can script a solution using usemechanic to export custom CSV’s; useful if you have some complicated system or business logic you need to apply to get specific sets of codes or do validation. https://tasks.mechanic.dev/?q=export
Contact me with detail for pricing this type of solution.
Or you can use spreadsheet apps matrixfy or ez-exporter
https://matrixify.app/tutorials/update-shopify-product-hs-code-and-country-of-origin-in-bulk/