-
Notifications
You must be signed in to change notification settings - Fork 390
Do not reset remaining days from trial on uninstall #958
Comments
You should handle this in your database by saving the first install date. Shopify seems to be using cookies for everything in this example, but I don't think it's a good approach for this case since you can have several users/browsers reinstalling the app. |
@daviareias Thanks for your answer. My problem is not how I track the trial, it's how I enforce it. As far as I know Shopify will charge the merchant as soon as the trial ends. My issue is that I cannot find an obvious way of setting different trial days for different users (e.g. the user who uses my app for 2 days, then reinstalls it should have 2 less days of trials than a completely new user). I see 3 solutions (all of them looks somewhat or completely hacky):
Let me know if I missed something or misunderstood how this should be done. |
Hey folks, thanks for reporting this. I think we can help remedy this by allowing an optional override for |
That would be perfect, thanks! |
Overview
We have a problem, where the trial period always resets when the user reinstalls the app. I've also read that this can be a feature, however for us it's definitely a bug, since anyone can just reinstall our app to use it for free forever.
There are a few community answers to solve this, however all of them includes changing the
trialDays
when requesting the recurring application charge. As far as I can see, the current implementation takes the trial days from the billing config, which can only be specified when creating theshopifyApp
instance.One option would be copying the config object with the new trial days, then using
validateConfig
manually on in, then passing it to therequest
factory function to create a request function. However, this does not seem like an intended way to use this library.Is there any other way to do this that I missed? Otherwise, I think it would be great if we could pass the
trialDays
in when using theshopify.api.billing.request
function to implement protection against indefinite free use of an app.The text was updated successfully, but these errors were encountered: