Allow subscription of predetermined length

I sucessfully solved the one time subscription with a time interval by add a new metadata (“recurring:0/1”) in price object. And when you try to create a subscription with price[:metadata][:recurring]==“0” I will set the cancel_at_end value = true in Subscription object.
Then when you create a one time price, you still need to choose a interval (year, month, day, week), but you should not check the “recurring” box.
And when a user subscribe it, the backend will create a recurring subscription which will end at the end date. User will not need to cancel renewal by them self.

However, I found that I cannot delete the products I create. see Cannot delete products on Discourse Subscriptions - #2 by Jonathan5

正在上傳: image.png…
this is my problem, I cannot delete the products. Sho



uld I delete them on stripe?

1 Like