Customs Info for Shipments
Provide customs details about your package in your API calls.
About customs and shipments
In international shipping, customs commonly refers to any applicable duties, fees, or taxes charged on items being shipped from one country to another. When shipping internationally, your organization may be required to provide additional customs details about your package.
This document includes example API calls for customs-specific shipping scenarios, including when international document printing is required, when electronic export information (EEI) is not required, when EEI is required, and when you want to pass all customs details for a shipment.
Finally, common definitions associated with customs and international shipping are included.
Carrier-specific requirements
Customs information needed may differ by carrier. Shipium recommends checking specific carrier requirements when shipping internationally. You can find guidance for Shipium-supported carriers with additional customs requirements in the following carrier-specific documentation: Amazon - Ship With Amazon, AMPM, Estafeta, LaserShip, and Paquetexpress.
In addition, UPS recommends including an email address for both the shipper and recipient for international shipments. You can include this information in the shipmentParameters or multiParcelShipmentParameters of your API call as the shipFromAddress.emailAddress and destinationAddress.emailAddress.
Customs items to order item quantity mapping
For certain carriers, accurate customs declaration requires a precise mapping between the individual items declared in your customs information and the corresponding items within each parcel. Shipium facilitates this by connecting the productId values provided in your customsInfo.customsItems with the productId values in your package's orderItemQuantities.
How it works. When you provide customs information for a shipment with the following carriers, Shipium expects that each customsItem will have a productId that matches a productId in one of the orderItemQuantities. This connects each item declared for customs with its corresponding item in your parcel.
Important. If the productId values do not match between your customsInfo.customsItems and your orderItemQuantities, the system will be unable to send complete and accurate customs and item information to the carrier. This may result in:
- Shipment delays
- Customs clearance issues
- Incorrect duties and taxes calculations
- Shipment rejection by the carrier
Carriers requiring this mapping. The following carriers require this explicit productId mapping for customs declarations:
- Amazon - Ship With Amazon
- Cirro
- ECMS
- FlavorCloud
- Reliable Logistics
Action required. When preparing shipments for these carriers, you'll want to ensure that:
- Every item you declare in
customsInfo.customsItemshas a unique and accurateproductId. - Every item listed in your package's
orderItemQuantitiesalso has aproductId. - The
productIdfor each item incustomsInfo.customsItemsprecisely matches theproductIdof its corresponding item inorderItemQuantities.
Example API calls and responses for international shipping customs
Minimum fields required for international, no EEI required for shipment
This is a sample cURL call to the API including the minimum required information for international shipping when an EEI is not required.
{
...
"labelParameters": {...},
"shipmentParameters": {
...,
"shipOption": "InternationalTwoToFiveDay",
"customsInfo": {
"totalCustomsValue": 54.95,
"totalCustomsValueCurrency": "usd",
"customsDescription": "9 mm steel screws",
"reasonForExport": "sale",
"invoiceDate": "2022-06-13",
"customsItems": [
{
"customsValue": 18.31,
"customsValueCurrency": "usd",
"commodityDescription": "9 mm steel screws",
"countryOfManufacture": "US",
"customsWeight": {
"weight": 4,
"weightUnit": "lb"
},
"quantity": 3,
"quantityUnitOfMeasurement": "box",
"harmonizedTariffNumber": "9876543210"
}
]
}
}
}Minimum fields for a shipment that requires an EEI, and EEI is filed through AES Direct
This is a sample cURL call to the API including the minimum required information for international shipping when an EEI is required and it is filed through the Automated Commercial Environment (ACE) AESDirect.
{
...
"labelParameters": {...},
"shipmentParameters": {
...,
"shipOption": "InternationalTwoToFiveDay",
"customsInfo": {
"totalCustomsValue": 54.95,
"totalCustomsValueCurrency": "usd",
"customsDescription": "9 mm steel screws",
"reasonForExport": "sale",
"invoiceDate": "2022-06-13",
"aesInternalTransactionNumber": "X20220613366903",
"customsItems": [
{
"customsValue": 18.31,
"customsValueCurrency": "usd",
"commodityDescription": "9 mm steel screws",
"countryOfManufacture": "US",
"customsWeight": {
"weight": 4,
"weightUnit": "lb"
},
"quantity": 3,
"quantityUnitOfMeasurement": "box",
"harmonizedTariffNumber": "9876543210"
}
]
}
}
}Sample API call with customs information included
This is a sample cURL call to the API including customs information. Importer of record and broker are not included in this sample call; the Broker & Importer of Record document provides details about these optional fields that can be included in your API call. The Tax Identification Number document includes information about the optional tax ID field in the sample call.
{
...
"labelParameters": {...},
"shipmentParameters": {
...,
"shipOption": "InternationalTwoToFiveDay",
"customsInfo": {
"totalCustomsValue": 54.95,
"totalCustomsValueCurrency": "usd",
"customsDescription": "9 mm steel screws",
"reasonForExport": "sale",
"invoiceDate": "2022-06-13",
"invoiceNumber": "123-abc-456",
"europeanUnionInfo": {
"vendorIossNumber": "123456789012"
},
"ultimateConsigneeAddress": {
"name": "Wile E. Coyote",
"phoneNumber": "1112223333",
"emailAddress": "[email protected]",
"street1": "123 Test",
"city": "St. John's",
"state": "NL",
"countryCode": "CA",
"postalCode": "A1A 2H4",
"addressType": "residential"
},
"ultimateConsigneeType": "direct_consumer",
"aesInternalTransactionNumber": "X20220613366903",
"electronicExportInformation": { // Note: not needed if an aesInternalTransactionNumber is provided
"exportDate": "2022-06-15",
"pointOfOrigin": "CO"
},
"b13AFilingOption": "NOT_REQUIRED",
"exportComplianceStatement": "AESX20220714987654",
"permitNumber": "12345",
"incoterm": "ddp",
"declarationStatement": "I declare that the information provided is true and accurate. These commodities are licensed by the United States for export to the destination country",
"taxIdentificationNumber": "12345",
"customsItems": [
{
"customsValue": 18.31,
"customsValueCurrency": "usd",
"commodityDescription": "9 mm steel screws",
"countryOfManufacture": "US",
"customsWeight": {
"weight": 4,
"weightUnit": "lb"
},
"quantity": 3,
"quantityUnitOfMeasurement": "box",
"harmonizedTariffNumber": "9876543210",
"productId": "ABC123",
"commodityPartNumber": "12345",
"marksAndNumbers": "1 of 1",
"electronicExportCommodityInformation": { // Note: not needed if the carrier is not filing an EEI
"exportType": "domestic",
"exportInformationCode": "LC",
"scheduleBInformation": {
"scheduleBNumber": "6404195500",
"scheduleBQuantity": 3,
"scheduleBUnitOfMeasurement": "pack"
},
"eccnNumber": "EAR99",
"exportLicenseInformation": {
"licenseType": "C33",
"licenseExemptionCode": "NLR",
"exportLicense": { // Note: not needed if you have provided a licenseExemptionCode
"licenseNumber": "123ABC",
"licenseLineValue": 1000,
"licenseExpiration": "2025-06-13"
}
}
}
}
]
}
}
}Sample response with customs information included in the API call
This is a sample JSON response from the API when customs information was included in the API call.
{
"carrierSelection": {
....
},
....,
....,
"carrierLabel": {
....,
....,
"documents": [
{
"labelExpiration": "2023-11-19T21:08:54.305Z",
"labelFormat": "zpl",
"labelImage": {
"imageContents": "BASE64LOOKINGSTUFFANDWHATHAVEYOUETCETCETC",
"imageEncoding": "base64"
},
"labelUrl": "https://api.shipium.com/labels/1a486afc-2ffc-4c37-928f-8d6aa014b35b.zpl"
}
],
"internationalDocuments": [
{
"documentType": "commercial_invoice", // "commercial_invoice", "electronic_export_information", "ps_2976", "air_waybill" or "multiple"
"documentExpiration": "2023-11-19T21:08:54.305Z",
"documentFormat": "pdf",
"documentImage": {
"documentEncoding": "base64",
"documentContents": "BASE64LOOKINGSTUFFANDWHATHAVEYOUETCETCETC"
},
"electronicallySubmitted": false
}
]
....,
....,
},
....,
....
}Minimum fields required for U.S. territory, APO, FPO, DPO
Shipium’s guidance is that as much of the following information be provided as possible for a shipment to a U.S. territory or a military region to ensure that the shipment is not returned. While some fields are marked as not required for one carrier and required for another carrier, it is not known which carrier will be chosen during carrier selection. Therefore, it is best to supply enough information for all carriers.
{
...
"labelParameters": {...},
"shipmentParameters": {
...,
"customsInfo": {
"totalCustomsValue": 54.95,
"totalCustomsValueCurrency": "usd",
"reasonForExport": "sale", // not strictly required for USPS
"invoiceDate": "2022-06-13", // required for UPS
"customsItems": [
{
"customsValue": 18.31,
"customsValueCurrency": "usd",
"commodityDescription": "9 mm steel screws",
"countryOfManufacture": "US", // not strictly required for USPS
"customsWeight": {
"weight": 4,
"weightUnit": "lb"
},
"quantity": 3,
"quantityUnitOfMeasurement": "box" // required for UPS
}
]
}
}
}Definitions of API request fields for customs and international shipping
This section includes Shipium descriptions of API request fields common to customs and international shipping. All fields are included within customsInfo in the shipmentParameters (or multiParcelShipmentParameters for multi-parcel shipments) of your call, with the exception of shipOption, which is included at the shipmentParameters (or multiParcelShipmentParameters) level.
Importer of record and broker are not included here; the Broker & Importer of Record document provides details about these optional fields that can be included in your API call. Likewise, the Tax Identification Number document includes information about tax IDs that is not included here.
Ship option
The shipOption field is included in the shipmentParameters of the API call (or in multiParcelShipmentParameters for a multi-parcel shipment). You can find more information about ship options in our Ship Options documentation.
Field | Type | Required? | Description |
|---|---|---|---|
| For international shipments, the ship option should be one of the following values: | Yes | The kind of international shipment performance |
Customs info
The customsInfo fields are included in the shipmentParameters (or in multiParcelShipmentParameters for a multi-parcel shipment) of the API call.
Field | Type | Required | Description |
|---|---|---|---|
| Float | Yes | The total customs value of the package in total customs value currency units |
| String | Yes | The currency to use for the package value in the |
| String | Yes | The detailed description of the items being shipped |
| Values: | Yes | The reason to export an international shipment |
| LocalDate | Yes | Date when the invoice was created; ideally, this is the same as the ship date. |
| String | No | The Commercial Invoice number, if the Commercial Invoice was generated by your organization |
| String | No | An Import One-Stop-Shop (IOSS) number is a 12-digit identification number that is used to pay value added tax (VAT) and declare imports to the European Union (EU). The IOSS number is a type of VAT identification, but it is not the same as a resident VAT registration. |
| String | Conditional (see the address fields that follow) | The address of the person or company who receives the goods for end use; if no value is sent, we will use the destinationAddress |
| String | No | The name associated with the address |
| String | Conditional (some carriers require a phone number) | The phone number of the contact |
| String | No | The country code of the phone number of the contact |
| String | No | The email address of the contact |
| String | No | The company name for the address |
| String | No | The first address line |
| String | No | The second address line |
| String | No | The name of the city for the address |
| String | No | The name of the state for the address |
| String | Yes | The ISO-3166-1 country code for the address |
| String | Yes | A country-appropriate postal code for the address |
| String | No | The type of location for this address |
| String
| Optional, but | The address line components for the address, used for some international shipments. This is an optional object that can be included in |
| String | No | The type of the ultimate consignee, the person or company receiving the shipment; if no value is sent, it will default to |
| String | No | The number received if the Electronic Export Information (EEI) was filed and has been accepted in the Automated Export System (AES) |
| Array of | No | Information for the Electronic Export Information (EEI) customs form, only used when the EEI will be filed directly by the carrier (i.e., not filed by your organization using AESDirect or otherwise) |
| Date-time | No, but required if including EEI | The date the goods will be leaving the country in ISO-8601 format |
| String | No, but required if including EEI | The 2-character state abbreviation from which the goods were shipped |
| String enumeration
| Conditional | Specify the filing option being exercised; this is required for non-document shipments originating in Canada destined for any country other than Canada, the United States, Puerto Rico, or the U.S. Virgin Islands. |
| String | No | For U.S. export shipments requiring an EEI, enter the ITN number received from AES when you filed your shipment or the FTR (Foreign Trade Regulations) exemption number. The proper format for an ITN number is AES XYYYYMMDDNNNNNN where YYYYMMDD is date and NNNNNN are numbers generated by the AES. |
| String | No | This is a permit number. This field is applicable only to Canada export non-document shipments of any value to any destination. No special characters are allowed. |
| String enumeration
| Yes | The incoterm, or international commerce term, defines the delivery duty responsibility for buyers and sellers for any mode of transport; the default value is |
| String | No | A customs declaration statement for the shipment that, if provided, will appear on generated commercial invoices |
| String | No | The employer identification number (EIN) tax identification number of the shipper; you can find more details about this field in Tax Identification Number. |
| Array of | Yes | Contains customs information for each item in the shipment |
Customs items
The customsItems fields are included within customsInfo in the API call.
Field | Type | Required | Description |
|---|---|---|---|
| Float | Yes | The value of each individual item to report to customs in customs value currency |
| String | Yes | The ISO-4217 currency code representing the |
| String | Yes | A description of this product to be provided to customs |
| String | Yes | The ISO-3166-1 country code for the address |
| Float | Yes | The weight of the item to report to customs in units of weight unit |
| String enumeration | Yes | The weight unit |
| Integer | Yes | The number of units of this customs item |
| String enumeration | Yes | The unit of measurement of the item |
| String | Yes | The 6- to 15-digit Harmonized System Tariff classification code |
| String | No | The unique identifier for the product being shipped. This value must match the |
| String | No | The part number or reference number for the product |
| String | No | Any special marks, codes, and numbers that may identify the package |
| Array of | No | Customs item information that is particular to the Electronic Export Information (EEI), only used when the EEI will be filed directly by the carrier (i.e., not filed by the partner using AES Direct or otherwise) |
| String | No, but required if including | The type of the export |
| String | No, but required if including | The 2-character export information code for the commodity |
| Array of | No, but required if including | The Schedule B information for the commodity |
| String | No, but required if including | The 10-digit Schedule B classification code for the item being exported |
| Integer | No, but required if including | The count of how many Schedule B units are in the shipment |
| String | No, but required if including | The unit of measure for the Schedule B quantity |
| String | No, but required if including | The 5-digit product Export Control Classification Number (ECCN) number as issued by the Bureau of Industry and Security; the format is |
| Array of | No, but required if including | The license information for the export |
| String | No, but required if including | The standard license type code as published by the U.S. government |
| String | No | The license exemption code, if the license type does not require a license number |
| Array of exportLicense objects (defined in the following table rows) | No | The export license, if the license type requires a valid license |
| String | No, but required if including | The license number |
| Integer | No, but required if including | The export monetary amount allowed per license |
| Date-time | No, but required if including | The license expiration date in ISO-8601 format |
Resources
Your Shipium team member is available to help along the way. However, you might find these resources helpful:
Updated 7 days ago
