Context variables
Available context variables in your template
The following variables are available in the template:
Shipment
The shipment (also called order) the template is used for.
Can be accessed via the shipment variable.
Attributes
destinationAddressAddressdestinationCompanyStringdestinationNameStringinvoiceNumberStringshipmentItemslist[ShipmentItem]
Accumulated FieldsFor the total price, you can use the total_price filter.
For the total weight, you can use the total_weight filter.
Shipment Item
Details about the items included in the shipment.
Can be accessed via the shipment.shipmentItems variable.
Attributes
amountIntegercustomsTariffNumberStringpricePriceproductNameStringskuStringweightFloat
FiltersYou can use the format_price filter to format the price.
You can use the format_weight filter to format the weight.
Sender Address
The address of the warehouse from where the shipment will be sent.
Can be accessed via the senderAddress variable
Read Address for more details about the attributes.
Address
Holds address information such as street, house number etc.
Attributes
countryCountrylocalityStringpostalCodeStringthoroughfareStringsubThoroughfareStringsubSubThoroughfareString
Formatting AddressFor street, house number and addition use the
format_streetfilter.
Updated about 1 month ago
