Subscription remain pending after Stripe payment

More
8 months 1 week ago #160225 by Peter
Hello!

I am struggling to figure out why subscriptions remain pending after payment. I am using Stripe Checkout in test mode. The payment goes through from what I can see, but still, I must manually activate the plan in the Subscription History (for each subscriber). What am I doing wrong? Any help would be very much appreciated.Best regards,Peter

Please Log in or Create an account to join the conversation.

More
8 months 6 days ago #160226 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Subscription remain pending after Stripe payment
Hi Peter

Usually, it happens because you haven't configured Stripe Webhook. See membershipprodoc.joomservices.com/basic-...eckout#configuration and try again

Regards,

Tuan
The following user(s) said Thank You: Peter

Please Log in or Create an account to join the conversation.

More
8 months 6 days ago - 8 months 6 days ago #160228 by Peter
Hi Tuan,

Thanks for quick response. 
Yes, I have been looking into that as well. Indeed, when examining the Stripe Dashboard>Developers> Logs there are four status messages for each time a payment is processed. Three says “200 OK”, but one says “400 ERR” with a response body saying
Code:
{  "error": {    "code": "resource_already_exists",    "doc_url": "https://stripe.com/docs/error-codes/resource-already-exists",    "message": "A plan or price with this ID already exists.",    "request_log_url": "https://dashboard.stripe.com/test/logs/req_ZEABOy36n31q1z?t=1693001387",    "type": "invalid_request_error"  }}
Also, when examining the webhooks event log, (almost) all responses include a 500 error message along with some code that makes me even more confused.
Apart from that I have checked the published/secret keys, as well as the webhook url itself. They seem correct.
Without jumping to conclusions, the “API version” seems outdated, telling from the Stripe dashboard. Our Membership Pro subscription was expired a couple of days before renewing (approx. 2 weeks ago). We are running 3.2.0 currently, but the system states that all extensions are up to date. Could this be an issue?
Again, thanks for your support!
Best, Peter
Last edit: 8 months 6 days ago by Peter. Reason: Formatting and typos

Please Log in or Create an account to join the conversation.

More
8 months 6 days ago #160233 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Subscription remain pending after Stripe payment
Beside configuring webhook, please make sure you get Signing Secret data from the webhook URL and enter it into Signing Secret parameter of the payment plugin

Also, you should use latest version of Membership Pro to make sure everything works well. Sometime, there are changes form payment gateway, so we have to update both the extension and the payment plugin to have it works with latest version of the payment gateway (Stripe API)

Regards,

Tuan

Please Log in or Create an account to join the conversation.

More
8 months 6 days ago #160234 by Peter
Signing Secret also ok.

However, and this is somewhat embarrassing on my part, updating Membership Pro (manually) seems to have done the trick.  Now the payment goes through and the subscription is activated accordingly. My bad, thanks for your time.

However, even though the payment goes through, the 400 error still remains in the Stripe dashboard developers log. Is that something I could ignore?

Best, Peter

Please Log in or Create an account to join the conversation.

More
8 months 6 days ago #160236 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Subscription remain pending after Stripe payment
Thanks Peter for upgrading the subscription. I'm glad it is working well now and Yes, you can ignore the 400 error

Regards,

Tuan
The following user(s) said Thank You: Peter

Please Log in or Create an account to join the conversation.