I am implementing ecommerce functionality. I have a situation where I want to restore product back into stock when stripe paymentIntent is not confirmed for a long time (say 10 minutes). To go into detail what I am doing is that when customer goes to checkout I lock stock of the products in cart. Then I ran a cronjob to identify carts which are lying unused for more than 30 minutes and restore stock back into inventory. This is fine, but there might be a case where user is paying and cart might be restored, inorder to tackle this, when payment is initiated I change cart state to inProgress so that cronjob is not restoring this cart. But if user is initiating payment and never completes it then cart will never be restored. So I am looking for a way in which paymentIntent will be expired and I can restore this cart in stripe webhooks. Any other alternative is appreciated.