@Erjen Rijnders Thanks for posting in our Q&A.
For this issue, I will share some information with you. Firstly, factoryResetKeepEnrollmentData seems related to "Retain enrollment state and user account" in wipe action. It is only available for Windows 10 version 1709 or later.
https://learn.microsoft.com/en-us/mem/intune/remote-actions/devices-wipe#wipe
We usually uninstall apps via add groups in uninstall assignment in intune portal. I have done a lot of research, I found there is assign action via Graph API. Here is the example:
https://learn.microsoft.com/en-us/graph/api/intune-shared-mobileapp-assign?view=graph-rest-beta#example
I think we could change the intent from "required" to "Uninstall".
Hope the above information will give you some idea.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.