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
- From your Unified Admin, go to Settings > Shipping Settings > Package Types.
- The list shows all package types for the current store in an AG Grid table.
- Use the Filter dropdown to show All Packages, Packages with order option, or Packages without order option.
- Use the Pricing dropdown to filter by a specific pricing category.
- Use the Search button to find package types by keyword.
- Click Add Package Type to create a new entry.
- Use the overflow menu (three-dot icon) to Export all package types to an Excel spreadsheet or Import from an .xlsx file.
List Columns
| Column | Description |
|---|---|
| Id | Unique identifier for the package type. |
| Pricing category | The pricing category, size, and order option this package type applies to, displayed as Category > Size > Option:Item. |
| Weight | Base weight of the package (empty box weight). |
| Max Weight | Maximum allowable weight for this package configuration. |
| Dimensions | Package dimensions displayed as Length x Width x Height. Blank for Advanced mode packages. |
| Status | Whether the package type is Enabled or Disabled. |
| Action | Edit or Delete the package type. |
Add/Edit a Package Type
- From the Package Types list, click Add Package Type or click Edit on an existing row.
- Fill in the required fields described below.
- Click SAVE to apply changes, or Cancel to discard.
Standard Mode Fields
| Field | Description |
|---|---|
| Pricing | The pricing category this package type applies to. Changing this resets the Size and Order Option selections. Required. |
| Enabled | When checked, this package type is active and used during shipping rate calculation. |
| Advanced | When 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. |
| Size | The pricing size within the selected category. Select "None" if the package type applies regardless of size. |
| Order Option | An order option to further narrow when this package type applies. Select "None" if not applicable. |
| Order Option Item | The specific option item value. Required when an Order Option is selected. |
| Package Type | The 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 Type | How package dimensions are calculated: Default — all dimension fields are required. Roll — Length is calculated automatically and disabled. Sheet/Rigid — Max Height becomes required. |
| Weight | Base weight of the package. Must be less than Max Weight. |
| Max Weight | Maximum weight for the package. For the Package type, max weight cannot exceed 150 lbs (or kilogram equivalent). |
| Height | Package height in the selected dimension unit. |
| Max Height | Maximum height, required only when Calculation Type is Sheet/Rigid. |
| Width | Package width in the selected dimension unit. |
| Length | Package length in the selected dimension unit. Disabled and auto-calculated when Calculation Type is Roll. |
| Weight Unit | Unit of measure for weight fields: Kilogram or Pound. |
| Dimension Unit | Unit 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.
| Field | Description |
|---|---|
| Pricing | The pricing category this package type applies to. Still required in Advanced mode. |
| Enabled | Whether this package type is active. |
| Enable Logging | When 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. |
| Script | JavaScript 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:
| Variable | Type | Description |
|---|---|---|
blankWidth | number | Width of the blank product. |
blankHeight | number | Height of the blank product. |
itemWeight | number | Total weight of the product. |
itemQuantity | integer | Quantity of items ordered. |
thickness | number | Thickness of the item. |
orderOptions | array | JSON array of objects with optionName and optionValue properties. |
parametricStandard | object | Available 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:
| Property | Type | Allowed Values |
|---|---|---|
width | number | Must be greater than 0. |
height | number | Must be greater than 0. |
length | number | Must be greater than 0. |
dimensionUnit | number | 0 = Inches, 1 = Centimeters, 2 = Feet, 3 = Meters, 4 = Millimeters |
weight | number | Must be greater than 0. |
maxWeight | number | Must be greater than 0. |
weightUnit | number | 1 = Kilogram, 2 = Pound |
type | number | 1 = 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:
| Column | Description |
|---|---|
| Id | Run identifier. Click to expand and view full input/output details. |
| Run Date | Date 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
Print Store
| Area | Effect |
|---|---|
| Checkout shipping rates | During 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 shipping | If 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 estimation | Product pages that show estimated shipping use package types to determine dimensions for rate estimation before the customer reaches checkout. |
Related Pages
- 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