Templates Plugins Courses

Cancel subscription - time remaining

Hello!
I’m trying to set cancellation of a subscription in order to allow the user access the content for the remaining time period.
Let’s say he’s getting his monthly subscription today and cancels the subscription tomorrow, he will need to have access till next month.
Right now his access to content is being suspended immediately. Stripe-side everything works fine (subscription is cancelled).

Thanks

Paolo

Hi @floripaolo, thanks for your inquiry.

I’m afraid that an answer to this question would mostly relate to template customization works and would be out of my responsibilities as a support team member as it is not related to the template default functionality.

As a general direction, allow me to recommend the following link, that might be useful for your case: How to cancel a Stripe Plan after subscription period ends? - Need help - Bubble Forum

Regards,

1 Like

Thanks @Serg

I’ll have a look at it!

1 Like

Hi @Serg

OK. I understand how it works on Stripe for a web app.

But how is this handled with Airnative on Apple in-app purchase and Google Play store payment?

Thanks for clarifying.

Paolo

Hi @floripaolo, thanks for your question.

If I remember right, your app uses the subscription model (allows users to use the content for a certain period of time).
In this case, to ensure the purchases in Google and App stores, it is required to add in-app purchases actions, provided by Air Native plugin.
Hope the provided hint will help.

Regards,

Hello @Serg
Yes Serg, I know this. Apple In-App Purchase is already setup.

The question was: How does the remaining time is handled by Apple for example?
Or in other words: If I subscribe today for a monthly subscription and cancel in 2 days, how does Bubble not cancel the access to the content right away, but only in 28 days? What setup is needed?

The documentation (which I read extensively) does not provide any information about this setup/action.

Thanks for clarifying.

Paolo

@floripaolo

The Apple and Google stores are only registering the fact of the purchase (+ taking the required commission fee).
All required use case workflows (to keep the user’s subscription active for a certain period) should be set up and managed within the Bubble application. For general guidance, please use the link shared two messages above.

Regards,

1 Like

Hi @Serg

  1. In order to setup a scheduled backend workfIow properly, I have a question regarding Apple/Google/Stripe subscription payments concerning your InnerSpace template:
    Does the transaction_date gets updated on each subscription payment cycle?
    Or do I need to update the date with a backend workflow as well?

Using the “cancel the current user’s plan” action will cancel the subscription in all three platforms?

Stripe by cancelling without further action.
Google/Apple by forwarding the user to their dashboard. Do you confirm?

Screenshot 2022-05-12 at 11.02.56

If someone for example cancels the subscription directly from the App Store there is no way to know and the user will still be able to access all paid content. How do you avoid such a situation?

Thanks

Paolo

Hi @floripaolo, thanks for your questions.

Yes, this data type is updated on each change of the subscription status. You can see cases when changes are applied by checking the “Make changes to a thing” actions, which modifies the “transaction_date” field.
For example:

No, it will cancel only a subscription that has been made in Stripe through the web application. If you need to cancel a subscription on iOS or Android, you have to use the Air Native plugin workflow related to that: https://docs.zeroqode.com/plugins/air-native-plugin/setup-guide#vl-in-app-purchases

One of the solutions, in this case, would be to add in cancel subscription workflow canceling actions for Stripe & Google Play & Apple Store, with a conditional that checks if the subscription relates or not to a certain platform. It will choose the right platform and how to cancel it, whether it is iOS/Android/web app. The plugin states will help you with that, you can check the docs mentioned above.

Hope the provided hints will help.

Regards,

1 Like

hi @Serg

I see what you mean, but this applies to the first time the user subscribes.
But after a month, when let’s say Stripe charges him again, will this date be updated?

Thanks

Paolo

Hi @floripaolo, thanks for your reply.

No, the default template functionality doesn’t provide the possibility to update the “transaction_date” on the next Stripe charge.

Regards,

1 Like

Hello @Serg

I had a customer that signed up to a subscription with 7 days trial period with an Apple in app purchase.
The customer cancelled the subscription from within the App store (he didn’t get charged after the trial period ended). But in Bubble the subscription is obviously still active…

This is a pretty serious flaw. How can I handle this problem?

Thanks

Paolo

Hi @floripaolo,

A solution, in this case, would be to register the fact of subscription cancellation in the user’s profile (for example - subscription access: yes/no), so once the subscription is canceled through any of the payment platforms, he lost access to the paid content.

Regards,

@Serg

How is Bubble getting the trigger from the App store to register this fact?
The user does not cancel the subscription in Bubble but in the App Store.

Thanks for clarifying. Is there any documentation describing this process in case?

Paolo

Once the workflow with subscription cancellation is triggered, you just add one more step with “Make changes to a thing”, where a certain value in the user’s profile is modified (from example from yes to no).

As the described use case is a particular one, regretfully there is no specific documentation available. To understand what available events and actions has the Air native plugin, please see the plugin documentation: https://docs.zeroqode.com/plugins/air-native-plugin/setup-guide#tu-elements

Regards,

@Serg

Cancellation is NOT triggered from Bubble!!

The user cancel directly from the App Store WITHOUT hitting “cancel subscription” in Bubble.

Cancellation is done directly from the App Store!!

Hi @floripaolo, thanks for the provided detail.

On purchase, a purchase id is generated. Using this Id and action “IAP - Check Active Purchase A Air Native”, the status of the purchase can be checked.
image

If the subscription is active - status will be “true”, and if not, correspondingly it is “false”. Considering this, you can build workflows that will check and change subscription status in Bubble database.

Hope the provided hint helps.

Regards,

1 Like

Do you have some documentation in regard?

Thanks

So far, we have the general documentation for the Air Native plugin, available on:

Later, gradually, we will add more useful information to it.

Regards,

1 Like

Hi @Serg

But since I don’t know when the customer cancels his subscription on the App store, I will need to check periodically (i.e. once a day) if the purchase is active.
Correct?

How is this done by Bubble?

This sounds like a very cumbersome workaround for a very common situation…

Cheers