I’m trying to delete a user along with all its related data when the app receives a specific webhook event. As of now, I’m able to delete all the related data, such as its products, subscriptions, … etc.
However, the user itself is not deleted. Here are two screenshots of how I’m deleting the subscription, for example, which is working as expected, and how I’m trying to delete the user, which is not doing anything.
Smart money says it’s the default privacy rule on the User data type that is getting in the way because that’s almost always the case in a situation like the one you are describing.
Of course you can change the default privacy rule, and the consequences are specific to the changes you make and the nature of your app. Instead of immediately firing back additional questions, you should learn about privacy rules and figure out how to use them correctly, and then apply what you learn to your app.
Well then, there you go… the Only When condition on the workflow is not being met (so that action doesn’t run).
I don’t know what the Condition is (aside from being Request Data’s event is Arbritray Text)…
So what is the Arbritrary text?
But if it’s anything to do with The User’s merchant_ID field, then I expect @mikeloc is correct, and you have a privacy rule stopping that field (or the entire User object) from being accessible in the workflow.
So either change your privacy rules, or check the box to allow the workflow to Ignore Privacy Rules when running, depending of course on the specifics of your app, the data you need to protect, and the way your workflow is set up etc.
Ok, mission accomplished. Not sure about the consequences yet though.
I found two ways to work around this, one is to add a privacy rule to the User type, as shown in the attachment. The other is to allow everyone to find this in search.
@halmelaifi I wouldn’t recommend that privacy rule. If your problem is related to privacy rules, it might be better to check the checkbox “ignore privacy rules” when running that backend workflow.