PrestaShop: integration guide
This guide describes ChannelEngine's integration with PrestaShop, including how to install and configure it, and more.
Table of contents
Introduction
PrestaShop is an open-source ecommerce platform that enables you to create and customize your webstore. You can integrate ChannelEngine with PrestaShop to automate your product content, offers, orders, and shipments. The integration uses the PrestaShop API entirely, so you do not need to install any code in your local environment.
Features
Supported | Not supported |
Product content | Returns |
Product offers | |
Orders | |
Shipments | |
Cancelations (merchant) | |
Marketplace fulfilment service | |
Variations (size, color) |
Requirements
- PrestaShop v8 and higher
- PrestaShop self-hosted or PrestaShop Cloud
- Access to the PrestaShop back-end
Prerequisites
-
For standalone products, the Merchant product number on ChannelEngine must match either the product ID or the product SKU on PrestaShop.
-
For product variations (a.k.a. combinations), the Merchant product number on ChannelEngine must match either:
-
[product ID]-[product attribute ID]. E.g.: if the product ID is 18 and the ID of the attribute that defines a variation (e.g.: color) is 6, the Merchant product number is 18-6.
-
The product SKU, which must be a unique attribute for each variation.
NB: if you use the product SKU as your Merchant product number, ensure it is configured as the reference field on PrestaShop and is unique.NB: use a consistent approach for Merchant product numbers – either product ID-based or SKU-based. Mixing approaches or switching identifiers after configuration is not possible.
-
Configuration
On PrestaShop
To connect your PrestaShop webstore to ChannelEngine, first enable the PrestaShop webservice, then obtain the required authentication credentials and identifiers. Also, make sure you correctly configure your VAT and country settings on PrestaShop.
Webservice
Enable the webservice to access the PrestaShop API.
- Log in to the PrestaShop back-end.
- From the side menu, go to Settings, Advanced parameters, Webservice.
- Toggle the Enable PrestaShop webservice switch.
Create a webservice key to provide to your ChannelEngine onboarding specialist. The key is the primary authentication method and allows ChannelEngine to call PrestaShop's API.
- On the Webservice page, click Add new webservice key.
- Click Generate to automatically create a new webservice key.
- In the key description, include 'ChannelEngine' to indicate that the key is used to integrate with ChannelEngine.
- Toggle the Enable the status key switch to activate the key.
- Grant ChannelEngine permissions to all available resources by clicking All in each row.
- Click Save.
Provide the webservice key to your ChannelEngine onboarding specialist.
Identifiers
Provide the following information to your ChannelEngine onboarding specialist:
- Default carrier ID - the unique identifier for your default shipping carrier on PrestaShop. You can find this under Settings, Shipping, Carriers. This ID is required to create an order on PrestaShop. You can change the default carrier later when you supply tracking codes.
- New order status ID - the unique identifier for the status assigned to orders. This is the status ChannelEngine uses to import orders with the status New. E.g.: Payment accepted or Processing in progress.
- Processing order status ID - the unique identifier for orders with the Processing status. This ID is required temporarily while the integration between your PrestaShop webstore and ChannelEngine is being configured.
-
Cancelation status ID - the unique identifier for the status assigned to cancelations. This is the status ChannelEngine uses to import cancelations created on PrestaShop.
- Default language ID - the unique identifier for your webstore language. If your webstore supports multiple languages, choose one language to use on ChannelEngine.
- Shop ID - the unique identifier for your webstore on PrestaShop. By default, this value is set to '1'.
VAT settings
To ensure accurate processing, VAT rates on PrestaShop and ChannelEngine must match. E.g.: if a product is subject to 21% VAT, set this rate in both systems so that the cart total matches the order total.
To learn more about how to configure VAT settings on ChannelEngine, check out the article ChannelEngine: VAT settings.
Countries
On PrestaShop, make sure that the countries from which you expect to receive orders are active.
- From the side menu, go to Settings, International, Locations.
- Navigate to the Countries tab, and enable the relevant countries.
- Click Save.
Shipments
Each shipment that you create on PrestaShop must have a carrier and a tracking code assigned to it. Without a tracking code, the shipment cannot be processed or exported to ChannelEngine. Ensure that the tracking code is in its original format (as provided by the carrier) and not a URL. The tracking code must not exceed 50 characters.
On ChannelEngine
To install the PrestaShop integration, contact your onboarding specialist at ChannelEngine. Based on the information that you provide, the onboarding specialist will add, configure, and activate the PrestaShop plugin for you.
FAQs
ChannelEngine cannot authenticate the request to my PrestaShop webservice. What do I do?
By default, PrestaShop blocks access to the webservice for security reasons. Ensure that access is enabled for the webservices you have created on PrestaShop. Otherwise, ChannelEngine cannot connect, and API requests return a '401 Unauthorized' error.
If you are using PrestaShop Cloud, enable the CGIPassAuth On
directive on your webservice. This allows PrestaShop to receive the HTTP_AUTHORIZATION
header. Add the following line to your .htaccess
file:
CGIPassAuth On
If you are using the self-hosted version of PrestaShop, submit a request to PrestaShop to add the following lines to your .htaccess
file.
RewriteCond %{HTTP:Authorization} ^(.*)
RewriteRule .* - [E=HTTP_AUTHORIZATION:%1]
How often does each task run on PrestaShop?
By default, the PrestaShop plugin follows the schedule below.
Task | Frequency |
Import product data from merchant | Every 24 hours |
Import product price from merchant | Every 15 minutes |
Import product stock from merchant | Every 15 minutes |
Export orders to merchant | Every 15 minutes |
Import shipments from merchant | Every 15 minutes |
Comments
0 comments
Article is closed for comments.