Stripe Update Status Changes to a non User Data Type

I want to keep track of my membership data in it’s own data type. Once reason is so I can keep track of users who have a membership, let it expire, and then start up again. I want that history.

I’m trying to set up a Backend Workflow to so if a subscription is canceled in Stripe, it will update the user and the Membership Data type connected to the subscription. It seems all the Stripe data from the Stripe Plugin is connected to the user.

How can I update the Membership Data type when, for example, a member cancels a subscription?

Make changes to user seems to work:
Thing to change: user(search for User) Stripe Customer ID=Request Data’s object customer

Make changes to Membership is not working(see in image)

You need to setup Stripe Webhooks for Stripe to automatically update your app of when a subscription is canceled in Stripe.

Once you do that you would need to reference the Detect Request Data in your dynamic expressions to find the stripe customer ID.

1 Like

:raised_hands:gold^^^

To add to this you also want to probably setup either daily/weekly/monthly recurring checks that ping the stripe database for subscription statuses/last payment date and compare vs your database as I’ve seen issues where bubble is not catching the webhook or stripe fails randomly that can cause discrepancies you wouldn’t want in a payment system.

2 Likes

Thank you, I should have clarified that I already have the webhook setup. As I mention it works on updating the user Data Type, but the issue is it won’t work in the same way on the Membership data type.

Looks like you are trying to search for a data type in your database that is called Membership…in that search you are attempting to constrain by a field that is labeled Member and your red dynamic expression is attempting to match Member to a Stripe Customer ID field on your User Data type.

Is the Member data field on the Membership Data type of type Text or User? Because the dynamic expression is red it seems like it is not supposed to be Text, which is what you are creating in that dynamic expression ( hover over it and see what it evaluates to )…if the field of Member is a User then remove the Stripe Customer ID portion of the red dynamic expression and just use the result of step 1 ( which is a User because in step 1 you are making changes to a User ).

Thank you! I’m still trying to wrap my brain around all these concepts.

One of the best ways to resolve for issues with dynamic expressions (when they are red) is to hover over it to see what it evaluates to…especially when the data type is the correct type, but it is evaluating as a single item and the element you are using is expecting a list.

I definitely struggled a lot with that.