Tracking User Subscription - Stripe Self Service Portal Plugin

Hey Bubblers!

I’ve recently installed the plugin Strip Self Service Portal so that I can have my users subscribe and unsubscribe easily. I have all that set up and working perfectly. The only issue that I have that I can’t see to solve is this.

The pricing page contains both the subscription card to sign up and the unsubscribe card to unsubscribe from our service. I want the subscription card to show only when the user doesn’t have a subscription, but not show when they do have a subscription, vice versa for the unsubscribe card.

I know you can track a users subscription status through Stripes Self Service Portal, just not sure how to get that set up!

Any help would be great, here is a link to my project head to the pricing page to view what I’m explaining above!

1 Like

Hey there @rbrtsts0 :wave:

If you are using the Bubble Stripe plugin, it looks like you are, you can access whether or not the user has an account with a conditional on the element.

Just use something like this:

Screen Shot 2020-10-25 at 9.09.56 AM

Hope that helps! :blush:

@j805 www.NoCodeMinute.com

For All Your No-Code Education Needs:

  • One-on-One Tutoring
  • eLearning Hub
  • Video Tutorials
  • No-Code Classes
2 Likes

Hey @J805

I did what you suggested and for some reason it still isn’t working. I’m currently a subscribed user and both of them still show up.

Hey @J805

Do you think I need to remove the StripeSubscription field? Could this be interfering with anything?

Right, I am not using the field. Try to follow closely this conditional, it should look exactly the same. It shouldn’t say ‘StripeSubscription’, you don’t need to reference your data field.

Screen Shot 2020-10-25 at 9.09.56 AM

Crap you’re right just updated it and it’s still not reading it for some reason.

See attached.

Double check your appearance tab to make sure it’s not visible on page load as well as your workflows. Make sure there are no workflows counteracting your conditional. :blush:

So you’re saying do the same thing for on page load as well? I looked through my workflows and nothing is counteracting the conditionals!

Maybe delete that data field so you don’t confuse yourself first. Then let me take a look to see what is wrong.

Deleted the data field as well!

Uncheck these. You have them both visible on page load.

Awesome just did now they don’t both show up haha

Keep this one checked:

Hey @J805 Just did that!! I’m able to get the subscribe card to show but after I subscribe and head back to the pricing page the subscribe card is still showing and the unsubscribe card is still hidden.

Try upgrading your plugin to Checkout v3. See if that helps. Also, I have an appointment right now and will be busy the rest of the day. I will try to take a look at it later this week for you but I am pretty booked with appointments so I will do what I can. :blush:

Will try doing that. But how would that have to do with showing these 2 cards or not? Let me know if you can help later, happy to pay you to fix this as well if that’s of interest.

You can always book a session with me and we can troubleshoot it together if you want. That will guarantee that I have time to spend helping you out. Check out my site if you would like.

Hope that helps! :blush:

@j805 www.NoCodeMinute.com

For All Your No-Code Education Needs:

  • One-on-One Tutoring
  • eLearning Hub
  • Video Tutorials
  • No-Code Classes

It looks like when I subscribe to the stripe account bubble can unsubscribe the user successfully, but I still can’t find out how to get Bubble to track if a user is subscribed or not. I tried the above steps but nothing seems to work… can anyone help with this?

It takes time for Stripe to process a subscription payment so if you are trying to use the subscription is active, it may take Stripe an hour or more, but most likely within 24 hours to process that.

If you look at the api calls from your stripe account for that particular subscription you can see that there are separate timings for when the charge is processed and accepted and when stripe pushes the final notice of the subscription becoming active.

I went through with Bubble support recently trying to figure this out and found out about the ‘lag time’…this was because I was attempting to create the system to track user payment and was trying to use the subscription is active directly after the subscription payment being made.

I had to use the subscription id is not empty to get things working properly directly after a payment was made.

My suggestion is if you are expecting to see the group on your page become hidden immediately after the sign up of a subscription find some other values from the current user stripe subscription to reference in the conditionals as the ‘is active’ might not be available for some time…OR you could in the workflows after the the subscribe the user workflow set a custom state on the group you want to hide. Make the custom state a yes no value and set the conditional to reference the custom state of that group.

1 Like

Hey @boston85719

Thanks for commenting on this. The issue I have with this suggestion is that when the user unsubscribes from a subscription I can easily change the status of the user from yes to no. The issue with this route is if the user clicks unsubscribe, the stripe portal opens up and if the user clicks cancel and doesn’t unsubscribe the users status still gets changed to no even though they didn’t unsubscribe because have it set up to change the user status once they click the unsubscribe button in the workflow (this is the only way I know how to do this) haha.

Let me know if this makes sense and if you have any feedback for what I explained!