This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
This topic contains 2 replies, has 2 voices.
Last updated by edlefW-2 1 year, 7 months ago.
Assisted by: Bobby.
Author | Posts |
---|---|
September 20, 2023 at 4:15 pm #14432311 | |
edlefW-2 |
I am currently trying to register WPML on my freshly installed test site but receive "Unable to parse data from service response." due to a 403 reply from api.wpml.org Temporarily i also disabled Firewall/ModSecurity on the server, but didn't help. PHP and WP max memory values are both set to 256MB, libxml and mbstrings is activated. Also tried to remove the site from WPML and re add it, but did not help. Not sure what else i should try. Looked through this forum but couldn't find any working solution. Would be great if someone could check 🙂 |
September 20, 2023 at 10:36 pm #14433745 | |
Bobby WPML Supporter since 04/2015
Languages: English (English ) Timezone: America/Los_Angeles (GMT-07:00) |
Hi there, Typically this would mean that your server is not allowing WPML to communicate with the site. Removing the firewall temporarily is a good first step. Please ensure to whitelist the IPs from the following URLs hidden link Additionally, if you are possibly on AWS and using a load balancer make sure to review the configuration as the IP could be blacklisted . |
September 21, 2023 at 12:00 pm #14438389 | |
edlefW-2 |
Hi Bobby, thanks for your reply. As said, there is nothing blocking traffic on my site. A curl request via WP-CLI's eval like this worked just fine: ``` Resulted with a correct answer like this - no 403: ``` But running nearly the same via wp_remote_post() returns in error 403. --------- After fumbling around i finally could solve it: wp_remote_post() does not include any User-agent wheras curl() does per default. So the quite simple solution - no firewall settings or whatever - is: ``` The user-agent string can be whatever you like. It also worked with "something" or curl's default "curl/7.74.0". --------- Remaining question: Where does the user agent get lost in wordpress' codebase |