Closed dianaow closed 5 months ago
It is necessary to add a webhook_secret
to the plugins array in medusa-config.js
in the backend.
As quoted from the documentation: "As for the webhook_secret
, it’s essential for your production environment. So, if you’re only using Stripe for development you can skip adding the value for this option at the moment."
I interpreted this to mean that if I were to attempt a checkout and payment flow with a Stripe account in test mode, I wouldn't need to add the webhook_secret
. However, the opposite is true. To get a successful response from any Medusa Store APIs related to payment sessions, shipping methods and cart completion, a webhook_secret
needs to be specified alongside correct public and secret Stripe API keys.
Hey, thanks for the report! Since v2 brought a lot of architectural and API changes on the backend, we will be closing this ticket since it no longer applies to our new setup, or the issue has already been fixed. If you are still facing issues with v1, please open a new ticket and we will address it as soon as possible. Thanks! 🙏
Bug report
Describe the bug
Unable to set a payment session with the provider_id as 'stripe' after creating payment sessions. I'm certain Stripe has already been set up correctly on Medusa backend and admin, with PUBLIC_STRIPE_KEY and PRIVATE_STRIPE_KEY specified in .env file.
System information
Medusa version (including plugins): "1.20.2" Node.js version: v18.18.0
Steps to reproduce the behavior
Error occurs at
medusa.carts.setPaymentSession
Expected behavior
A 200 response with a cart object returned
Screenshots
Medusa Admin Region settings: Stripe is checked
POST request to create a payment session (I see the presence of stripe as a payment provider option)
POST request to set a payment session
Error message
Error: Request failed with status code 404