How can I handle someone not completing a PayPal payment?

I have a form that is processing payments with Stripe or PayPal (standard). I have a webhook setup that hits a 3rd party server when payment is completed, but I don’t think that is relevant to my question.

When someone submits a form with PayPal selected as method (driven by Conditional Logic), they are redirected to PayPal. I get the form entry in the database and notifications happen since they are set to “on Form Submitted”. But, if the person closes their browser window or doesn’t complete the PayPal checkout, the entry is marked as Processing in the database. I don’t have admins logging into the site to check that. I can send a notification that “Payment is Complete” on Payment Complete status, but then people getting the notifications have to double check that they are receiving two emails.

I guess what I’m asking is… is there any sort of safety mechanism I can deploy that would send a follow up email to me if xx number of minutes passes and payment hasn’t changed from Processing to Paid? Realistically, if this is possible, I’d want other things to happen too, email the customer saying they didn’t pay and possibly delete the entry, unless there is a way to email a link for them to complete checkout.

This seems like a good discussion :slight_smile:

One way to do it would be with a cron job and the Gravity Forms API functions to check the payment status, compare the time of the entry to the current time, and if the payment is still Processing after some threshold time, then // do something (all the things.)

One other possibility would be to look at Gravity Flow. I do not know if that plugin has the ability to perform an action after some time delay or not, but it’s worth asking there to see if this is already possible, without having to add any code of your own.

Are there any free ways of setting up a cron job within WordPress to do API things? Can the API return all entires with a specific status like Processing?

Gravity Flow looks appetizing. The pricing for it does not.

Regardless of the pricing, Gravity Flow is great. If you have a need for it, it can save many hundreds of hours of development. For this application, I’m not even sure if it can do what you needed. It was just something to look into.

For using WordPress cron and the Gravity Forms API, you don’t need any plugins - it can all be accomplished with custom code. I was tossing out that idea as a possibility, but I’m sure there are other ways to accomplish this, and I’ll leave this open in case anyone has tackled something similar in the past.