PrintNowPrintNowDocs

Package Types

Define how products are boxed for shipping by mapping pricing categories to package dimensions, weights, and calculation rules.

Package Types control how PrintNow determines the physical package used when calculating shipping rates at checkout. Each package type links a pricing category (and optionally a size and order option) to a set of dimensions, weight limits, and a packaging strategy. When a customer checks out, the system looks up the matching package type for each line item and uses it to request rates from configured shipping carriers (FedEx, UPS, ShipEngine, etc.).

For products with complex or variable packaging needs, Advanced mode lets you write a JavaScript script that dynamically computes package dimensions at runtime based on the ordered item's properties.

View Package Types

  1. From your Unified Admin, go to Settings > Shipping Settings > Package Types.
  2. The list shows all package types for the current store in an AG Grid table.
  3. Use the Filter dropdown to show All Packages, Packages with order option, or Packages without order option.
  4. Use the Pricing dropdown to filter by a specific pricing category.
  5. Use the Search button to find package types by keyword.
  6. Click Add Package Type to create a new entry.
  7. Use the overflow menu (three-dot icon) to Export all package types to an Excel spreadsheet or Import from an .xlsx file.

List Columns

ColumnDescription
IdUnique identifier for the package type.
Pricing categoryThe pricing category, size, and order option this package type applies to, displayed as Category > Size > Option:Item.
WeightBase weight of the package (empty box weight).
Max WeightMaximum allowable weight for this package configuration.
DimensionsPackage dimensions displayed as Length x Width x Height. Blank for Advanced mode packages.
StatusWhether the package type is Enabled or Disabled.
ActionEdit or Delete the package type.

Add/Edit a Package Type

  1. From the Package Types list, click Add Package Type or click Edit on an existing row.
  2. Fill in the required fields described below.
  3. Click SAVE to apply changes, or Cancel to discard.

Standard Mode Fields

FieldDescription
PricingThe pricing category this package type applies to. Changing this resets the Size and Order Option selections. Required.
EnabledWhen checked, this package type is active and used during shipping rate calculation.
AdvancedWhen checked, switches to Advanced mode where a JavaScript script computes dimensions dynamically. All standard dimension/weight fields are hidden and replaced by a code editor.
SizeThe pricing size within the selected category. Select "None" if the package type applies regardless of size.
Order OptionAn order option to further narrow when this package type applies. Select "None" if not applicable.
Order Option ItemThe specific option item value. Required when an Order Option is selected.
Package TypeThe container type: Package (standard parcel), Pallet, or Skid. Pallet and Skid options appear only when the LTL Shipping feature is enabled. When set to Pallet or Skid, freight carrier rates are fetched instead of standard parcel rates.
Calculation TypeHow package dimensions are calculated:
Default — all dimension fields are required.
Roll — Length is calculated automatically and disabled.
Sheet/Rigid — Max Height becomes required.
WeightBase weight of the package. Must be less than Max Weight.
Max WeightMaximum weight for the package. For the Package type, max weight cannot exceed 150 lbs (or kilogram equivalent).
HeightPackage height in the selected dimension unit.
Max HeightMaximum height, required only when Calculation Type is Sheet/Rigid.
WidthPackage width in the selected dimension unit.
LengthPackage length in the selected dimension unit. Disabled and auto-calculated when Calculation Type is Roll.
Weight UnitUnit of measure for weight fields: Kilogram or Pound.
Dimension UnitUnit of measure for dimension fields: Inches, Feet, Millimeters, Centimeters, or Meters.

Advanced Mode

When Advanced is checked, all standard dimension and weight fields are replaced by a JavaScript code editor. In this mode you write a script that receives order item properties as input variables and must return an output object defining the package dimensions.

FieldDescription
PricingThe pricing category this package type applies to. Still required in Advanced mode.
EnabledWhether this package type is active.
Enable LoggingWhen checked, every script execution (including test runs) is recorded with input/output data and execution time. View logs in the Run History section below the editor.
ScriptJavaScript code editor (Monaco). Write logic that computes package dimensions. The script has a 3-second execution timeout.

Script Input Variables

The following variables are available inside your script:

VariableTypeDescription
blankWidthnumberWidth of the blank product.
blankHeightnumberHeight of the blank product.
itemWeightnumberTotal weight of the product.
itemQuantityintegerQuantity of items ordered.
thicknessnumberThickness of the item.
orderOptionsarrayJSON array of objects with optionName and optionValue properties.
parametricStandardobjectAvailable when the pricing category uses Parametric Standard. Access parameters by name (case-sensitive), e.g. parametricStandard.Height.

Script Output Object

Your script must define a variable named output with this structure:

PropertyTypeAllowed Values
widthnumberMust be greater than 0.
heightnumberMust be greater than 0.
lengthnumberMust be greater than 0.
dimensionUnitnumber0 = Inches, 1 = Centimeters, 2 = Feet, 3 = Meters, 4 = Millimeters
weightnumberMust be greater than 0.
maxWeightnumberMust be greater than 0.
weightUnitnumber1 = Kilogram, 2 = Pound
typenumber1 = Package, 2 = Pallet, 3 = Skid

Testing Scripts

Click the Test button below the code editor to open a test panel. Enter sample values for all input variables and click Submit. The output object is displayed along with any validation errors. If Enable Logging is on, test runs are recorded in the Run History grid.

Run History

When a package type uses Advanced mode with Enable Logging turned on, the Run History section appears below the code editor. It shows a grid of past script executions with:

ColumnDescription
IdRun identifier. Click to expand and view full input/output details.
Run DateDate and time the script was executed.

Expanding a row shows the full JSON input and output side by side, along with the execution time in seconds.

Import and Export

Package types can be bulk-managed via Excel spreadsheets:

  • Export — Click the overflow menu (three-dot icon) and select Export to download all package types as an .xlsx file.
  • Import — Click the overflow menu and select Import. Upload an .xlsx file in the expected format. Only .xlsx files are accepted.

Associations

AreaEffect
Checkout shipping ratesDuring checkout, the shipping rate engine looks up the package type matching each line item's pricing category, size, and order options. The resolved package dimensions and weight are sent to configured carriers (FedEx, UPS, ShipEngine) to calculate live shipping rates.
Freight vs. parcel shippingIf any item resolves to a Pallet or Skid package type, the system requests freight rates from LTL carriers instead of standard parcel rates.
Shipping rate estimationProduct pages that show estimated shipping use package types to determine dimensions for rate estimation before the customer reaches checkout.
  • Shipping Methods — configure carriers that use package dimensions for rate calculations
  • Shipping Locations — define ship-from addresses paired with package data for rate requests
  • Pricing — package types are linked to pricing categories for product matching

On this page