Troubleshooting

WooCommerce Pohoda Connector

Batch connector start displays error “curl is not recognized”

Issue: When starting the batch connector on the local or network side of Pohoda, the command line is displayed error “curl is not recognized as an internal or external command”.

Cause: The command line tool cURL is not installed on Windows running a local instance of Pohoda or which has remote access to the Pohoda network. This open software tool ensures data transfer between systems. In the case of our batch connector, it is about sending requests from Pohoda to the API e-shop.

Solution: You can use this procedure to install and activate cURL https://stackoverflow.com/a/16216825.


The log in the plugin displays the error “Failed connect to API. Incorrect credentials.”

Issue: Even if you have entered the correct and identical REST API login data in the configuration of the batch connector and the e-shop plugin (E-shop API login name, E-shop API password), a situation may arise that the synchronization does not proceed correctly and in the logs of the e-shop plugin there is the following error was written:

REQUEST >>> Success connect to API.

REQUEST >>> ERROR: Failed connect to API. Incorrect credentials.

Cause: Verification of login data coming from the batch connector to the e-shop takes place through Basic HTTP authentication. The cause of the given problem may be that Basic HTTP authentication is not enabled on the web hosting of the e-shop, or that this access verification method is explicitly blocked.

Solution: On the web hosting of the e-shop, check whether Basic HTTP authentication is enabled. It can be a setting within the hosting or a necessary entry in the file .htaccess.


The sent request from Pohoda does not arrive in the e-shop

Issue: Even if you have entered the correct and identical REST API login data in the configuration of the batch connector and the e-shop plugin (E-shop API login name, E-shop API password), a situation may arise that the synchronization between Pohoda and the e-shop does not work at all and in there is no record of an incoming request from Pohoda in the logs of the e-shop plugin.

Cause: If the request from Pohoda does not reach the e-shop, while the batch connector does not show any error, the communication between the systems can be blocked either by a restriction on sending the request on the Pohoda side, or by a restriction on receiving the request on the e-shop’s side, or web server.

Solution:

1. On the Pohoda side, check whether running the batch connector is not blocked by the antivirus program. To be sure, enable the batch connector in it, or executable batch files wc.bat and wc-mserver.bat by adding them to exceptions and defining them to be ignored by the antivirus program.

2. On the e-shop side, check the settings of the security plugin that you have installed and active in the e-shop, whether the REST API call is enabled. If enabled, check that REST API request processing is not limited to the IP addresses of the request sender. If you have set a restriction on IP addresses for security reasons, add the IP address of the PC or server from which the batch connector sends requests to the e-shop to the whitelist of IP addresses.

3. Some web hostings with pre-installed WordPress implicitly require active WP functionality “Application Passwords” and thus can block requests coming to the REST API. If this functionality is not deactivated in the e-shop (e.g. via the security plugin), you can use to deactivate it the plugin Disable Application Passwords, or simply add this filter hook to the file functions.php in your e-shop template:

add_filter( 'wp_is_application_passwords_available', '__return_false' );

4. In case you don’t want or can’t globally disable “Application Passwords” in the e-shop, you need to create a WP user for REST API. The “Application Passwords” function will generate a password for you, which must be entered both in the settings of our plugin on the e-shop side as login API data, and on the other hand in our Pohoda batch connector on the Pohoda side in the file wc-config.cmd.

Example:

Create a WP user with any role in the e-shop administration. Give him a username, e.g. pohodaapiuser, the e-mail may be fake. After creating and saving the WP user, the Application Passwords section will appear, where in the field New App Password Name, enter the login name, in our example pohodaapiuser:

After clicking the button Add new application password, the system will generate a password and assign it to the user pohodaapiuser:

Enter the username and password in the settings of our plugin as API credentials:

Enter the username and password in the configuration file wc-config.cmd in our Pohoda batch connector:


Pohoda mServer running nonstop stops communicating

Issue: If you use a solution via Pohoda mServer for synchronization between the e-shop and Pohoda, during its non-stop running it may get stuck, ie. mServer will stop communicating with our batch connector and Pohoda and it is necessary to restart it. A similar problem can occur if the Pohoda computer or server restarts and forgets to restart Pohoda mServer.

Cause: The most common cause of mServer crashes is its continuous operation, and Stormware, as the creator of Pohoda, does not recommend that mServer be run non-stop.

Solution: Our batch connector allows you to set Pohoda mServer to activate (start) only if the connector needs it to connect to Pohoda (“on demand”). In practice, this means that Pohoda mServer is not run non-stop, but only at the moment when data is exchanged between the batch connector and Pohoda. When the batch connector is started, the mServer turns on, when the batch connector runs, the mServer automatically shuts down. For this method of communication, simply enter the name mServer in the attribute “pohoda_mserver_name” in the “wc-config.cmd” configuration file in our batch connector.


PDF invoices from Pohoda are not downloaded to the e-shop

Issue: When synchronizing invoices, the e-shop displays the invoice numbers generated in Pohoda, but it is not possible to display them or send them to e-shop customers.

Cause: In order for invoices to be displayed in the e-shop, or so that they can be automatically sent by e-shop to customers, the plugin needs to have defined which printable invoice report to download from Pohoda.

Solution: In the plugin settings, on the “Invoices” tab, enter the value of the print report ID from the Pohoda you want to catch in the “Invoice print report” attribute. You can find the value of ID in Pohoda – you will open the Invoices agenda, in the top menu click on File > Print reports, select a print report and right-click to display Report Properties, where you will see the report ID value. The default report ID for issued invoices is 190.


Created invoices do not have the correct number range

Issue: Created invoices from e-shop orders do not have the correct number range in Pohoda, or invoices in Pohoda are not created at all.

Cause: The most common cause of the problem is an incorrectly entered number range prefix in the plugin. If this prefix is ​​not specified in the plugin, resp. is empty (tab “Invoices”, attribute “Prefix of numerical series of invoices”), Pohoda generates invoices according to the basic number series. But if you have created your own number range for invoices from the e-shop in Pohoda, you need to enter its prefix in the plugin.

Solution: In Pohoda, view a list of all number series – in the top menu, open the Settings > Lists > Number boards. The Prefix column shows the prefix and copy the prefix from the given invoice number series and paste it into the “Invoice of the invoice series prefix” attribute in the plugin.


Created invoices do not have the correct primary accounting

Issue: Created invoices from e-shop orders do not have the primary accounting correctly assigned in Pohoda.

Cause: In the plugin settings, in the “Invoices” tab, in the “Pre-invoice for invoices” attribute, the value of the primary accounting shortcut is not entered at all, or an incorrect value is entered.

Solution: In Pohoda, you will see a list of all primary accountings – in the top menu, open the Accounting > Primary accountings. The Shortcut column shows the shortcuts for primary accountings, and copy and paste the shortcut from the given primary accounting of issued invoices into the “Accounting for invoices” attribute in the plugin.


If you have not found a solution to your problem, please contact us via the form


    Cookie settings
    WooConn.sk logo

    This website uses cookies so that we can provide you with the best possible experience with the use of our website. We store the information in cookies stored in your browser and thanks to them we know what interests you the most and thanks to that we can create such content that you may be interested in.

    Necessary cookies

    these cookies are used to ensure the operation of this website

    Statistical cookies

    these cookies are used to anonymously obtain information about traffic to this website