To automatically pull commodity information (like HS Codes, Country of Origin, Composition) from your WooCommerce products into Shiptheory for international shipments, follow these steps:


1. Configure Commodity Fields in Shiptheory Settings

First, tell Shiptheory where to find the commodity data in WooCommerce. This usually involves mapping WooCommerce field/attribute names to Shiptheory's commodity fields.

  • Navigate to your WooCommerce integration settings within Shiptheory (usually under Carriers & Integrations > WooCommerce > Advanced Settings).
  • Locate the section for Commodity Data or International Shipping Fields.
  • Enter the exact names of the WooCommerce Product Attributes or Metafields where you store your HS Code, Country of Origin, and Composition data. Consistency in naming is crucial.
  • Save your Shiptheory settings.

Shiptheory WooCommerce settings for commodity fields


2. Add and Populate Attributes on WooCommerce Products

Next, ensure the corresponding attributes exist and contain the correct information on your products within WooCommerce.

  1. Log in to your WordPress Admin and navigate to the product you wish to edit.
  2. Scroll down to the 'Product data' section and select the Attributes tab.
  3. Click Add new to create a new attribute if it doesn't exist yet.
  4. In the 'Name' field, enter the attribute name. *Important* This name must match exactly what you entered in the Shiptheory settings in Step 1 (e.g., `HS_Code`, `Country_of_Origin`, `Composition`).
  5. In the 'Value(s)' field, enter the specific commodity information for that product (e.g., `610910` for HS Code, `CN` for Country of Origin, `100% Cotton` for Composition).
  6. Click Save attributes.

WooCommerce product attributes section


3. Verify Information in Shiptheory

Once set up, Shiptheory will pull this attribute data when new orders containing these products are downloaded from WooCommerce.

  • Check a new order containing the updated product in Shiptheory. View the shipment details and look under the 'Shipment Products' section to confirm the information has been imported correctly.
  • To test changes on an existing order: If you updated a product *after* the order was already in Shiptheory, you can force a refresh. Find the relevant shipment on the dashboard, right-click it, and select 'Retry Shipment'. This action re-downloads the order data from WooCommerce, including the latest product attributes.

Shiptheory shipment details showing product commodity information


If the commodity information isn't pulling through correctly after following these steps, or if you have further questions, please feel free to contact our support team. You can call us on 0117 403 4313 (UK) / +1 (629) 666-6726 (US) or reach us online here.