Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter nois3

    (@nois3)

    Of course I masked the real address as I cannot give anyone access to the backend, but I used example.com for reference. Please contact me if you’re in the plugin dev team

    Saif

    (@babylon1999)

    Hello @nois3,

    Thank you for reaching out!

    When I try to set Stripe credentials it performs two different API calls (GET and POST) that returns 404.

    I understand that you’re having trouble adding your Stripe API keys, correct? Please ensure that you’re not copying the keys with any formatting, such as extra spaces at the beginning or end.

    If you’re using a Mac, you can paste the key with CMD + Shift + V instead of CMD + V to avoid formatting issues. If this doesn’t resolve the issue, please provide a screenshot of the error you’re encountering along with your site’s system status report.

    You can find it via WooCommerce > Status. Select “Get system report” and then “Copy for support” (after you scroll down a bit)”. Once done, please paste it here in your reply or via a text-sharing service like https://gist.github.com.

    Look forward to hearing back from you.

    Thread Starter nois3

    (@nois3)

    So here’s the woocommerce status in a gist.

    It’s not about API Keys formatting, in fact inspecting the network calls in the Dev tools console, I noticed 404 codes on API get and post calls to those two endpoints.

    It’s a matter of REST Base path and Bedrock configuration I guess.

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @nois3

    After reviewing your system status report, everything seems normal except PHP Post Max Size (increase from 64 MB to 2 GB) and PHP Time Limit (increase from 30 to 1200).

    However, from what you’ve described, it looks like there might be a conflict with your Bedrock configuration and the REST Base path. Bedrock modifies the default WordPress directory structure, which might be causing the 404 errors on the API calls.

    One possible workaround could be to modify your .htaccess file to include the new base path. You can try adding the following lines at the top of your .htaccess file:

    RewriteEngine On
    RewriteBase /wp/
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /wp/index.php [L]

    You could also try updating the permalink structure. Go to Settings > Permalinks and simply click “Save Changes”. This can sometimes help refresh the system and resolve any issues related to URLs.

    Let us know how that goes. Looking forward to helping you.

    Thread Starter nois3

    (@nois3)

    Thanks for the effort, but this is not a viable solution. This would mean breaking a 10-years-working platform like bedrock, rather than having this working the correct way.

    Let me clarify: the whole website works great, but we it comes to accessing Stripe via your plugin, something is hardwired rather than rely on .env file CONF, hence this breaks everything.

    I clearly need a better solution, or hint to find one, if you’re able to solve it for everybody.

    Thanks for you understanding.

    Plugin Support Kaushik S. a11n

    (@kaushiksomaiya)

    Hi there @nois3

    In general, if you change the WordPress Address – the Rest API path will throw 404.

    You’d want to go with method 2 described here to ensure WP Json works well: https://www.ads-software.com/documentation/article/giving-wordpress-its-own-directory/

    As an example, I changed the WordPress Address (URL) to /wp/ at the back and followed method 2 described above. I was able to get the Stripe Json calls working:

    https://d.pr/i/6dmcvT
    Let us know if you have any questions!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Woocommerce Gateway installed on Bedrock’ is closed to new replies.