• Resolved Assadullah Shaikh

    (@assadullahshaikh)


    Greetings,

    I have set up the free version of wps subscription plugin on my website and it works great when someone purchases the subscription product via the pricing plans section. The problem occurs during the subscription renewal. The subscription status turns to “On-Hold” and the order automatically fails. When I access the customer payment page, it shows an error message: “This order cannot be paid for. Please contact us if you need assistance.” Screenshot (image 1): https://imgur.com/a/rQW1PO7

    The order note shows “Stripe Transaction Failed Order status changed from Pending payment to Failed.” and I’m not sure how to debug this step. Screenshot (image 2): https://imgur.com/a/rQW1PO7

    I have searched across the board here as well as the woo-commerce plugin section. Came across multiple solutions. I.e.

    1. the failure could be due to the cache plugin appending some parameters in the checkout URL.
    2. Renewal Payment failed for Paypal
    3. Error: This order cannot be paid for. Please contact us if you need assistance.
      and more. Tried whatever was possible but ran out of luck.

    Some general information: I am using the stripe payment gateway and it is enabled in settings. When the subscription is purchased for the first time, it works well. The problem occurs upon renewal. The order fails and the subscription is set to hold.

    Here’s System Status Report from woocommerce: https://pastebin.com/CvTDQerB
    Here’s the latest log from wps subscriptions plugin: https://pastebin.com/mVNf5ABy – There are no fatal error logs.

    I would also like to know the hook for subscription renewal in this plugin.

    If you require some more information, please let me know. Your assistance would be appreciated.

    Thanks & Regards,

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author WP Swings

    (@wpswings)

    Hey,

    For stripe renewal failed issue we have two suggestion for you.

    1. please check by your end you are using our plugin updated version because in the previous version there is some issue arise after stripe offical update but we have already solved the issue and release the new version of our plugin i.e v 1.5.0 so please check you are using latest version on your site.

    2. if you are using latest version and still facing issue with stripe renewal then we strongly suggest please connect with our support they will assist you better.

    And as you mention ” I would also like to know the hook for subscription renewal in this plugin.”

    So here is hook for subscription renewal which generally work at subscription renewal scheduler

    “wps_sfw_create_renewal_order_schedule” this is action hook so you can use it while using do_action.

    example – add_action( ‘wps_sfw_create_renewal_order_schedule’, ‘your_custom_function_callback’ );

    Thank you

    Thread Starter Assadullah Shaikh

    (@assadullahshaikh)

    Hi @wpswings , Thanks for getting back. 🙂

    I have followed your suggestion. I noticed the plugin’s version was 1.4.8. I’ve now updated it to the recent one (1.5.0), Screenshot: https://i.imgur.com/GhQxcDf.png – I have created a 1-day subscription order. Let’s hope it gets renewed automatically after 24 hours. Meanwhile, please keep the topic open.

    Thank you for sharing the webhook. If you don’t mind me asking for some more information; I have some custom settings which I need to update on every successful subscription purchase as well as renewal. The webhook you provided is triggered on every subscription renewal (when the renewal payment is charged), right?

    In the developer section of the plugin, there’s a webhook: wps_sfw_subscription_active_renewal’,$subscription->ID);, can you please guide me on the use of this webhook also? I have tried searching webhooks knowledge base on your website but I couldn’t find the relevant documentation.

    Your help is appreciated. Thank you.

    Thread Starter Assadullah Shaikh

    (@assadullahshaikh)

    Hey @wpswings ,

    Thank you for your help. Updating the plugin fixed the renewal failure issue. It is now being renewed successfully. Besides, If I may ask; if you could guide me, how can I create a subscription programmatically, that’d be very helpful. i.e. the hook or function that I need to make a call to. I am creating an order. Couldn’t find the way to create subscription via wp swings.

    Thanks,

    Plugin Author WP Swings

    (@wpswings)

    Hey,

    Sorry, but we do not have the feature to create subscriptions manually.

    But we call a function wps_sfw_create_subscription during the checkout to create a subscription. You can take a reference from that. But this will be a little complicated to understand.

    Thank you

    Thread Starter Assadullah Shaikh

    (@assadullahshaikh)

    Hi, Thanks for the help. I really appreciate it and the plugin is now working smoothly.

    I’ll look into the mentioned fuction if I can make up something of it. Thank you.

    Plugin Author WP Swings

    (@wpswings)

    Most welcome !

    Plugin Author WP Swings

    (@wpswings)

    Most welcome!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Subscription Renewal Failure: This order cannot be paid for’ is closed to new replies.