Connect Qapla’ to Magento

In order to connect Qapla’ to your Magento, the following steps have to followed:

1. Create a Role

From  Magento Administration Panel please select: System/ WebServices / SOAP/XML-RPC – Roles


Click on «Add New Role» and name it “All”

Click on «Role Resources»,select “All” and then click on “Save Role”.

2. Create a User

Once a new Role is created, a User has to be created as well. From Magento Administration Panel select: System / Web Services / SOAP/XML-RPC – Users.

Click on “Add New User” and fill in as follows using as API Key the string found on Qapla’ under: Channels > [Channel Name] > Configure >  Channel.

N.B. The user name MUST be “qapla” without any apostrophes.
Click on “Save User”.

 

3. Add the User to the Role

Click on “User Role”, select “All” and then click on “Save User”.

 

4. Check WS-I Compliance

Select: System / Configuration / Magento Core API.

 

Check that

  • WS-I Compliance = No
  • Set up Enable Cache WSDL = Yes

Click on “Save Configuration”.

 

5. Minimum reading permissions

In case of safety issues, here you can find the minimum reading permissions that Qapla’ needs to integrate with Magento.

6. Minimum writing permissions

In case of safety issues, here you can find the minimum writing permissions that Qapla’ needs to integrate with Magento.

7. Enter the data in Qapla’

On Magento, the configuration is complete.

Go to Settings > Channels > [Channel Name] > Configure > E-Commerce, select the platform, and enter the Username and Store ID from Magento.

After entering the data, click “Save and Run Test.”

8. Activating order import

To enable order import, go to: Settings > Channels > [Channel Name] > Configure > Imports > Orders
Select the desired import mode:

  • Automatic: Qapla’ will query your platform every hour (at .00, e.g. 9:00, 10:00, 11:00, etc.) to import new orders and update the existing ones.
  • Manual: you can start the import at any time from the Labels section, selecting Magento and clicking Manual Import.

Excluded statuses from import
You can exclude specific order statuses (in addition to the default ones) from import, customizing the flow based on your operational needs.

Advanced Settings
Within “Imports > Orders” you can enable the following options:

  • Import product images
  • Import weight

Courier pre-assignment
You can automatically import the courier chosen at checkout on Magento. However, for Magento this setup requires special attention, as the platform does not return structured courier codes via web service.
Unlike other platforms (e.g., PrestaShop), Magento does not provide a unique courier identifier via API, but transmits two generic text fields:

  • “shipping_method”, example: tablerate_bestway
  • “shipping_description”, example: Express Courier

The “shipping_description” field is the description visible to the customer at checkout and is not a unique code, but a simple string. This value may change over time, depending on the merchant’s configuration in Magento.
Multiple shipping methods (shipping_method) can correspond to different couriers, and it is not always possible to determine with certainty which courier was actually selected.

Since these are free-text fields, interpreting the correct courier requires a specific mapping.
To correctly configure this feature:

  1. Analyze some real orders on your Magento platform (you can use WS Test) to verify the values in the “shipping_description” field.

  2. Based on what you find, enter the strings in the Transcoding Code field within the courier configuration. If you want to associate multiple strings, enter them separated by commas, without spaces. Example: “Express Courier,Standard Shipping,GLS Courier”

  3. Write to support@qapla.it to complete the configuration, sending the channel name, all the codes, and the courier to associate them with.

On the next import, orders will be associated with the correct courier.
It is recommended to verify the actual import and correct courier assignment on one or more orders after saving the configuration, to ensure the mapping is correct.

Set default weight
Set a default weight to apply to imported orders.

Set default number of parcels
Define a default number of parcels for each imported order.

9. Order update on Magento

To enable automatic updates on Magento, go to: Settings > Channels > [Channel Name] > Configure > Updates > E-commerce
Enable the available update options:

  • Complete
    • Set the order to “Complete” when the shipment has been dispatched.
    • Set the order to “Complete” when the shipment has been picked up by the courier.
    • Set the order to “Complete” when the shipment has been delivered.
  • Tracking number: Update shipments on Magento by entering the Tracking Number.

10. Activating shipment import

To enable shipment import, go to: Settings > Channels > [Channel Name] > Configure > Imports > Shipments > Connectors > Magento Connector > Set Connector.
In this section, set the time when Qapla’ will import shipments from Magento.

  • You can configure up to two times per channel.
  • If you want to set more than two times, contact our Customer Care at support@qapla.it.

The import will run automatically at the configured times.

Not working?

Qapla’ uses Magento’s Official API (Web Services).

These services are pre-installed and working in all correctly configured Magento installations up to 1.9.X.

If it doesn’t work, we recommend requesting a check from the manager who maintains the Magento site.

For SOAP to work within the Magento application, the PHP SOAP extension (“soap.so”) needs to be installed on the server. For RPM-based Linux distributions this is normally installed with the command “yum install php-soap”. Note that the PHP SOAP extension is not the same thing as the PEAR SOAP extension

Warning: version 1.9.3.0
A known bug affects this version.
The fix is available at the indicated address.

Auto test script
Available at the following link, a script that uses Magento’s Official Web Services, useful for internal tests:
https://github.com/qapla-it/php-check-Magento-Web-Service

Troubleshooting

Error Description Solution
401 Unauthorized Qapla’ is not authorized to access The provided key is incorrect or was not authorized by following the procedure above.
403 Forbidden The server blocks access to Qapla’ Check that no security strategies (firewall) are active and ensure Qapla’ IPs are authorized. To request the full and updated list of IPs, contact our support at support@qapla.it.
404 Not Found The URL or endpoint being accessed does not exist Verify the correctness of the site URL and confirm the site is indeed a Magento instance.
500 Internal Server Error Internal server error Check the cause on your server.
Bad HTTP response The site is unreachable The site URL is incorrect, offline, or no longer exists.
301 Moved Permanently The site URL redirects to another Enter the correct site URL.
302 Found The site URL redirects to another Enter the correct site URL.
Could not resolve host: www.xxx.xx The URL does not exist Enter the correct site URL.
OpenSSL SSL_connect: Connection reset by peer in connection to www.xxx.xx:443 Site certificate issues Check the site’s HTTPS certificate.

In general, connections to servers respond with HTTP error codes.

Magento modules
The Module currently does not provide support.
It is recommended to use Magento’s official Web Services.