Hi all,
I’ve been banging my head against the wall with this issue for most of the day now. I’ve setup a backend stripe API workflow so that when a checkout session is completed in the V3 stripe checkout client, bubble can detect that event and make a change to the current user.
The webhook seems to be working correctly in Stripe and setup correctly in bubble, but the workflow I’ve set to change a yes/no datatype for the current user isn’t changing after the event is triggered.
Any help with this issue is greatly appreciated!
You can’t use ‘Current User’ when triggering workflows via webhooks…
‘Current User’ is an internal Bubble concept and, as this workflow is being triggered externally from Stripe, there’s no way the Current User can be passed into your Bubble app from Stripe (Stripe doesn’t have a ‘Current User’). So the ‘Current User’ in this workflow will be empty.
You need to define the User some other way, from the data retrieved by the webhook.
So instead of using ‘Current User’, search the database to find the user in question (for example by matching the email address).
Note that any subsequent API workflows triggered by this initial one will also have no ‘Current User’ so you’ll have to pass the User data as a parameter from one workflow to the next if you plan to trigger more workflows from this one.
1 Like
Thank you @adamhholmes!!
Changing the workflow to “Make changes to a list of things” and searching for users using the “Request Data’s object customer_email” constraint fixed my problem!
Thanks again Adam!
1 Like