In today’s e-commerce environment, shipping processes must provide flawless solutions to meet customer demands and maintain operational efficiency. Magento is a powerful and popular e-commerce platform. If you have an e-commerce store operating on Magento, it is necessary to work with a shipping carrier supported by the platform.
DHL provides worldwide service with its reliable global logistics network. DHL offers shipping services that appeal to both local and international customers. In this way, e-commerce businesses that aim to expand can have easier processes. Using Magento DHL integration, you can simplify processes such as managing shipments, tracking orders, and ensuring on-time delivery, especially for international markets.
Set Up Magento 2 #
The Magento 2 platform provides businesses with customization, flexibility, and reliability to set up their online store, enabling them to run e-commerce successfully. With this integration, you can use features such as reflecting DHL express prices, creating shipping labels, and obtaining tracking information.
Before starting with the DHL integration, you need to make sure that Magento 2 is installed. This step provides a foundation where you can install plugins, set customization options, and perform shipping integrations. To install Magento 2, you should first check the server requirements.
1. Set Up Access for DHL Express Commerce to Magento2 #
There are two different methods to integrate DHL Magento 2 integration. The first of these is the Token authentication method. The integration steps with this method are as follows:
- To integrate DHL Express Commerce into your store, you must first log on to the Magento 2 admin page.
- Click on the System item at the bottom left of this panel and click on Add-ons and Integrations.
- Then click on Add New Integration. Then in the opened tab, type DHL in the Name field, enter your administrator password, and leave the other fields blank.
- Then go to the API tab, click on the Source Access menu, click on the All sign in the opened menu, and save.
- In this step, you will be redirected to the Integration tab. Click on the Allow button on the page that appears here, enter the Access Token in the dialog box that appears, and click on the Done button.
Businesses that do not use the Token Authentication method can choose the User Authentication method. The steps of this method are as follows:
- Enter the Magento admin dashboard and select the System item.
- Then enter the Permissions tab and click the Select User Role button to add a new user role. The role name should be integration, then select the role resources select the All option from the menu that opens and click save.
- Then assign the role to your new user and select the System item from the panel. Select all users in the Permissions tab and click the Add New User option.
- Save your username and information from this area and click the User Role tab.
- Then select the previously created integration role and click the Save User button.
2. Enter Your Magento 2 Details #
In order to integrate DHL Magento 2 integration with your store correctly, you need to enter the store details into the system. To do this:
- First of all, you need to log in to DHL Express Commerce, go to the Settings tab, and select Integrations.
- In this tab, click on Add a New Integration and select Magento 2.
- Then select Authentication Method and click on the Enable Magento 2 button.
- Then enter your website URL and enter the Access Token/Username.
- Finally, select the Import status and test it, then click on the Save button.
Troubleshooting #
You may encounter many problems during Magento 2 DHL integration. For example, if you encounter an issue like Error: ‘The Consumer isn’t authorized to access %resources%’, the first thing you need to do is to make adjustments from the store settings. To fix such an error, you should first enter the Stores tab. Then, click on the Configuration item and select the Services option. In this area, you will see the OAuth option. After selecting this option, you must enter the Consumer Settings tab. Finally, you should click on the Allow button so that the OAuth Access token can be used as an independent carrier. After making these adjustments, this error will be resolved, and the same error will not occur on your website again.
Additional Configuration #
After completing the Magento 2 DHL integration, there are additional settings left to make. One of these configurations is the ‘HS Codes and Manufacturer Country Import’ settings. The special attribute code is imported for each country.
Then, the import status must be determined, and the delivery information must be created. When making adjustments to the import status, multiple values can be given by separating each status with a semicolon. Additionally, you must enable this item yourself, as the Magento 2 platform does not import DHL Express Commerce packages.
Finally, you must configure settings such as defining a user agent, configuring different addresses, and importing the single order feature.